@@ -281,24 +281,6 @@ pub struct WorkerStartOpts {
281281 /// It should *NOT* be placed on a network filesystem.
282282 #[ arg( long) ]
283283 pub work_dir : Option < PathBuf > ,
284-
285- /// The maximal parallel downloads for data objects
286- #[ arg( long, default_value = "4" ) ]
287- pub max_parallel_downloads : u32 ,
288-
289- /// The maximal data object download tries
290- ///
291- /// Specifies how many times the worker tries to download a data object
292- /// from the remote side before download is considered as failed.
293- #[ arg( long, default_value = "8" ) ]
294- pub max_download_tries : u32 ,
295-
296- #[ arg( long,
297- default_value = "1s" , value_parser = parse_hms_or_human_time,
298- help = duration_doc!( "The delay between download attempts\n \n Sets how long to wait between failed downloads of data object. This time is multiplied by the number of previous retries. Therefore between 4th and 5th retry it waits 4 * the given duration" ) ,
299- value_name = "TIME" )
300- ]
301- pub wait_between_download_tries : Duration ,
302284}
303285
304286pub async fn start_hq_worker (
@@ -344,24 +326,13 @@ fn gather_configuration(opts: WorkerStartOpts) -> anyhow::Result<WorkerConfigura
344326 hostname,
345327 on_server_lost,
346328 work_dir,
347- max_parallel_downloads,
348- max_download_tries,
349- wait_between_download_tries,
350329 } = opts;
351330
352331 let detect_resources = detect_resources_cli
353332 . clone ( )
354333 . map ( |p| p. into_parsed_arg ( ) )
355334 . unwrap_or_default ( ) ;
356335
357- if max_download_tries == 0 {
358- bail ! ( "--max-download-tries cannot be zero" ) ;
359- }
360-
361- if max_parallel_downloads == 0 {
362- bail ! ( "--max-parallel-downloads cannot be zero" ) ;
363- }
364-
365336 let hostname = get_hostname ( hostname) ;
366337 let mut resources: Vec < _ > = resource. into_iter ( ) . map ( |x| x. into_parsed_arg ( ) ) . collect ( ) ;
367338 let cpu_resources = resources. iter ( ) . find ( |x| x. name == CPU_RESOURCE_NAME ) ;
@@ -480,9 +451,6 @@ fn gather_configuration(opts: WorkerStartOpts) -> anyhow::Result<WorkerConfigura
480451 idle_timeout,
481452 overview_configuration,
482453 extra,
483- max_parallel_downloads,
484- max_download_tries,
485- wait_between_download_tries,
486454 } )
487455}
488456
0 commit comments