- Navigation GuideYou are on a Command (operation) page with structural examples. Use the navigation breadcrumb if you would like to return to the Client landing page.
UpdateTriggerCommand
Updates a trigger definition.
Job arguments may be logged. Do not pass plaintext secrets as arguments. Retrieve secrets from a Glue Connection, Amazon Web Services Secrets Manager or other secret management mechanism if you intend to keep them within the Job.
Example Syntax
Use a bare-bones client and the command you need to make an API call.
import { GlueClient, UpdateTriggerCommand } from "@aws-sdk/client-glue"; // ES Modules import
// const { GlueClient, UpdateTriggerCommand } = require("@aws-sdk/client-glue"); // CommonJS import
const client = new GlueClient(config);
const input = { // UpdateTriggerRequest
Name: "STRING_VALUE", // required
TriggerUpdate: { // TriggerUpdate
Name: "STRING_VALUE",
Description: "STRING_VALUE",
Schedule: "STRING_VALUE",
Actions: [ // ActionList
{ // Action
JobName: "STRING_VALUE",
Arguments: { // GenericMap
"<keys>": "STRING_VALUE",
},
Timeout: Number("int"),
SecurityConfiguration: "STRING_VALUE",
NotificationProperty: { // NotificationProperty
NotifyDelayAfter: Number("int"),
},
CrawlerName: "STRING_VALUE",
},
],
Predicate: { // Predicate
Logical: "AND" || "ANY",
Conditions: [ // ConditionList
{ // Condition
LogicalOperator: "EQUALS",
JobName: "STRING_VALUE",
State: "STARTING" || "RUNNING" || "STOPPING" || "STOPPED" || "SUCCEEDED" || "FAILED" || "TIMEOUT" || "ERROR" || "WAITING" || "EXPIRED",
CrawlerName: "STRING_VALUE",
CrawlState: "RUNNING" || "CANCELLING" || "CANCELLED" || "SUCCEEDED" || "FAILED" || "ERROR",
},
],
},
EventBatchingCondition: { // EventBatchingCondition
BatchSize: Number("int"), // required
BatchWindow: Number("int"),
},
},
};
const command = new UpdateTriggerCommand(input);
const response = await client.send(command);
// { // UpdateTriggerResponse
// Trigger: { // Trigger
// Name: "STRING_VALUE",
// WorkflowName: "STRING_VALUE",
// Id: "STRING_VALUE",
// Type: "SCHEDULED" || "CONDITIONAL" || "ON_DEMAND" || "EVENT",
// State: "CREATING" || "CREATED" || "ACTIVATING" || "ACTIVATED" || "DEACTIVATING" || "DEACTIVATED" || "DELETING" || "UPDATING",
// Description: "STRING_VALUE",
// Schedule: "STRING_VALUE",
// Actions: [ // ActionList
// { // Action
// JobName: "STRING_VALUE",
// Arguments: { // GenericMap
// "<keys>": "STRING_VALUE",
// },
// Timeout: Number("int"),
// SecurityConfiguration: "STRING_VALUE",
// NotificationProperty: { // NotificationProperty
// NotifyDelayAfter: Number("int"),
// },
// CrawlerName: "STRING_VALUE",
// },
// ],
// Predicate: { // Predicate
// Logical: "AND" || "ANY",
// Conditions: [ // ConditionList
// { // Condition
// LogicalOperator: "EQUALS",
// JobName: "STRING_VALUE",
// State: "STARTING" || "RUNNING" || "STOPPING" || "STOPPED" || "SUCCEEDED" || "FAILED" || "TIMEOUT" || "ERROR" || "WAITING" || "EXPIRED",
// CrawlerName: "STRING_VALUE",
// CrawlState: "RUNNING" || "CANCELLING" || "CANCELLED" || "SUCCEEDED" || "FAILED" || "ERROR",
// },
// ],
// },
// EventBatchingCondition: { // EventBatchingCondition
// BatchSize: Number("int"), // required
// BatchWindow: Number("int"),
// },
// },
// };
UpdateTriggerCommand Input
See UpdateTriggerCommandInput for more details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
Name Required | string | undefined | The name of the trigger to update. |
TriggerUpdate Required | TriggerUpdate | undefined | The new values with which to update the trigger. |
UpdateTriggerCommand Output
See UpdateTriggerCommandOutput for details
Parameter | Type | Description |
---|
Parameter | Type | Description |
---|---|---|
$metadata Required | ResponseMetadata | Metadata pertaining to this request. |
Trigger | Trigger | undefined | The resulting trigger definition. |
Throws
Name | Fault | Details |
---|
Name | Fault | Details |
---|---|---|
ConcurrentModificationException | client | Two processes are trying to modify a resource simultaneously. |
EntityNotFoundException | client | A specified entity does not exist |
InternalServiceException | server | An internal service error occurred. |
InvalidInputException | client | The input provided was not valid. |
OperationTimeoutException | client | The operation timed out. |
GlueServiceException | Base exception class for all service exceptions from Glue service. |