Skip to content

Commit bc19f31

Browse files
vertex-sdk-botcopybara-github
authored andcommitted
feat: Adds cancel_query_job to SDK for agent engine long running async tasks.
PiperOrigin-RevId: 899660067
1 parent 90e3f69 commit bc19f31

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

src/genai/types/common.ts

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2571,6 +2571,34 @@ export declare interface RunQueryJobResult {
25712571
outputGcsUri?: string;
25722572
}
25732573

2574+
/** Config for canceling async querying agent engines. */
2575+
export declare interface CancelQueryJobAgentEngineConfig {
2576+
/** Used to override HTTP request options. */
2577+
httpOptions?: genaiTypes.HttpOptions;
2578+
/** Abort signal which can be used to cancel the request.
2579+
2580+
NOTE: AbortSignal is a client-only operation. Using it to cancel an
2581+
operation will not cancel the request in the service. You will still
2582+
be charged usage for any applicable operations.
2583+
*/
2584+
abortSignal?: AbortSignal;
2585+
/** Name of the longrunning operation returned from run_query_job. */
2586+
operationName?: string;
2587+
}
2588+
2589+
/** Result of canceling a query job. */
2590+
export declare interface CancelQueryJobResult {
2591+
/** Used to override HTTP request options. */
2592+
httpOptions?: genaiTypes.HttpOptions;
2593+
/** Abort signal which can be used to cancel the request.
2594+
2595+
NOTE: AbortSignal is a client-only operation. Using it to cancel an
2596+
operation will not cancel the request in the service. You will still
2597+
be charged usage for any applicable operations.
2598+
*/
2599+
abortSignal?: AbortSignal;
2600+
}
2601+
25742602
/** Config for async querying agent engines. */
25752603
export declare interface CheckQueryJobAgentEngineConfig {
25762604
/** Used to override HTTP request options. */

0 commit comments

Comments
 (0)