fix(web): avoid asset list failures during large uploads
This commit is contained in:
@@ -79,6 +79,7 @@ export const uploadAsset = async (
|
||||
): Promise<{ storage_key: string; ingest_job_id: string; url: string }> => {
|
||||
const response = await apiClient.post('/upload', formData, {
|
||||
headers: { 'Content-Type': 'multipart/form-data' },
|
||||
timeout: 30 * 60 * 1000,
|
||||
});
|
||||
return response.data;
|
||||
};
|
||||
|
||||
@@ -147,7 +147,9 @@ const ProjectAssets: React.FC = () => {
|
||||
queryKey: ['assets', libraryId],
|
||||
queryFn: () => getAssets(libraryId),
|
||||
enabled: !!libraryId,
|
||||
refetchInterval: 3000,
|
||||
retry: 3,
|
||||
retryDelay: (attemptIndex) => Math.min(1000 * 2 ** attemptIndex, 5000),
|
||||
refetchOnWindowFocus: false,
|
||||
});
|
||||
|
||||
const ingestJobQuery = useQuery({
|
||||
|
||||
Reference in New Issue
Block a user