From fecec7ef45b63f0483f3425e2a3c3072caf5c190 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot <44816363+yoshi-automation@users.noreply.github.com> Date: Thu, 28 Mar 2019 11:20:04 -0700 Subject: [PATCH] Add additional request name headers (#1754) --- src/V2/Gapic/Controller2GapicClient.php | 8 ++++++++ src/V2/Gapic/Debugger2GapicClient.php | 15 +++++++++++++++ synth.metadata | 10 +++++----- 3 files changed, 28 insertions(+), 5 deletions(-) diff --git a/src/V2/Gapic/Controller2GapicClient.php b/src/V2/Gapic/Controller2GapicClient.php index 2a65f8e..9a7b25a 100644 --- a/src/V2/Gapic/Controller2GapicClient.php +++ b/src/V2/Gapic/Controller2GapicClient.php @@ -29,6 +29,7 @@ use Google\ApiCore\ApiException; use Google\ApiCore\CredentialsWrapper; use Google\ApiCore\GapicClientTrait; +use Google\ApiCore\RequestParamsHeaderDescriptor; use Google\ApiCore\RetrySettings; use Google\ApiCore\Transport\TransportInterface; use Google\ApiCore\ValidationException; @@ -307,6 +308,13 @@ public function listActiveBreakpoints($debuggeeId, array $optionalArgs = []) $request->setSuccessOnTimeout($optionalArgs['successOnTimeout']); } + $requestParams = new RequestParamsHeaderDescriptor([ + 'debuggee_id' => $request->getDebuggeeId(), + ]); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startCall( 'ListActiveBreakpoints', ListActiveBreakpointsResponse::class, diff --git a/src/V2/Gapic/Debugger2GapicClient.php b/src/V2/Gapic/Debugger2GapicClient.php index bb598e1..72d9586 100644 --- a/src/V2/Gapic/Debugger2GapicClient.php +++ b/src/V2/Gapic/Debugger2GapicClient.php @@ -29,6 +29,7 @@ use Google\ApiCore\ApiException; use Google\ApiCore\CredentialsWrapper; use Google\ApiCore\GapicClientTrait; +use Google\ApiCore\RequestParamsHeaderDescriptor; use Google\ApiCore\RetrySettings; use Google\ApiCore\Transport\TransportInterface; use Google\ApiCore\ValidationException; @@ -229,6 +230,13 @@ public function setBreakpoint($debuggeeId, $breakpoint, $clientVersion, array $o $request->setBreakpoint($breakpoint); $request->setClientVersion($clientVersion); + $requestParams = new RequestParamsHeaderDescriptor([ + 'debuggee_id' => $request->getDebuggeeId(), + ]); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startCall( 'SetBreakpoint', SetBreakpointResponse::class, @@ -406,6 +414,13 @@ public function listBreakpoints($debuggeeId, $clientVersion, array $optionalArgs $request->setWaitToken($optionalArgs['waitToken']); } + $requestParams = new RequestParamsHeaderDescriptor([ + 'debuggee_id' => $request->getDebuggeeId(), + ]); + $optionalArgs['headers'] = isset($optionalArgs['headers']) + ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) + : $requestParams->getHeader(); + return $this->startCall( 'ListBreakpoints', ListBreakpointsResponse::class, diff --git a/synth.metadata b/synth.metadata index c3e4b9f..26eb0d5 100644 --- a/synth.metadata +++ b/synth.metadata @@ -1,19 +1,19 @@ { - "updateTime": "2018-12-18T11:00:03.624475Z", + "updateTime": "2019-03-28T09:59:59.062664Z", "sources": [ { "generator": { "name": "artman", - "version": "0.16.3", - "dockerImage": "googleapis/artman@sha256:bfb92654b4a77368471f70e2808eaf4e60f263b9559f27bb3284097322787bf1" + "version": "0.16.20", + "dockerImage": "googleapis/artman@sha256:e3c054a2fb85a12481c722af616c7fb6f1d02d862248385eecbec3e4240ebd1e" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "c04bc0dc0a9164d924a9ab923fd6845b4ae6a7ab", - "internalRef": "225851467" + "sha": "6a84b3267b0a95e922608b9891219075047eee29", + "internalRef": "240640999" } } ],