Class FileDownloader
java.lang.Object
gov.nasa.pds.registry.common.util.file.FileDownloader
File downloader with retry logic.
By default, SSL certificate and host verification is disabled for HTTPS
connections to support self-signed certificates. This can be turned off.
- Author:
- karpenko
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
FileDownloader
Constructor- Parameters:
sslTrustAll- Enable or disable SSL certificate and host validation to support self-signed certificates.- Throws:
Exception
-
-
Method Details
-
download
Download a file from a URL. Retry several times on error.- Parameters:
fromUrl- Download a file from this URL.toFile- Save to this file- Throws:
Exception- an exceptionIOExceptionInterruptedException
-