File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -282,19 +282,24 @@ export class YdbEmbeddedAPI extends AxiosWrapper {
282282 } ,
283283 { concurrentId} : AxiosOptions = { } ,
284284 ) {
285+ // Time difference to ensure that timeout from ui will be shown rather than backend error
286+ const uiTimeout = 9 * 60 * 1000 ;
287+ const backendTimeout = 10 * 60 * 1000 ;
288+
285289 return this . post < QueryAPIResponse < Action , Schema > > (
286- this . getPath ( `/viewer/json/query${ schema ? `?schema=${ schema } ` : '' } ` ) ,
290+ this . getPath (
291+ `/viewer/json/query?timeout=${ backendTimeout } ${ schema ? `&schema=${ schema } ` : '' } ` ,
292+ ) ,
287293 {
288294 query,
289295 database,
290296 action,
291297 stats,
292- timeout : 10 * 60 * 1000 ,
293298 } ,
294299 { } ,
295300 {
296301 concurrentId,
297- timeout : 9 * 60 * 1000 ,
302+ timeout : uiTimeout ,
298303 } ,
299304 ) ;
300305 }
You can’t perform that action at this time.
0 commit comments