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

Commit d38deef

Browse files
feat: added fallback option when restoring an agent (#164)
This PR was generated using Autosynth. 🌈 Synth log will be available here: https://source.cloud.google.com/results/invocations/50a12256-ca5e-4f80-a8f2-ba3c4ab12a2c/targets - [ ] To automatically regenerate this PR, check this box. PiperOrigin-RevId: 362090097 Source-Link: googleapis/googleapis@4b16c60 docs: clarified experiment length
1 parent 31372a4 commit d38deef

File tree

12 files changed

+609
-189
lines changed

12 files changed

+609
-189
lines changed

google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/AgentsClientTest.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -577,6 +577,7 @@ public void restoreAgentTest() throws Exception {
577577
Assert.assertEquals(request.getName(), actualRequest.getName());
578578
Assert.assertEquals(request.getAgentUri(), actualRequest.getAgentUri());
579579
Assert.assertEquals(request.getAgentContent(), actualRequest.getAgentContent());
580+
Assert.assertEquals(request.getRestoreOption(), actualRequest.getRestoreOption());
580581
Assert.assertTrue(
581582
channelProvider.isHeaderSent(
582583
ApiClientHeaderProvider.getDefaultApiClientHeaderKey(),

proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentProto.java

Lines changed: 68 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -135,72 +135,76 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
135135
+ "\340A\002\372A!\n\037dialogflow.googleapis.com/Agent\022"
136136
+ "\026\n\tagent_uri\030\002 \001(\tB\003\340A\001\"L\n\023ExportAgentRe"
137137
+ "sponse\022\023\n\tagent_uri\030\001 \001(\tH\000\022\027\n\ragent_con"
138-
+ "tent\030\002 \001(\014H\000B\007\n\005agent\"\203\001\n\023RestoreAgentRe"
138+
+ "tent\030\002 \001(\014H\000B\007\n\005agent\"\246\002\n\023RestoreAgentRe"
139139
+ "quest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037dialogflow."
140140
+ "googleapis.com/Agent\022\023\n\tagent_uri\030\002 \001(\tH"
141-
+ "\000\022\027\n\ragent_content\030\003 \001(\014H\000B\007\n\005agent\"d\n\024V"
142-
+ "alidateAgentRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A"
143-
+ "!\n\037dialogflow.googleapis.com/Agent\022\025\n\rla"
144-
+ "nguage_code\030\002 \001(\t\"\177\n\037GetAgentValidationR"
145-
+ "esultRequest\022E\n\004name\030\001 \001(\tB7\340A\002\372A1\n/dial"
146-
+ "ogflow.googleapis.com/AgentValidationRes"
147-
+ "ult\022\025\n\rlanguage_code\030\002 \001(\t\"\372\001\n\025AgentVali"
148-
+ "dationResult\022\014\n\004name\030\001 \001(\t\022T\n\027flow_valid"
149-
+ "ation_results\030\002 \003(\01323.google.cloud.dialo"
150-
+ "gflow.cx.v3.FlowValidationResult:}\352Az\n/d"
141+
+ "\000\022\027\n\ragent_content\030\003 \001(\014H\000\022X\n\016restore_op"
142+
+ "tion\030\005 \001(\0162@.google.cloud.dialogflow.cx."
143+
+ "v3.RestoreAgentRequest.RestoreOption\"G\n\r"
144+
+ "RestoreOption\022\036\n\032RESTORE_OPTION_UNSPECIF"
145+
+ "IED\020\000\022\010\n\004KEEP\020\001\022\014\n\010FALLBACK\020\002B\007\n\005agent\"d"
146+
+ "\n\024ValidateAgentRequest\0225\n\004name\030\001 \001(\tB\'\340A"
147+
+ "\002\372A!\n\037dialogflow.googleapis.com/Agent\022\025\n"
148+
+ "\rlanguage_code\030\002 \001(\t\"\177\n\037GetAgentValidati"
149+
+ "onResultRequest\022E\n\004name\030\001 \001(\tB7\340A\002\372A1\n/d"
151150
+ "ialogflow.googleapis.com/AgentValidation"
152-
+ "Result\022Gprojects/{project}/locations/{lo"
153-
+ "cation}/agents/{agent}/validationResult2"
154-
+ "\231\016\n\006Agents\022\256\001\n\nListAgents\0220.google.cloud"
155-
+ ".dialogflow.cx.v3.ListAgentsRequest\0321.go"
156-
+ "ogle.cloud.dialogflow.cx.v3.ListAgentsRe"
157-
+ "sponse\";\202\323\344\223\002,\022*/v3/{parent=projects/*/l"
158-
+ "ocations/*}/agents\332A\006parent\022\233\001\n\010GetAgent"
159-
+ "\022..google.cloud.dialogflow.cx.v3.GetAgen"
160-
+ "tRequest\032$.google.cloud.dialogflow.cx.v3"
161-
+ ".Agent\"9\202\323\344\223\002,\022*/v3/{name=projects/*/loc"
162-
+ "ations/*/agents/*}\332A\004name\022\260\001\n\013CreateAgen"
163-
+ "t\0221.google.cloud.dialogflow.cx.v3.Create"
164-
+ "AgentRequest\032$.google.cloud.dialogflow.c"
165-
+ "x.v3.Agent\"H\202\323\344\223\0023\"*/v3/{parent=projects"
166-
+ "/*/locations/*}/agents:\005agent\332A\014parent,a"
167-
+ "gent\022\273\001\n\013UpdateAgent\0221.google.cloud.dial"
168-
+ "ogflow.cx.v3.UpdateAgentRequest\032$.google"
169-
+ ".cloud.dialogflow.cx.v3.Agent\"S\202\323\344\223\002920/"
170-
+ "v3/{agent.name=projects/*/locations/*/ag"
171-
+ "ents/*}:\005agent\332A\021agent,update_mask\022\223\001\n\013D"
172-
+ "eleteAgent\0221.google.cloud.dialogflow.cx."
173-
+ "v3.DeleteAgentRequest\032\026.google.protobuf."
174-
+ "Empty\"9\202\323\344\223\002,**/v3/{name=projects/*/loca"
175-
+ "tions/*/agents/*}\332A\004name\022\315\001\n\013ExportAgent"
176-
+ "\0221.google.cloud.dialogflow.cx.v3.ExportA"
177-
+ "gentRequest\032\035.google.longrunning.Operati"
178-
+ "on\"l\202\323\344\223\0026\"1/v3/{name=projects/*/locatio"
179-
+ "ns/*/agents/*}:export:\001*\312A-\n\023ExportAgent"
180-
+ "Response\022\026google.protobuf.Struct\022\322\001\n\014Res"
181-
+ "toreAgent\0222.google.cloud.dialogflow.cx.v"
182-
+ "3.RestoreAgentRequest\032\035.google.longrunni"
183-
+ "ng.Operation\"o\202\323\344\223\0027\"2/v3/{name=projects"
184-
+ "/*/locations/*/agents/*}:restore:\001*\312A/\n\025"
185-
+ "google.protobuf.Empty\022\026google.protobuf.S"
186-
+ "truct\022\272\001\n\rValidateAgent\0223.google.cloud.d"
187-
+ "ialogflow.cx.v3.ValidateAgentRequest\0324.g"
188-
+ "oogle.cloud.dialogflow.cx.v3.AgentValida"
189-
+ "tionResult\">\202\323\344\223\0028\"3/v3/{name=projects/*"
190-
+ "/locations/*/agents/*}:validate:\001*\022\334\001\n\030G"
191-
+ "etAgentValidationResult\022>.google.cloud.d"
192-
+ "ialogflow.cx.v3.GetAgentValidationResult"
193-
+ "Request\0324.google.cloud.dialogflow.cx.v3."
194-
+ "AgentValidationResult\"J\202\323\344\223\002=\022;/v3/{name"
195-
+ "=projects/*/locations/*/agents/*/validat"
196-
+ "ionResult}\332A\004name\032x\312A\031dialogflow.googlea"
197-
+ "pis.com\322AYhttps://www.googleapis.com/aut"
198-
+ "h/cloud-platform,https://www.googleapis."
199-
+ "com/auth/dialogflowB\232\001\n!com.google.cloud"
200-
+ ".dialogflow.cx.v3B\nAgentProtoP\001Z?google."
201-
+ "golang.org/genproto/googleapis/cloud/dia"
202-
+ "logflow/cx/v3;cx\370\001\001\242\002\002DF\252\002\035Google.Cloud."
203-
+ "Dialogflow.Cx.V3b\006proto3"
151+
+ "Result\022\025\n\rlanguage_code\030\002 \001(\t\"\372\001\n\025AgentV"
152+
+ "alidationResult\022\014\n\004name\030\001 \001(\t\022T\n\027flow_va"
153+
+ "lidation_results\030\002 \003(\01323.google.cloud.di"
154+
+ "alogflow.cx.v3.FlowValidationResult:}\352Az"
155+
+ "\n/dialogflow.googleapis.com/AgentValidat"
156+
+ "ionResult\022Gprojects/{project}/locations/"
157+
+ "{location}/agents/{agent}/validationResu"
158+
+ "lt2\231\016\n\006Agents\022\256\001\n\nListAgents\0220.google.cl"
159+
+ "oud.dialogflow.cx.v3.ListAgentsRequest\0321"
160+
+ ".google.cloud.dialogflow.cx.v3.ListAgent"
161+
+ "sResponse\";\202\323\344\223\002,\022*/v3/{parent=projects/"
162+
+ "*/locations/*}/agents\332A\006parent\022\233\001\n\010GetAg"
163+
+ "ent\022..google.cloud.dialogflow.cx.v3.GetA"
164+
+ "gentRequest\032$.google.cloud.dialogflow.cx"
165+
+ ".v3.Agent\"9\202\323\344\223\002,\022*/v3/{name=projects/*/"
166+
+ "locations/*/agents/*}\332A\004name\022\260\001\n\013CreateA"
167+
+ "gent\0221.google.cloud.dialogflow.cx.v3.Cre"
168+
+ "ateAgentRequest\032$.google.cloud.dialogflo"
169+
+ "w.cx.v3.Agent\"H\202\323\344\223\0023\"*/v3/{parent=proje"
170+
+ "cts/*/locations/*}/agents:\005agent\332A\014paren"
171+
+ "t,agent\022\273\001\n\013UpdateAgent\0221.google.cloud.d"
172+
+ "ialogflow.cx.v3.UpdateAgentRequest\032$.goo"
173+
+ "gle.cloud.dialogflow.cx.v3.Agent\"S\202\323\344\223\0029"
174+
+ "20/v3/{agent.name=projects/*/locations/*"
175+
+ "/agents/*}:\005agent\332A\021agent,update_mask\022\223\001"
176+
+ "\n\013DeleteAgent\0221.google.cloud.dialogflow."
177+
+ "cx.v3.DeleteAgentRequest\032\026.google.protob"
178+
+ "uf.Empty\"9\202\323\344\223\002,**/v3/{name=projects/*/l"
179+
+ "ocations/*/agents/*}\332A\004name\022\315\001\n\013ExportAg"
180+
+ "ent\0221.google.cloud.dialogflow.cx.v3.Expo"
181+
+ "rtAgentRequest\032\035.google.longrunning.Oper"
182+
+ "ation\"l\202\323\344\223\0026\"1/v3/{name=projects/*/loca"
183+
+ "tions/*/agents/*}:export:\001*\312A-\n\023ExportAg"
184+
+ "entResponse\022\026google.protobuf.Struct\022\322\001\n\014"
185+
+ "RestoreAgent\0222.google.cloud.dialogflow.c"
186+
+ "x.v3.RestoreAgentRequest\032\035.google.longru"
187+
+ "nning.Operation\"o\202\323\344\223\0027\"2/v3/{name=proje"
188+
+ "cts/*/locations/*/agents/*}:restore:\001*\312A"
189+
+ "/\n\025google.protobuf.Empty\022\026google.protobu"
190+
+ "f.Struct\022\272\001\n\rValidateAgent\0223.google.clou"
191+
+ "d.dialogflow.cx.v3.ValidateAgentRequest\032"
192+
+ "4.google.cloud.dialogflow.cx.v3.AgentVal"
193+
+ "idationResult\">\202\323\344\223\0028\"3/v3/{name=project"
194+
+ "s/*/locations/*/agents/*}:validate:\001*\022\334\001"
195+
+ "\n\030GetAgentValidationResult\022>.google.clou"
196+
+ "d.dialogflow.cx.v3.GetAgentValidationRes"
197+
+ "ultRequest\0324.google.cloud.dialogflow.cx."
198+
+ "v3.AgentValidationResult\"J\202\323\344\223\002=\022;/v3/{n"
199+
+ "ame=projects/*/locations/*/agents/*/vali"
200+
+ "dationResult}\332A\004name\032x\312A\031dialogflow.goog"
201+
+ "leapis.com\322AYhttps://www.googleapis.com/"
202+
+ "auth/cloud-platform,https://www.googleap"
203+
+ "is.com/auth/dialogflowB\232\001\n!com.google.cl"
204+
+ "oud.dialogflow.cx.v3B\nAgentProtoP\001Z?goog"
205+
+ "le.golang.org/genproto/googleapis/cloud/"
206+
+ "dialogflow/cx/v3;cx\370\001\001\242\002\002DF\252\002\035Google.Clo"
207+
+ "ud.Dialogflow.Cx.V3b\006proto3"
204208
};
205209
descriptor =
206210
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
@@ -311,7 +315,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
311315
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
312316
internal_static_google_cloud_dialogflow_cx_v3_RestoreAgentRequest_descriptor,
313317
new java.lang.String[] {
314-
"Name", "AgentUri", "AgentContent", "Agent",
318+
"Name", "AgentUri", "AgentContent", "RestoreOption", "Agent",
315319
});
316320
internal_static_google_cloud_dialogflow_cx_v3_ValidateAgentRequest_descriptor =
317321
getDescriptor().getMessageTypes().get(11);

0 commit comments

Comments
 (0)