-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ZCS-11427 new SOAP api for configuring S3 bucket
- Loading branch information
1 parent
5170f22
commit 2b8c898
Showing
11 changed files
with
467 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,8 @@ | |
.project | ||
.settings/ | ||
.idea/ | ||
*.iml | ||
.java-version | ||
build/ | ||
bin/ | ||
.DS_Store | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
common/src/java/com/zimbra/common/soap/GlobalExternalStoreConfigConstants.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package com.zimbra.common.soap; | ||
|
||
public final class GlobalExternalStoreConfigConstants { | ||
|
||
public static final String E_GLOBAL_S3_BUCKET_CONFIGURATIONS = "global/s3BucketConfigurations"; | ||
public static final String A_S3_GLOBAL_BUCKET_UUID = "globalBucketUUID"; | ||
public static final String A_S3_BUCKET_NAME = "bucketName"; | ||
public static final String A_S3_STORE_PROVIDER = "storeProvider"; | ||
public static final String A_S3_PROTOCOL = "protocol"; | ||
public static final String A_S3_ACCESS_KEY = "accessKey"; | ||
public static final String A_S3_SECRET_KEY = "secretKey"; | ||
public static final String A_S3_REGION = "region"; | ||
public static final String A_S3_DESTINATION_PATH = "destinationPath"; | ||
public static final String A_S3_URL = "url"; | ||
public static final String A_S3_BUCKET_STATUS = "bucketStatus"; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
soap/src/java/com/zimbra/soap/admin/message/CreateS3BucketConfigRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2022 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.admin.type.AdminAttrsImpl; | ||
|
||
/** | ||
* @zm-api-command-auth-required true | ||
* @zm-api-command-admin-auth-required true | ||
* @zm-api-command-description Create S3 Bucket Config <br /> | ||
*/ | ||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_CREATE_S3_BUCKET_CONFIG_REQUEST) | ||
public class CreateS3BucketConfigRequest extends AdminAttrsImpl { | ||
|
||
public CreateS3BucketConfigRequest() { | ||
} | ||
|
||
} |
34 changes: 34 additions & 0 deletions
34
soap/src/java/com/zimbra/soap/admin/message/CreateS3BucketConfigResponse.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2022 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.admin.type.AdminAttrsImpl; | ||
|
||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_CREATE_S3_BUCKET_CONFIG_RESPONSE) | ||
public class CreateS3BucketConfigResponse extends AdminAttrsImpl { | ||
|
||
public CreateS3BucketConfigResponse() { | ||
} | ||
|
||
} |
39 changes: 39 additions & 0 deletions
39
soap/src/java/com/zimbra/soap/admin/message/DeleteS3BucketConfigRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2022 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.admin.type.AdminAttrsImpl; | ||
|
||
/** | ||
* @zm-api-command-auth-required true | ||
* @zm-api-command-admin-auth-required true | ||
* @zm-api-command-description Delete S3 Bucket Config <br /> | ||
*/ | ||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_DELETE_S3_BUCKET_CONFIG_REQUEST) | ||
public class DeleteS3BucketConfigRequest extends AdminAttrsImpl { | ||
|
||
public DeleteS3BucketConfigRequest() { | ||
} | ||
|
||
} |
34 changes: 34 additions & 0 deletions
34
soap/src/java/com/zimbra/soap/admin/message/DeleteS3BucketConfigResponse.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2022 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.admin.type.AdminAttrsImpl; | ||
|
||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_DELETE_S3_BUCKET_CONFIG_RESPONSE) | ||
public class DeleteS3BucketConfigResponse extends AdminAttrsImpl { | ||
|
||
public DeleteS3BucketConfigResponse() { | ||
} | ||
|
||
} |
39 changes: 39 additions & 0 deletions
39
soap/src/java/com/zimbra/soap/admin/message/GetS3BucketConfigRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2012 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.admin.type.AdminAttrsImpl; | ||
|
||
/** | ||
* @zm-api-command-auth-required true | ||
* @zm-api-command-admin-auth-required true | ||
* @zm-api-command-description Get S3 Bucket Config | ||
*/ | ||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_GET_S3_BUCKET_CONFIG_REQUEST) | ||
public class GetS3BucketConfigRequest extends AdminAttrsImpl { | ||
|
||
public GetS3BucketConfigRequest() { | ||
} | ||
|
||
} |
57 changes: 57 additions & 0 deletions
57
soap/src/java/com/zimbra/soap/admin/message/GetS3BucketConfigResponse.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/* | ||
* ***** BEGIN LICENSE BLOCK ***** | ||
* Zimbra Collaboration Suite Server | ||
* Copyright (C) 2022 Synacor, Inc. | ||
* | ||
* This program is free software: you can redistribute it and/or modify it under | ||
* the terms of the GNU General Public License as published by the Free Software Foundation, | ||
* version 2 of the License. | ||
* | ||
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; | ||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
* See the GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License along with this program. | ||
* If not, see <https://www.gnu.org/licenses/>. | ||
* ***** END LICENSE BLOCK ***** | ||
*/ | ||
|
||
package com.zimbra.soap.admin.message; | ||
|
||
import java.util.Collection; | ||
import java.util.List; | ||
|
||
import javax.xml.bind.annotation.XmlAccessType; | ||
import javax.xml.bind.annotation.XmlAccessorType; | ||
import javax.xml.bind.annotation.XmlElement; | ||
import javax.xml.bind.annotation.XmlRootElement; | ||
|
||
import com.google.common.collect.Lists; | ||
import com.zimbra.common.soap.AdminConstants; | ||
import com.zimbra.soap.type.GlobalS3BucketConfiguration; | ||
|
||
@XmlAccessorType(XmlAccessType.NONE) | ||
@XmlRootElement(name = AdminConstants.E_GET_S3_BUCKET_CONFIG_RESPONSE) | ||
public final class GetS3BucketConfigResponse { | ||
|
||
/** | ||
* @zm-api-field-description Information about globalS3BucketConfigs | ||
*/ | ||
@XmlElement(name = "globalS3BucketConfigurations", required = true) | ||
private final List<GlobalS3BucketConfiguration> globalS3BucketConfigurations = Lists.newArrayList(); | ||
|
||
public void setGlobalS3BucketConfigurations(Collection<GlobalS3BucketConfiguration> list) { | ||
globalS3BucketConfigurations.clear(); | ||
if (list != null && !list.isEmpty()) { | ||
globalS3BucketConfigurations.addAll(list); | ||
} | ||
} | ||
|
||
public List<GlobalS3BucketConfiguration> getGlobalS3BucketConfigurations() { | ||
return globalS3BucketConfigurations; | ||
} | ||
|
||
public void addGlobalS3BucketConfiguration(GlobalS3BucketConfiguration globalS3BucketConfig) { | ||
globalS3BucketConfigurations.add(globalS3BucketConfig); | ||
} | ||
|
||
} |
Oops, something went wrong.