Skip to content

Commit

Permalink
feat: [Dataflow] new parameters in FlexTemplateRuntimeEnvironment (#5087
Browse files Browse the repository at this point in the history
)

* feat: new parameters in FlexTemplateRuntimeEnvironment fix: added google.api.http annotations to RPCs

Committer: @alexander-fenster
PiperOrigin-RevId: 425662603

Source-Link: googleapis/googleapis@9d0fe54

Source-Link: googleapis/googleapis-gen@f427d78
Copy-Tag: eyJwIjoiRGF0YWZsb3cvLk93bEJvdC55YW1sIiwiaCI6ImY0MjdkNzhlNzhkY2JjMmJkNzk5MWFmMjgzMzEwOGYxZGQyYmMxM2UifQ==

* 🦉 Updates from OwlBot

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Feb 10, 2022
1 parent 0a38493 commit 2823f6f
Show file tree
Hide file tree
Showing 23 changed files with 833 additions and 37 deletions.
Binary file modified Dataflow/metadata/V1Beta3/Jobs.php
Binary file not shown.
Binary file modified Dataflow/metadata/V1Beta3/Messages.php
Binary file not shown.
Binary file modified Dataflow/metadata/V1Beta3/Metrics.php
Binary file not shown.
Binary file modified Dataflow/metadata/V1Beta3/Snapshots.php
Binary file not shown.
Binary file modified Dataflow/metadata/V1Beta3/Templates.php
Binary file not shown.
12 changes: 4 additions & 8 deletions Dataflow/src/V1beta3/AutoscalingEvent.php

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Dataflow/src/V1beta3/BigTableIODetails.php

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

194 changes: 194 additions & 0 deletions Dataflow/src/V1beta3/FlexTemplateRuntimeEnvironment.php

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 11 additions & 1 deletion Dataflow/src/V1beta3/Gapic/FlexTemplatesServiceGapicClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@
namespace Google\Cloud\Dataflow\V1beta3\Gapic;

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;
Expand Down Expand Up @@ -225,8 +226,10 @@ public function __construct(array $options = [])
public function launchFlexTemplate(array $optionalArgs = [])
{
$request = new LaunchFlexTemplateRequest();
$requestParamHeaders = [];
if (isset($optionalArgs['projectId'])) {
$request->setProjectId($optionalArgs['projectId']);
$requestParamHeaders['project_id'] = $optionalArgs['projectId'];
}

if (isset($optionalArgs['launchParameter'])) {
Expand All @@ -235,12 +238,19 @@ public function launchFlexTemplate(array $optionalArgs = [])

if (isset($optionalArgs['location'])) {
$request->setLocation($optionalArgs['location']);
$requestParamHeaders['location'] = $optionalArgs['location'];
}

if (isset($optionalArgs['validateOnly'])) {
$request->setValidateOnly($optionalArgs['validateOnly']);
}

$requestParams = new RequestParamsHeaderDescriptor(
$requestParamHeaders
);
$optionalArgs['headers'] = isset($optionalArgs['headers'])
? array_merge($requestParams->getHeader(), $optionalArgs['headers'])
: $requestParams->getHeader();
return $this->startCall(
'LaunchFlexTemplate',
LaunchFlexTemplateResponse::class,
Expand Down
Loading

0 comments on commit 2823f6f

Please sign in to comment.