-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changing request timeout to infinite for file upload #58
Conversation
12509c2
to
50326c6
Compare
…tion and default one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good at a high level w.r.t. overall structure. Just need a consistency/documentation pass and should be good. 👍
|
||
/** | ||
* @function comsAxios | ||
* Returns an Axios instance for the COMS API | ||
* @param {number} [timeout=10000] Number of milliseconds before timing out the request | ||
Returns an Axios instance for the COMS API |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a potential indentation issue in the git diff here?
…d, and fixing indentation.
frontend/src/store/objectStore.ts
Outdated
@@ -8,6 +8,7 @@ import { partition } from '@/utils/utils'; | |||
|
|||
import type { Ref } from 'vue'; | |||
import type { COMSObject, ObjectSearchPermissionsOptions } from '@/types'; | |||
import type { AxiosRequestConfig } from 'axios'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
External type import. Should come before vue import.
@@ -44,7 +44,8 @@ const onUpload = async (event: any) => { | |||
await Promise.allSettled( | |||
event.files.map(async (file: File) => { | |||
try { | |||
await objectStore.createObject(file, bucketId); | |||
//infinite timeout for big files upload to avoid timeout error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Style: missing space after // and capitalization
https://apps.nrs.gov.bc.ca/int/jira/browse/SHOWCASE-3139? Changed the number of milliseconds before timing out the request for file upload only, to infinitive. Adding timeout as input argument at service/store layer, if not passed in defaults to 10000ms.
Used 1GB for testing.
Types of changes
Checklist
Further comments