Class: Google::Apis::LoggingV1beta3::LogSink

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

Overview

Describes where log entries are written outside of Cloud Logging.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ LogSink

Returns a new instance of LogSink



511
512
513
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 511

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

Instance Attribute Details

#destinationString

The resource name of the destination. Cloud Logging writes designated log entries to this destination. For example, "storage.googleapis.com/my-output- bucket". Corresponds to the JSON property destination

Returns:

  • (String)


496
497
498
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 496

def destination
  @destination
end

#errorsArray<Google::Apis::LoggingV1beta3::LogError>

Output only. If any errors occur when invoking a sink method, then this field contains descriptions of the errors. Corresponds to the JSON property errors



509
510
511
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 509

def errors
  @errors
end

#filterString

An advanced logs filter. If present, only log entries matching the filter are written. Only project sinks use this field; log sinks and log service sinks must not include a filter. Corresponds to the JSON property filter

Returns:

  • (String)


503
504
505
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 503

def filter
  @filter
end

#nameString

The client-assigned name of this sink. For example, "my-syslog-sink". The name must be unique among the sinks of a similar kind in the project. Corresponds to the JSON property name

Returns:

  • (String)


489
490
491
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 489

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



516
517
518
519
520
521
# File 'generated/google/apis/logging_v1beta3/classes.rb', line 516

def update!(**args)
  @name = args[:name] unless args[:name].nil?
  @destination = args[:destination] unless args[:destination].nil?
  @filter = args[:filter] unless args[:filter].nil?
  @errors = args[:errors] unless args[:errors].nil?
end