Class: Google::Apis::RunV1alpha1::CloudPubSubSourceSpec

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/run_v1alpha1/classes.rb,
generated/google/apis/run_v1alpha1/representations.rb,
generated/google/apis/run_v1alpha1/representations.rb

Overview

The desired state of the CloudPubSubSource.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ CloudPubSubSourceSpec

Returns a new instance of CloudPubSubSourceSpec.



516
517
518
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 516

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#ack_deadlineString

AckDeadline is the default maximum time after a subscriber receives a message before the subscriber should acknowledge the message. Defaults to 30 seconds (' 30s'). +optional Corresponds to the JSON property ackDeadline

Returns:

  • (String)


460
461
462
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 460

def ack_deadline
  @ack_deadline
end

#ce_overridesGoogle::Apis::RunV1alpha1::CloudEventOverrides

CloudEventOverrides defines arguments for a Source that control the output format of the CloudEvents produced by the Source. Corresponds to the JSON property ceOverrides



466
467
468
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 466

def ce_overrides
  @ce_overrides
end

#projectString

Project is the ID of the Google Cloud Project that the CloudPubSubSource Topic exists in. If omitted, defaults to same as the cluster. +optional Corresponds to the JSON property project

Returns:

  • (String)


472
473
474
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 472

def project
  @project
end

#pubsub_secretGoogle::Apis::RunV1alpha1::SecretKeySelector

Cloud Run fully managed: not supported Cloud Run on GKE: supported SecretKeySelector selects a key of a Secret. Corresponds to the JSON property pubsubSecret



478
479
480
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 478

def pubsub_secret
  @pubsub_secret
end

#retain_acked_messagesBoolean Also known as: retain_acked_messages?

RetainAckedMessages defines whether to retain acknowledged messages. If true, acknowledged messages will not be expunged until they fall out of the RetentionDuration window. Corresponds to the JSON property retainAckedMessages

Returns:

  • (Boolean)


485
486
487
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 485

def retain_acked_messages
  @retain_acked_messages
end

#retention_durationString

RetentionDuration defines how long to retain messages in backlog, from the time of publish. If RetainAckedMessages is true, this duration affects the retention of acknowledged messages, otherwise only unacknowledged messages are retained. Cannot be longer than 7 days or shorter than 10 minutes. Defaults to 7 days ('7d'). +optional Corresponds to the JSON property retentionDuration

Returns:

  • (String)


495
496
497
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 495

def retention_duration
  @retention_duration
end

#secretGoogle::Apis::RunV1alpha1::SecretKeySelector

Cloud Run fully managed: not supported Cloud Run on GKE: supported SecretKeySelector selects a key of a Secret. Corresponds to the JSON property secret



501
502
503
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 501

def secret
  @secret
end

#sinkGoogle::Apis::RunV1alpha1::Destination

Sink is a reference to an object that will resolve to a domain name or a URI directly to use as the sink. Corresponds to the JSON property sink



507
508
509
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 507

def sink
  @sink
end

#topicString

Topic is the ID of the CloudPubSubSource Topic to Subscribe to. It must be in the form of the unique identifier within the project, not the entire name. E.g. it must be 'laconia', not 'projects/my-proj/topics/laconia'. Corresponds to the JSON property topic

Returns:

  • (String)


514
515
516
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 514

def topic
  @topic
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



521
522
523
524
525
526
527
528
529
530
531
# File 'generated/google/apis/run_v1alpha1/classes.rb', line 521

def update!(**args)
  @ack_deadline = args[:ack_deadline] if args.key?(:ack_deadline)
  @ce_overrides = args[:ce_overrides] if args.key?(:ce_overrides)
  @project = args[:project] if args.key?(:project)
  @pubsub_secret = args[:pubsub_secret] if args.key?(:pubsub_secret)
  @retain_acked_messages = args[:retain_acked_messages] if args.key?(:retain_acked_messages)
  @retention_duration = args[:retention_duration] if args.key?(:retention_duration)
  @secret = args[:secret] if args.key?(:secret)
  @sink = args[:sink] if args.key?(:sink)
  @topic = args[:topic] if args.key?(:topic)
end