public class StsOssClientProvider extends Object implements Closeable
Constructor and Description |
---|
StsOssClientProvider(UnderFileSystemConfiguration ossConfiguration)
Constructs a new instance of
StsOssClientProvider . |
Modifier and Type | Method and Description |
---|---|
void |
close() |
protected void |
createOrRefreshOssStsClient(UnderFileSystemConfiguration ossConfiguration)
Create Or Refresh the STS OSS client.
|
com.aliyun.oss.OSS |
getOSSClient()
Returns the STS OSS client.
|
void |
init()
Init
StsOssClientProvider . |
protected void |
setOssClientBuilder(com.aliyun.oss.OSSClientBuilder ossClientBuilder) |
public StsOssClientProvider(UnderFileSystemConfiguration ossConfiguration)
StsOssClientProvider
.ossConfiguration
- UnderFileSystemConfiguration
for OSSpublic void init() throws IOException
StsOssClientProvider
.IOException
- if failed to init OSS Clientprotected void createOrRefreshOssStsClient(UnderFileSystemConfiguration ossConfiguration) throws IOException
ossConfiguration
- OSS UnderFileSystemConfiguration
IOException
- if failed to create or refresh OSS clientpublic com.aliyun.oss.OSS getOSSClient()
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
protected void setOssClientBuilder(com.aliyun.oss.OSSClientBuilder ossClientBuilder)
Copyright © 2023. All Rights Reserved.