-
Notifications
You must be signed in to change notification settings - Fork 427
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: A new value
NVIDIA_H100_80GB
is added to enum `AcceleratorTyp…
…e` (#7134) feat: A new enum `HarmSeverity` is added feat: A new field `probability_score` is added to message `.google.cloud.aiplatform.v1.SafetyRating` feat: A new field `severity` is added to message `.google.cloud.aiplatform.v1.SafetyRating` feat: A new field `severity_score` is added to message `.google.cloud.aiplatform.v1.SafetyRating` feat: A new value `BLOCKLIST` is added to enum `FinishReason` feat: A new value `PROHIBITED_CONTENT` is added to enum `FinishReason` feat: A new value `SPII` is added to enum `FinishReason` feat: A new field `grounding_metadata` is added to message `.google.cloud.aiplatform.v1.Candidate` feat: A new message `Segment` is added feat: A new message `GroundingAttribution` is added feat: A new message `GroundingMetadata` is added feat: A new field `display_name` is added to message `.google.cloud.aiplatform.v1.DatasetVersion` feat: A new field `metadata` is added to message `.google.cloud.aiplatform.v1.DatasetVersion` feat: A new field `project_number` is added to message `.google.cloud.aiplatform.v1.FeatureView` feat: A new message `SyncSummary` is added feat: A new field `sync_summary` is added to message `.google.cloud.aiplatform.v1.FeatureViewSync` feat: A new value `NOT_EQUAL` is added to enum `Operator` feat: A new message `BaseModelSource` is added feat: A new field `base_model_source` is added to message `.google.cloud.aiplatform.v1.Model` feat: A new message `ModelGardenSource` is added feat: A new message `GenieSource` is added feat: A new method `BatchDeletePipelineJobs` is added to service `PipelineService` feat: A new method `BatchCancelPipelineJobs` is added to service `PipelineService` feat: A new message `BatchCancelPipelineJobsOperationMetadata` is added feat: A new message `BatchDeletePipelineJobsRequest` is added feat: A new message `BatchDeletePipelineJobsResponse` is added feat: A new message `BatchCancelPipelineJobsRequest` is added feat: A new message `BatchCancelPipelineJobsResponse` is added feat: A new field `retrieval` is added to message `.google.cloud.aiplatform.v1.Tool` feat: A new field `google_search_retrieval` is added to message `.google.cloud.aiplatform.v1.Tool` feat: A new message `Retrieval` is added feat: A new message `VertexAISearch` is added feat: A new message `GoogleSearchRetrieval` is added docs: various documentation improvements PiperOrigin-RevId: 614723899 Source-Link: googleapis/googleapis@eebdbe4 Source-Link: googleapis/googleapis-gen@e9faa30 Copy-Tag: eyJwIjoiQWlQbGF0Zm9ybS8uT3dsQm90LnlhbWwiLCJoIjoiZTlmYWEzMGVkYjE4NWQyZjIyYWU4M2U0ZWI5NTQxNGY0MjE5NGViNyJ9
- Loading branch information
1 parent
837d8cb
commit f5eb49c
Showing
78 changed files
with
4,749 additions
and
97 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
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
104 changes: 104 additions & 0 deletions
104
AiPlatform/samples/V1/PipelineServiceClient/batch_cancel_pipeline_jobs.php
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,104 @@ | ||
<?php | ||
/* | ||
* Copyright 2024 Google LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/* | ||
* GENERATED CODE WARNING | ||
* This file was automatically generated - do not edit! | ||
*/ | ||
|
||
require_once __DIR__ . '/../../../vendor/autoload.php'; | ||
|
||
// [START aiplatform_v1_generated_PipelineService_BatchCancelPipelineJobs_sync] | ||
use Google\ApiCore\ApiException; | ||
use Google\ApiCore\OperationResponse; | ||
use Google\Cloud\AIPlatform\V1\BatchCancelPipelineJobsRequest; | ||
use Google\Cloud\AIPlatform\V1\BatchCancelPipelineJobsResponse; | ||
use Google\Cloud\AIPlatform\V1\Client\PipelineServiceClient; | ||
use Google\Rpc\Status; | ||
|
||
/** | ||
* Batch cancel PipelineJobs. | ||
* Firstly the server will check if all the jobs are in non-terminal states, | ||
* and skip the jobs that are already terminated. | ||
* If the operation failed, none of the pipeline jobs are cancelled. | ||
* The server will poll the states of all the pipeline jobs periodically | ||
* to check the cancellation status. | ||
* This operation will return an LRO. | ||
* | ||
* @param string $formattedParent The name of the PipelineJobs' parent resource. | ||
* Format: `projects/{project}/locations/{location}` | ||
* Please see {@see PipelineServiceClient::locationName()} for help formatting this field. | ||
* @param string $formattedNamesElement The names of the PipelineJobs to cancel. | ||
* A maximum of 32 PipelineJobs can be cancelled in a batch. | ||
* Format: | ||
* `projects/{project}/locations/{location}/pipelineJobs/{pipelineJob}` | ||
* Please see {@see PipelineServiceClient::pipelineJobName()} for help formatting this field. | ||
*/ | ||
function batch_cancel_pipeline_jobs_sample( | ||
string $formattedParent, | ||
string $formattedNamesElement | ||
): void { | ||
// Create a client. | ||
$pipelineServiceClient = new PipelineServiceClient(); | ||
|
||
// Prepare the request message. | ||
$formattedNames = [$formattedNamesElement,]; | ||
$request = (new BatchCancelPipelineJobsRequest()) | ||
->setParent($formattedParent) | ||
->setNames($formattedNames); | ||
|
||
// Call the API and handle any network failures. | ||
try { | ||
/** @var OperationResponse $response */ | ||
$response = $pipelineServiceClient->batchCancelPipelineJobs($request); | ||
$response->pollUntilComplete(); | ||
|
||
if ($response->operationSucceeded()) { | ||
/** @var BatchCancelPipelineJobsResponse $result */ | ||
$result = $response->getResult(); | ||
printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); | ||
} else { | ||
/** @var Status $error */ | ||
$error = $response->getError(); | ||
printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); | ||
} | ||
} catch (ApiException $ex) { | ||
printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); | ||
} | ||
} | ||
|
||
/** | ||
* Helper to execute the sample. | ||
* | ||
* This sample has been automatically generated and should be regarded as a code | ||
* template only. It will require modifications to work: | ||
* - It may require correct/in-range values for request initialization. | ||
* - It may require specifying regional endpoints when creating the service client, | ||
* please see the apiEndpoint client configuration option for more details. | ||
*/ | ||
function callSample(): void | ||
{ | ||
$formattedParent = PipelineServiceClient::locationName('[PROJECT]', '[LOCATION]'); | ||
$formattedNamesElement = PipelineServiceClient::pipelineJobName( | ||
'[PROJECT]', | ||
'[LOCATION]', | ||
'[PIPELINE_JOB]' | ||
); | ||
|
||
batch_cancel_pipeline_jobs_sample($formattedParent, $formattedNamesElement); | ||
} | ||
// [END aiplatform_v1_generated_PipelineService_BatchCancelPipelineJobs_sync] |
100 changes: 100 additions & 0 deletions
100
AiPlatform/samples/V1/PipelineServiceClient/batch_delete_pipeline_jobs.php
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,100 @@ | ||
<?php | ||
/* | ||
* Copyright 2024 Google LLC | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
/* | ||
* GENERATED CODE WARNING | ||
* This file was automatically generated - do not edit! | ||
*/ | ||
|
||
require_once __DIR__ . '/../../../vendor/autoload.php'; | ||
|
||
// [START aiplatform_v1_generated_PipelineService_BatchDeletePipelineJobs_sync] | ||
use Google\ApiCore\ApiException; | ||
use Google\ApiCore\OperationResponse; | ||
use Google\Cloud\AIPlatform\V1\BatchDeletePipelineJobsRequest; | ||
use Google\Cloud\AIPlatform\V1\BatchDeletePipelineJobsResponse; | ||
use Google\Cloud\AIPlatform\V1\Client\PipelineServiceClient; | ||
use Google\Rpc\Status; | ||
|
||
/** | ||
* Batch deletes PipelineJobs | ||
* The Operation is atomic. If it fails, none of the PipelineJobs are deleted. | ||
* If it succeeds, all of the PipelineJobs are deleted. | ||
* | ||
* @param string $formattedParent The name of the PipelineJobs' parent resource. | ||
* Format: `projects/{project}/locations/{location}` | ||
* Please see {@see PipelineServiceClient::locationName()} for help formatting this field. | ||
* @param string $formattedNamesElement The names of the PipelineJobs to delete. | ||
* A maximum of 32 PipelineJobs can be deleted in a batch. | ||
* Format: | ||
* `projects/{project}/locations/{location}/pipelineJobs/{pipelineJob}` | ||
* Please see {@see PipelineServiceClient::pipelineJobName()} for help formatting this field. | ||
*/ | ||
function batch_delete_pipeline_jobs_sample( | ||
string $formattedParent, | ||
string $formattedNamesElement | ||
): void { | ||
// Create a client. | ||
$pipelineServiceClient = new PipelineServiceClient(); | ||
|
||
// Prepare the request message. | ||
$formattedNames = [$formattedNamesElement,]; | ||
$request = (new BatchDeletePipelineJobsRequest()) | ||
->setParent($formattedParent) | ||
->setNames($formattedNames); | ||
|
||
// Call the API and handle any network failures. | ||
try { | ||
/** @var OperationResponse $response */ | ||
$response = $pipelineServiceClient->batchDeletePipelineJobs($request); | ||
$response->pollUntilComplete(); | ||
|
||
if ($response->operationSucceeded()) { | ||
/** @var BatchDeletePipelineJobsResponse $result */ | ||
$result = $response->getResult(); | ||
printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); | ||
} else { | ||
/** @var Status $error */ | ||
$error = $response->getError(); | ||
printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); | ||
} | ||
} catch (ApiException $ex) { | ||
printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); | ||
} | ||
} | ||
|
||
/** | ||
* Helper to execute the sample. | ||
* | ||
* This sample has been automatically generated and should be regarded as a code | ||
* template only. It will require modifications to work: | ||
* - It may require correct/in-range values for request initialization. | ||
* - It may require specifying regional endpoints when creating the service client, | ||
* please see the apiEndpoint client configuration option for more details. | ||
*/ | ||
function callSample(): void | ||
{ | ||
$formattedParent = PipelineServiceClient::locationName('[PROJECT]', '[LOCATION]'); | ||
$formattedNamesElement = PipelineServiceClient::pipelineJobName( | ||
'[PROJECT]', | ||
'[LOCATION]', | ||
'[PIPELINE_JOB]' | ||
); | ||
|
||
batch_delete_pipeline_jobs_sample($formattedParent, $formattedNamesElement); | ||
} | ||
// [END aiplatform_v1_generated_PipelineService_BatchDeletePipelineJobs_sync] |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.