Class: Google::Apis::BatchV1::JobNotification
- Inherits:
-
Object
- Object
- Google::Apis::BatchV1::JobNotification
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/batch_v1/classes.rb,
lib/google/apis/batch_v1/representations.rb,
lib/google/apis/batch_v1/representations.rb
Overview
Notification configurations.
Instance Attribute Summary collapse
-
#message ⇒ Google::Apis::BatchV1::Message
Message details.
-
#pubsub_topic ⇒ String
The Pub/Sub topic where notifications like the job state changes will be published.
Instance Method Summary collapse
-
#initialize(**args) ⇒ JobNotification
constructor
A new instance of JobNotification.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ JobNotification
Returns a new instance of JobNotification.
1273 1274 1275 |
# File 'lib/google/apis/batch_v1/classes.rb', line 1273 def initialize(**args) update!(**args) end |
Instance Attribute Details
#message ⇒ Google::Apis::BatchV1::Message
Message details. Describe the conditions under which messages will be sent. If
no attribute is defined, no message will be sent by default. One message
should specify either the job or the task level attributes, but not both. For
example, job level: JOB_STATE_CHANGED and/or a specified new_job_state; task
level: TASK_STATE_CHANGED and/or a specified new_task_state.
Corresponds to the JSON property message
1263 1264 1265 |
# File 'lib/google/apis/batch_v1/classes.rb', line 1263 def @message end |
#pubsub_topic ⇒ String
The Pub/Sub topic where notifications like the job state changes will be
published. The topic must exist in the same project as the job and billings
will be charged to this project. If not specified, no Pub/Sub messages will be
sent. Topic format: projects/project/topics/topic`.
Corresponds to the JSON propertypubsubTopic`
1271 1272 1273 |
# File 'lib/google/apis/batch_v1/classes.rb', line 1271 def pubsub_topic @pubsub_topic end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1278 1279 1280 1281 |
# File 'lib/google/apis/batch_v1/classes.rb', line 1278 def update!(**args) @message = args[:message] if args.key?(:message) @pubsub_topic = args[:pubsub_topic] if args.key?(:pubsub_topic) end |