Skip to content
This repository has been archived by the owner on Sep 16, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
feat: added topic field to Secret (#389)
PiperOrigin-RevId: 359285402

Source-Author: Google APIs <noreply@google.com>
Source-Date: Wed Feb 24 07:59:50 2021 -0800
Source-Repo: googleapis/googleapis
Source-Sha: 8b3d36daaf5561496b7d4075fba4f2c52d18ca1c
Source-Link: googleapis/googleapis@8b3d36d
  • Loading branch information
yoshi-automation committed Feb 24, 2021
1 parent 4ab50b6 commit 32286cc
Show file tree
Hide file tree
Showing 10 changed files with 1,633 additions and 67 deletions.
Expand Up @@ -188,6 +188,7 @@ public void createSecretTest() throws Exception {
.setReplication(Replication.newBuilder().build())
.setCreateTime(Timestamp.newBuilder().build())
.putAllLabels(new HashMap<String, String>())
.addAllTopics(new ArrayList<Topic>())
.build();
mockSecretManagerService.addResponse(expectedResponse);

Expand Down Expand Up @@ -235,6 +236,7 @@ public void createSecretTest2() throws Exception {
.setReplication(Replication.newBuilder().build())
.setCreateTime(Timestamp.newBuilder().build())
.putAllLabels(new HashMap<String, String>())
.addAllTopics(new ArrayList<Topic>())
.build();
mockSecretManagerService.addResponse(expectedResponse);

Expand Down Expand Up @@ -370,6 +372,7 @@ public void getSecretTest() throws Exception {
.setReplication(Replication.newBuilder().build())
.setCreateTime(Timestamp.newBuilder().build())
.putAllLabels(new HashMap<String, String>())
.addAllTopics(new ArrayList<Topic>())
.build();
mockSecretManagerService.addResponse(expectedResponse);

Expand Down Expand Up @@ -411,6 +414,7 @@ public void getSecretTest2() throws Exception {
.setReplication(Replication.newBuilder().build())
.setCreateTime(Timestamp.newBuilder().build())
.putAllLabels(new HashMap<String, String>())
.addAllTopics(new ArrayList<Topic>())
.build();
mockSecretManagerService.addResponse(expectedResponse);

Expand Down Expand Up @@ -452,6 +456,7 @@ public void updateSecretTest() throws Exception {
.setReplication(Replication.newBuilder().build())
.setCreateTime(Timestamp.newBuilder().build())
.putAllLabels(new HashMap<String, String>())
.addAllTopics(new ArrayList<Topic>())
.build();
mockSecretManagerService.addResponse(expectedResponse);

Expand Down
Expand Up @@ -79,6 +79,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r
internal_static_google_cloud_secretmanager_v1_CustomerManagedEncryptionStatus_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_secretmanager_v1_CustomerManagedEncryptionStatus_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_secretmanager_v1_Topic_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_secretmanager_v1_Topic_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_secretmanager_v1_SecretPayload_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
Expand All @@ -97,70 +101,74 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
+ "google/api/field_behavior.proto\032\031google/"
+ "api/resource.proto\032\036google/protobuf/dura"
+ "tion.proto\032\037google/protobuf/timestamp.pr"
+ "oto\032\034google/api/annotations.proto\"\320\003\n\006Se"
+ "oto\032\034google/api/annotations.proto\"\213\004\n\006Se"
+ "cret\022\021\n\004name\030\001 \001(\tB\003\340A\003\022G\n\013replication\030\002"
+ " \001(\0132*.google.cloud.secretmanager.v1.Rep"
+ "licationB\006\340A\005\340A\002\0224\n\013create_time\030\003 \001(\0132\032."
+ "google.protobuf.TimestampB\003\340A\003\022A\n\006labels"
+ "\030\004 \003(\01321.google.cloud.secretmanager.v1.S"
+ "ecret.LabelsEntry\0226\n\013expire_time\030\006 \001(\0132\032"
+ ".google.protobuf.TimestampB\003\340A\001H\000\022-\n\003ttl"
+ "\030\007 \001(\0132\031.google.protobuf.DurationB\003\340A\004H\000"
+ "\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 "
+ "\001(\t:\0028\001:M\352AJ\n#secretmanager.googleapis.c"
+ "om/Secret\022#projects/{project}/secrets/{s"
+ "ecret}B\014\n\nexpiration\"\337\003\n\rSecretVersion\022\021"
+ "\n\004name\030\001 \001(\tB\003\340A\003\0224\n\013create_time\030\002 \001(\0132\032"
+ ".google.protobuf.TimestampB\003\340A\003\0225\n\014destr"
+ "oy_time\030\003 \001(\0132\032.google.protobuf.Timestam"
+ "pB\003\340A\003\022F\n\005state\030\004 \001(\01622.google.cloud.sec"
+ "retmanager.v1.SecretVersion.StateB\003\340A\003\022L"
+ "\n\022replication_status\030\005 \001(\01320.google.clou"
+ "d.secretmanager.v1.ReplicationStatus\"H\n\005"
+ "State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n\007ENABLED\020"
+ "\001\022\014\n\010DISABLED\020\002\022\r\n\tDESTROYED\020\003:n\352Ak\n*sec"
+ "retmanager.googleapis.com/SecretVersion\022"
+ "=projects/{project}/secrets/{secret}/ver"
+ "sions/{secret_version}\"\220\004\n\013Replication\022I"
+ "\n\tautomatic\030\001 \001(\01324.google.cloud.secretm"
+ "anager.v1.Replication.AutomaticH\000\022N\n\014use"
+ "r_managed\030\002 \001(\01326.google.cloud.secretman"
+ "ager.v1.Replication.UserManagedH\000\032o\n\tAut"
+ "omatic\022b\n\033customer_managed_encryption\030\001 "
+ "\001(\01328.google.cloud.secretmanager.v1.Cust"
+ "omerManagedEncryptionB\003\340A\001\032\345\001\n\013UserManag"
+ "ed\022U\n\010replicas\030\001 \003(\0132>.google.cloud.secr"
+ "etmanager.v1.Replication.UserManaged.Rep"
+ "licaB\003\340A\002\032\177\n\007Replica\022\020\n\010location\030\001 \001(\t\022b"
+ "\n\033customer_managed_encryption\030\002 \001(\01328.go"
+ "ogle.cloud.secretmanager.v1.CustomerMana"
+ "gedEncryptionB\003\340A\001B\r\n\013replication\"6\n\031Cus"
+ "tomerManagedEncryption\022\031\n\014kms_key_name\030\001"
+ " \001(\tB\003\340A\002\"\353\004\n\021ReplicationStatus\022U\n\tautom"
+ "atic\030\001 \001(\0132@.google.cloud.secretmanager."
+ "v1.ReplicationStatus.AutomaticStatusH\000\022Z"
+ "\n\014user_managed\030\002 \001(\0132B.google.cloud.secr"
+ "etmanager.v1.ReplicationStatus.UserManag"
+ "edStatusH\000\032{\n\017AutomaticStatus\022h\n\033custome"
+ "r_managed_encryption\030\001 \001(\0132>.google.clou"
+ "d.secretmanager.v1.CustomerManagedEncryp"
+ "tionStatusB\003\340A\003\032\217\002\n\021UserManagedStatus\022g\n"
+ "\010replicas\030\001 \003(\0132P.google.cloud.secretman"
+ "ager.v1.ReplicationStatus.UserManagedSta"
+ "tus.ReplicaStatusB\003\340A\003\032\220\001\n\rReplicaStatus"
+ "\022\025\n\010location\030\001 \001(\tB\003\340A\003\022h\n\033customer_mana"
+ "ged_encryption\030\002 \001(\0132>.google.cloud.secr"
+ "etmanager.v1.CustomerManagedEncryptionSt"
+ "atusB\003\340A\003B\024\n\022replication_status\"D\n\037Custo"
+ "merManagedEncryptionStatus\022!\n\024kms_key_ve"
+ "rsion_name\030\001 \001(\tB\003\340A\002\"\035\n\rSecretPayload\022\014"
+ "\n\004data\030\001 \001(\014B\355\001\n!com.google.cloud.secret"
+ "manager.v1B\016ResourcesProtoP\001ZJgoogle.gol"
+ "ang.org/genproto/googleapis/cloud/secret"
+ "manager/v1;secretmanager\370\001\001\242\002\003GSM\252\002\035Goog"
+ "le.Cloud.SecretManager.V1\312\002\035Google\\Cloud"
+ "\\SecretManager\\V1\352\002 Google::Cloud::Secre"
+ "tManager::V1b\006proto3"
+ "ecret.LabelsEntry\0229\n\006topics\030\005 \003(\0132$.goog"
+ "le.cloud.secretmanager.v1.TopicB\003\340A\001\0226\n\013"
+ "expire_time\030\006 \001(\0132\032.google.protobuf.Time"
+ "stampB\003\340A\001H\000\022-\n\003ttl\030\007 \001(\0132\031.google.proto"
+ "buf.DurationB\003\340A\004H\000\032-\n\013LabelsEntry\022\013\n\003ke"
+ "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001:M\352AJ\n#secretm"
+ "anager.googleapis.com/Secret\022#projects/{"
+ "project}/secrets/{secret}B\014\n\nexpiration\""
+ "\337\003\n\rSecretVersion\022\021\n\004name\030\001 \001(\tB\003\340A\003\0224\n\013"
+ "create_time\030\002 \001(\0132\032.google.protobuf.Time"
+ "stampB\003\340A\003\0225\n\014destroy_time\030\003 \001(\0132\032.googl"
+ "e.protobuf.TimestampB\003\340A\003\022F\n\005state\030\004 \001(\016"
+ "22.google.cloud.secretmanager.v1.SecretV"
+ "ersion.StateB\003\340A\003\022L\n\022replication_status\030"
+ "\005 \001(\01320.google.cloud.secretmanager.v1.Re"
+ "plicationStatus\"H\n\005State\022\025\n\021STATE_UNSPEC"
+ "IFIED\020\000\022\013\n\007ENABLED\020\001\022\014\n\010DISABLED\020\002\022\r\n\tDE"
+ "STROYED\020\003:n\352Ak\n*secretmanager.googleapis"
+ ".com/SecretVersion\022=projects/{project}/s"
+ "ecrets/{secret}/versions/{secret_version"
+ "}\"\220\004\n\013Replication\022I\n\tautomatic\030\001 \001(\01324.g"
+ "oogle.cloud.secretmanager.v1.Replication"
+ ".AutomaticH\000\022N\n\014user_managed\030\002 \001(\01326.goo"
+ "gle.cloud.secretmanager.v1.Replication.U"
+ "serManagedH\000\032o\n\tAutomatic\022b\n\033customer_ma"
+ "naged_encryption\030\001 \001(\01328.google.cloud.se"
+ "cretmanager.v1.CustomerManagedEncryption"
+ "B\003\340A\001\032\345\001\n\013UserManaged\022U\n\010replicas\030\001 \003(\0132"
+ ">.google.cloud.secretmanager.v1.Replicat"
+ "ion.UserManaged.ReplicaB\003\340A\002\032\177\n\007Replica\022"
+ "\020\n\010location\030\001 \001(\t\022b\n\033customer_managed_en"
+ "cryption\030\002 \001(\01328.google.cloud.secretmana"
+ "ger.v1.CustomerManagedEncryptionB\003\340A\001B\r\n"
+ "\013replication\"6\n\031CustomerManagedEncryptio"
+ "n\022\031\n\014kms_key_name\030\001 \001(\tB\003\340A\002\"\353\004\n\021Replica"
+ "tionStatus\022U\n\tautomatic\030\001 \001(\0132@.google.c"
+ "loud.secretmanager.v1.ReplicationStatus."
+ "AutomaticStatusH\000\022Z\n\014user_managed\030\002 \001(\0132"
+ "B.google.cloud.secretmanager.v1.Replicat"
+ "ionStatus.UserManagedStatusH\000\032{\n\017Automat"
+ "icStatus\022h\n\033customer_managed_encryption\030"
+ "\001 \001(\0132>.google.cloud.secretmanager.v1.Cu"
+ "stomerManagedEncryptionStatusB\003\340A\003\032\217\002\n\021U"
+ "serManagedStatus\022g\n\010replicas\030\001 \003(\0132P.goo"
+ "gle.cloud.secretmanager.v1.ReplicationSt"
+ "atus.UserManagedStatus.ReplicaStatusB\003\340A"
+ "\003\032\220\001\n\rReplicaStatus\022\025\n\010location\030\001 \001(\tB\003\340"
+ "A\003\022h\n\033customer_managed_encryption\030\002 \001(\0132"
+ ">.google.cloud.secretmanager.v1.Customer"
+ "ManagedEncryptionStatusB\003\340A\003B\024\n\022replicat"
+ "ion_status\"D\n\037CustomerManagedEncryptionS"
+ "tatus\022!\n\024kms_key_version_name\030\001 \001(\tB\003\340A\002"
+ "\"_\n\005Topic\022\021\n\004name\030\001 \001(\tB\003\340A\002:C\352A@\n\033pubsu"
+ "b.googleapis.com/Topic\022!projects/{projec"
+ "t}/topics/{topic}\"\035\n\rSecretPayload\022\014\n\004da"
+ "ta\030\001 \001(\014B\355\001\n!com.google.cloud.secretmana"
+ "ger.v1B\016ResourcesProtoP\001ZJgoogle.golang."
+ "org/genproto/googleapis/cloud/secretmana"
+ "ger/v1;secretmanager\370\001\001\242\002\003GSM\252\002\035Google.C"
+ "loud.SecretManager.V1\312\002\035Google\\Cloud\\Sec"
+ "retManager\\V1\352\002 Google::Cloud::SecretMan"
+ "ager::V1b\006proto3"
};
descriptor =
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
Expand All @@ -178,7 +186,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_secretmanager_v1_Secret_descriptor,
new java.lang.String[] {
"Name", "Replication", "CreateTime", "Labels", "ExpireTime", "Ttl", "Expiration",
"Name",
"Replication",
"CreateTime",
"Labels",
"Topics",
"ExpireTime",
"Ttl",
"Expiration",
});
internal_static_google_cloud_secretmanager_v1_Secret_LabelsEntry_descriptor =
internal_static_google_cloud_secretmanager_v1_Secret_descriptor.getNestedTypes().get(0);
Expand Down Expand Up @@ -288,8 +303,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
new java.lang.String[] {
"KmsKeyVersionName",
});
internal_static_google_cloud_secretmanager_v1_SecretPayload_descriptor =
internal_static_google_cloud_secretmanager_v1_Topic_descriptor =
getDescriptor().getMessageTypes().get(6);
internal_static_google_cloud_secretmanager_v1_Topic_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_secretmanager_v1_Topic_descriptor,
new java.lang.String[] {
"Name",
});
internal_static_google_cloud_secretmanager_v1_SecretPayload_descriptor =
getDescriptor().getMessageTypes().get(7);
internal_static_google_cloud_secretmanager_v1_SecretPayload_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_secretmanager_v1_SecretPayload_descriptor,
Expand Down

0 comments on commit 32286cc

Please sign in to comment.