fix(storage): rename S3 configuration and change stream interfaces to storage-oriented types
This commit is contained in:
@@ -33,8 +33,8 @@ export class TsView {
|
||||
/**
|
||||
* Set S3 configuration programmatically
|
||||
*/
|
||||
public setS3Config(config: interfaces.IS3Config): void {
|
||||
this.config.setS3Config(config);
|
||||
public setStorageConfig(config: interfaces.IStorageConfig): void {
|
||||
this.config.setStorageConfig(config);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -52,17 +52,17 @@ export class TsView {
|
||||
return this.smartbucketInstance;
|
||||
}
|
||||
|
||||
const s3Config = this.config.getS3Config();
|
||||
if (!s3Config) {
|
||||
const storageConfig = this.config.getStorageConfig();
|
||||
if (!storageConfig) {
|
||||
return null;
|
||||
}
|
||||
|
||||
this.smartbucketInstance = new plugins.smartbucket.SmartBucket({
|
||||
endpoint: s3Config.endpoint,
|
||||
port: s3Config.port,
|
||||
accessKey: s3Config.accessKey,
|
||||
accessSecret: s3Config.accessSecret,
|
||||
useSsl: s3Config.useSsl ?? true,
|
||||
endpoint: storageConfig.endpoint,
|
||||
port: storageConfig.port,
|
||||
accessKey: storageConfig.accessKey,
|
||||
accessSecret: storageConfig.accessSecret,
|
||||
useSsl: storageConfig.useSsl ?? true,
|
||||
});
|
||||
|
||||
return this.smartbucketInstance;
|
||||
|
||||
Reference in New Issue
Block a user