public class FileTransferManagerConfig extends Object
Constructor and Description |
---|
FileTransferManagerConfig() |
FileTransferManagerConfig(int maxRestApiRetries, int maxRestApiRetryElapsedTimeInSeconds, long connectTimeoutInMillis, String tempDirPath)
Deprecated.
Instead use the constructor with no arguments. As of release 2.1, the parameter tempDirPath is not supported.
|
Modifier and Type | Method and Description |
---|---|
long |
getConnectTimeout()
Returns connection timeout in milliseconds.
|
KeyPair |
getKeyPair()
Returns key pair used by EncryptedFileTransferManager for client-side encryption/decryption of objects.
|
int |
getMaxDataTransferThreads()
Returns maximum number of threads to be used for data transfer.
|
int |
getMaxRestApiRetries()
Returns maximum REST API retry count.
|
int |
getMaxRestApiRetryElapsedTime()
Returns maximum retry elapsed time.
|
long |
getReadTimeout()
Returns read timeout in milliseconds.
|
String |
getTempDirPath()
Deprecated.
As of release 2.1, temporary directory is not required for transferring files.
Returns temporary directory path location used for transferring large files. |
oracle.cloudstorage.api.http.URLStreamHandlerConfig |
getUrlStreamHandlerConfig()
Returns a URL Stream Handler configuration.
|
void |
setConnectTimeout(long connectTimeoutInMillis)
Sets the connection timeout (in milliseconds) for the REST APIs.
Default is 120000 (2 minutes).
|
void |
setKeyPair(KeyPair keyPair)
Sets the key pair used by EncryptedFileTransferManager for client-side encryption/decryption of objects.
|
void |
setMaxDataTransferThreads(int maxDataTransferThreads)
Sets maximum number of data transfer threads.
|
void |
setMaxRestApiRetries(int maxRestApiRetries)
Sets maximum retry count for a REST API before aborting it.
|
void |
setMaxRestApiRetryElapsedTime(int maxRestApiRetryElapsedTimeInSeconds)
Sets the maximum time elapsed for retry attempts before aborting it.
|
void |
setReadTimeout(long readTimeoutInMillis)
Sets the read timeout (in milliseconds) for the REST APIs.
Default is 120000 (2 minutes).
|
void |
setTempDirPath(String tempDirPath)
Deprecated.
As of release 2.1, temporary directory is not required for transferring files.
Sets temporary directory path location used for transferring large files. |
void |
setUrlStreamHandlerConfig(oracle.cloudstorage.api.http.URLStreamHandlerConfig urlStreamHandlerConfig)
Sets URL Stream Handler configuration.
This enables to override the default URL stream handler with the specified stream handler.
|
public FileTransferManagerConfig()
@Deprecated public FileTransferManagerConfig(int maxRestApiRetries, int maxRestApiRetryElapsedTimeInSeconds, long connectTimeoutInMillis, String tempDirPath)
maxRestApiRetries
-maxRestApiRetryElapsedTimeInSeconds
-connectTimeoutInMillis
-tempDirPath
-@Deprecated public String getTempDirPath()
Returns temporary directory path location used for transferring large files.
@Deprecated public void setTempDirPath(String tempDirPath)
Sets temporary directory path location used for transferring large files.
tempDirPath
- temporary directory path locationpublic int getMaxRestApiRetries()
public void setMaxRestApiRetries(int maxRestApiRetries)
The retries are attempted for network failures and other HTTP errors such as 'internal server error' or 'service unavailable'.
This is used along with maximum time elapsed. The retry attempts will be stopped whenever either of the condition is met.
maxRestApiRetries
-IllegalArgumentException
- If the parameter maxRestApiRetries is less than 1.public int getMaxRestApiRetryElapsedTime()
public void setMaxRestApiRetryElapsedTime(int maxRestApiRetryElapsedTimeInSeconds)
This is used along with maximum retries. The retry attempts will be stopped whenever either of the condition is met.
maxRestApiRetryElapsedTimeInSeconds
-IllegalArgumentException
- If parameter maxRestApiRetryElapsedTimeInSeconds is negative.public long getConnectTimeout()
public void setConnectTimeout(long connectTimeoutInMillis)
connectTimeoutInMillis
-IllegalArgumentException
- if parameter connectTimeoutInMillis is negative.public long getReadTimeout()
public void setReadTimeout(long readTimeoutInMillis)
readTimeoutInMillis
-IllegalArgumentException
- if parameter readTimeoutInMillis is negative.public void setMaxDataTransferThreads(int maxDataTransferThreads)
maxDataTransferThreads
- maximum number of data transfer threadsIllegalArgumentException
- If the parameter maxDataTransferThreads is less than 1.public int getMaxDataTransferThreads()
public KeyPair getKeyPair()
public void setKeyPair(KeyPair keyPair)
keyPair
- Security key pair for encryptionpublic oracle.cloudstorage.api.http.URLStreamHandlerConfig getUrlStreamHandlerConfig()
public void setUrlStreamHandlerConfig(oracle.cloudstorage.api.http.URLStreamHandlerConfig urlStreamHandlerConfig)
urlStreamHandlerConfig
- URL Stream Handler configuration