diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index 95f5775c6b9..604a90a3364 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -6766,6 +6766,8 @@ components: description: Optional prefix for blobs written to the container. example: logs/ type: string + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' container_name: description: The name of the Azure Blob Storage container to store logs in. @@ -36391,6 +36393,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' client_id: description: Azure AD client ID used for authentication. example: a1b2c3d4-5678-90ab-cdef-1234567890ab @@ -38337,6 +38341,8 @@ components: properties: auth: $ref: '#/components/schemas/ObservabilityPipelineAmazonOpenSearchDestinationAuth' + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' bulk_index: description: The index to write logs to. example: logs-index @@ -38418,6 +38424,8 @@ components: description: S3 bucket name. example: error-logs type: string + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: Unique identifier for the destination component. example: amazon-s3-destination @@ -38539,6 +38547,8 @@ components: description: Name of the Amazon S3 bucket in Security Lake (3-63 characters). example: security-lake-bucket type: string + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' custom_source_name: description: Custom source name for the logs in Security Lake. example: my-custom-source @@ -38598,6 +38608,39 @@ components: role session. type: string type: object + ObservabilityPipelineBufferOptions: + description: Configuration for buffer settings on destination components. + oneOf: + - $ref: '#/components/schemas/ObservabilityPipelineDiskBufferOptions' + - $ref: '#/components/schemas/ObservabilityPipelineMemoryBufferOptions' + - $ref: '#/components/schemas/ObservabilityPipelineMemoryBufferSizeOptions' + ObservabilityPipelineBufferOptionsDiskType: + default: disk + description: The type of the buffer that will be configured, a disk buffer. + enum: + - disk + type: string + x-enum-varnames: + - DISK + ObservabilityPipelineBufferOptionsMemoryType: + default: memory + description: The type of the buffer that will be configured, a memory buffer. + enum: + - memory + type: string + x-enum-varnames: + - MEMORY + ObservabilityPipelineBufferOptionsWhenFull: + default: block + description: Behavior when the buffer is full (block and stop accepting new + events, or drop new events) + enum: + - block + - drop_newest + type: string + x-enum-varnames: + - BLOCK + - DROP_NEWEST ObservabilityPipelineCloudPremDestination: description: 'The `cloud_prem` destination sends logs to Datadog CloudPrem. @@ -38868,6 +38911,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' compression: $ref: '#/components/schemas/ObservabilityPipelineCrowdStrikeNextGenSiemDestinationCompression' encoding: @@ -39093,6 +39138,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: The unique identifier for this component. example: datadog-logs-destination @@ -39347,6 +39394,19 @@ components: type: string x-enum-varnames: - DEDUPE + ObservabilityPipelineDiskBufferOptions: + description: Options for configuring a disk buffer. + properties: + max_size: + description: Maximum size of the disk buffer. + example: 4096 + format: int64 + type: integer + type: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptionsDiskType' + when_full: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptionsWhenFull' + type: object ObservabilityPipelineElasticsearchDestination: description: 'The `elasticsearch` destination writes logs to an Elasticsearch cluster. @@ -39356,6 +39416,8 @@ components: properties: api_version: $ref: '#/components/schemas/ObservabilityPipelineElasticsearchDestinationApiVersion' + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' bulk_index: description: The index to write logs to in Elasticsearch. example: logs-index @@ -39901,6 +39963,8 @@ components: properties: auth: $ref: '#/components/schemas/ObservabilityPipelineGcpAuth' + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' customer_id: description: The Google Chronicle customer ID. example: abcdefg123456789 @@ -39969,6 +40033,8 @@ components: description: Name of the GCS bucket. example: error-logs type: string + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: Unique identifier for the destination component. example: gcs-destination @@ -40053,6 +40119,8 @@ components: properties: auth: $ref: '#/components/schemas/ObservabilityPipelineGcpAuth' + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' encoding: $ref: '#/components/schemas/ObservabilityPipelineGooglePubSubDestinationEncoding' id: @@ -40579,6 +40647,28 @@ components: type: string x-enum-varnames: - LOGSTASH + ObservabilityPipelineMemoryBufferOptions: + description: Options for configuring a memory buffer by byte size. + properties: + max_size: + description: Maximum size of the memory buffer. + example: 4096 + format: int64 + type: integer + type: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptionsMemoryType' + type: object + ObservabilityPipelineMemoryBufferSizeOptions: + description: Options for configuring a memory buffer by queue length. + properties: + max_events: + description: Maximum events for the memory buffer. + example: 500 + format: int64 + type: integer + type: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptionsMemoryType' + type: object ObservabilityPipelineMetadataEntry: description: A custom metadata entry. properties: @@ -40701,6 +40791,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: The unique identifier for this component. example: new-relic-destination @@ -40847,6 +40939,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' bulk_index: description: The index to write logs to. example: logs-index @@ -41560,6 +41654,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: The unique identifier for this component. example: rsyslog-destination @@ -42065,6 +42161,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: The unique identifier for this component. example: sentinelone-destination @@ -42119,6 +42217,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' encoding: $ref: '#/components/schemas/ObservabilityPipelineSocketDestinationEncoding' framing: @@ -42495,6 +42595,8 @@ components: If `false`, Splunk assigns the time the event was received.' example: true type: boolean + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' encoding: $ref: '#/components/schemas/ObservabilityPipelineSplunkHecDestinationEncoding' id: @@ -42619,6 +42721,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' encoding: $ref: '#/components/schemas/ObservabilityPipelineSumoLogicDestinationEncoding' header_custom_fields: @@ -42732,6 +42836,8 @@ components: **Supported pipeline types:** logs' properties: + buffer: + $ref: '#/components/schemas/ObservabilityPipelineBufferOptions' id: description: The unique identifier for this component. example: syslog-ng-destination diff --git a/lib/datadog_api_client/inflector.rb b/lib/datadog_api_client/inflector.rb index 8bcf2052b62..a016b7b240f 100644 --- a/lib/datadog_api_client/inflector.rb +++ b/lib/datadog_api_client/inflector.rb @@ -3364,6 +3364,10 @@ def overrides "v2.observability_pipeline_amazon_security_lake_destination" => "ObservabilityPipelineAmazonSecurityLakeDestination", "v2.observability_pipeline_amazon_security_lake_destination_type" => "ObservabilityPipelineAmazonSecurityLakeDestinationType", "v2.observability_pipeline_aws_auth" => "ObservabilityPipelineAwsAuth", + "v2.observability_pipeline_buffer_options" => "ObservabilityPipelineBufferOptions", + "v2.observability_pipeline_buffer_options_disk_type" => "ObservabilityPipelineBufferOptionsDiskType", + "v2.observability_pipeline_buffer_options_memory_type" => "ObservabilityPipelineBufferOptionsMemoryType", + "v2.observability_pipeline_buffer_options_when_full" => "ObservabilityPipelineBufferOptionsWhenFull", "v2.observability_pipeline_cloud_prem_destination" => "ObservabilityPipelineCloudPremDestination", "v2.observability_pipeline_cloud_prem_destination_type" => "ObservabilityPipelineCloudPremDestinationType", "v2.observability_pipeline_config" => "ObservabilityPipelineConfig", @@ -3397,6 +3401,7 @@ def overrides "v2.observability_pipeline_dedupe_processor" => "ObservabilityPipelineDedupeProcessor", "v2.observability_pipeline_dedupe_processor_mode" => "ObservabilityPipelineDedupeProcessorMode", "v2.observability_pipeline_dedupe_processor_type" => "ObservabilityPipelineDedupeProcessorType", + "v2.observability_pipeline_disk_buffer_options" => "ObservabilityPipelineDiskBufferOptions", "v2.observability_pipeline_elasticsearch_destination" => "ObservabilityPipelineElasticsearchDestination", "v2.observability_pipeline_elasticsearch_destination_api_version" => "ObservabilityPipelineElasticsearchDestinationApiVersion", "v2.observability_pipeline_elasticsearch_destination_data_stream" => "ObservabilityPipelineElasticsearchDestinationDataStream", @@ -3463,6 +3468,8 @@ def overrides "v2.observability_pipeline_kafka_source_type" => "ObservabilityPipelineKafkaSourceType", "v2.observability_pipeline_logstash_source" => "ObservabilityPipelineLogstashSource", "v2.observability_pipeline_logstash_source_type" => "ObservabilityPipelineLogstashSourceType", + "v2.observability_pipeline_memory_buffer_options" => "ObservabilityPipelineMemoryBufferOptions", + "v2.observability_pipeline_memory_buffer_size_options" => "ObservabilityPipelineMemoryBufferSizeOptions", "v2.observability_pipeline_metadata_entry" => "ObservabilityPipelineMetadataEntry", "v2.observability_pipeline_metric_tags_processor" => "ObservabilityPipelineMetricTagsProcessor", "v2.observability_pipeline_metric_tags_processor_rule" => "ObservabilityPipelineMetricTagsProcessorRule", diff --git a/lib/datadog_api_client/v2/models/azure_storage_destination.rb b/lib/datadog_api_client/v2/models/azure_storage_destination.rb index b17e732af9c..7d5d83703f2 100644 --- a/lib/datadog_api_client/v2/models/azure_storage_destination.rb +++ b/lib/datadog_api_client/v2/models/azure_storage_destination.rb @@ -26,6 +26,9 @@ class AzureStorageDestination # Optional prefix for blobs written to the container. attr_accessor :blob_prefix + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The name of the Azure Blob Storage container to store logs in. attr_reader :container_name @@ -45,6 +48,7 @@ class AzureStorageDestination def self.attribute_map { :'blob_prefix' => :'blob_prefix', + :'buffer' => :'buffer', :'container_name' => :'container_name', :'id' => :'id', :'inputs' => :'inputs', @@ -57,6 +61,7 @@ def self.attribute_map def self.openapi_types { :'blob_prefix' => :'String', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'container_name' => :'String', :'id' => :'String', :'inputs' => :'Array', @@ -86,6 +91,10 @@ def initialize(attributes = {}) self.blob_prefix = attributes[:'blob_prefix'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'container_name') self.container_name = attributes[:'container_name'] end @@ -183,6 +192,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && blob_prefix == o.blob_prefix && + buffer == o.buffer && container_name == o.container_name && id == o.id && inputs == o.inputs && @@ -194,7 +204,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [blob_prefix, container_name, id, inputs, type, additional_properties].hash + [blob_prefix, buffer, container_name, id, inputs, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/microsoft_sentinel_destination.rb b/lib/datadog_api_client/v2/models/microsoft_sentinel_destination.rb index 4948de659f0..e3a352437e3 100644 --- a/lib/datadog_api_client/v2/models/microsoft_sentinel_destination.rb +++ b/lib/datadog_api_client/v2/models/microsoft_sentinel_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class MicrosoftSentinelDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Azure AD client ID used for authentication. attr_reader :client_id @@ -50,6 +53,7 @@ class MicrosoftSentinelDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'client_id' => :'client_id', :'dcr_immutable_id' => :'dcr_immutable_id', :'id' => :'id', @@ -64,6 +68,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'client_id' => :'String', :'dcr_immutable_id' => :'String', :'id' => :'String', @@ -92,6 +97,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'client_id') self.client_id = attributes[:'client_id'] end @@ -233,6 +242,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && client_id == o.client_id && dcr_immutable_id == o.dcr_immutable_id && id == o.id && @@ -247,7 +257,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [client_id, dcr_immutable_id, id, inputs, table, tenant_id, type, additional_properties].hash + [buffer, client_id, dcr_immutable_id, id, inputs, table, tenant_id, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_open_search_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_open_search_destination.rb index 44f1c6db5b6..3b517345a7f 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_open_search_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_open_search_destination.rb @@ -27,6 +27,9 @@ class ObservabilityPipelineAmazonOpenSearchDestination # The `strategy` field determines whether basic or AWS-based authentication is used. attr_reader :auth + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The index to write logs to. attr_accessor :bulk_index @@ -46,6 +49,7 @@ class ObservabilityPipelineAmazonOpenSearchDestination def self.attribute_map { :'auth' => :'auth', + :'buffer' => :'buffer', :'bulk_index' => :'bulk_index', :'id' => :'id', :'inputs' => :'inputs', @@ -58,6 +62,7 @@ def self.attribute_map def self.openapi_types { :'auth' => :'ObservabilityPipelineAmazonOpenSearchDestinationAuth', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'bulk_index' => :'String', :'id' => :'String', :'inputs' => :'Array', @@ -87,6 +92,10 @@ def initialize(attributes = {}) self.auth = attributes[:'auth'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'bulk_index') self.bulk_index = attributes[:'bulk_index'] end @@ -184,6 +193,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && auth == o.auth && + buffer == o.buffer && bulk_index == o.bulk_index && id == o.id && inputs == o.inputs && @@ -195,7 +205,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auth, bulk_index, id, inputs, type, additional_properties].hash + [auth, buffer, bulk_index, id, inputs, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_s3_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_s3_destination.rb index aec7f0bbcbf..10e95955f83 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_s3_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_s3_destination.rb @@ -30,6 +30,9 @@ class ObservabilityPipelineAmazonS3Destination # S3 bucket name. attr_reader :bucket + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Unique identifier for the destination component. attr_reader :id @@ -59,6 +62,7 @@ def self.attribute_map { :'auth' => :'auth', :'bucket' => :'bucket', + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'key_prefix' => :'key_prefix', @@ -75,6 +79,7 @@ def self.openapi_types { :'auth' => :'ObservabilityPipelineAwsAuth', :'bucket' => :'String', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'key_prefix' => :'String', @@ -111,6 +116,10 @@ def initialize(attributes = {}) self.bucket = attributes[:'bucket'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -243,6 +252,7 @@ def ==(o) self.class == o.class && auth == o.auth && bucket == o.bucket && + buffer == o.buffer && id == o.id && inputs == o.inputs && key_prefix == o.key_prefix && @@ -257,7 +267,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auth, bucket, id, inputs, key_prefix, region, storage_class, tls, type, additional_properties].hash + [auth, bucket, buffer, id, inputs, key_prefix, region, storage_class, tls, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_security_lake_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_security_lake_destination.rb index 6bc480ae997..59b5386ca03 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_amazon_security_lake_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_amazon_security_lake_destination.rb @@ -30,6 +30,9 @@ class ObservabilityPipelineAmazonSecurityLakeDestination # Name of the Amazon S3 bucket in Security Lake (3-63 characters). attr_reader :bucket + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Custom source name for the logs in Security Lake. attr_reader :custom_source_name @@ -56,6 +59,7 @@ def self.attribute_map { :'auth' => :'auth', :'bucket' => :'bucket', + :'buffer' => :'buffer', :'custom_source_name' => :'custom_source_name', :'id' => :'id', :'inputs' => :'inputs', @@ -71,6 +75,7 @@ def self.openapi_types { :'auth' => :'ObservabilityPipelineAwsAuth', :'bucket' => :'String', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'custom_source_name' => :'String', :'id' => :'String', :'inputs' => :'Array', @@ -106,6 +111,10 @@ def initialize(attributes = {}) self.bucket = attributes[:'bucket'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'custom_source_name') self.custom_source_name = attributes[:'custom_source_name'] end @@ -234,6 +243,7 @@ def ==(o) self.class == o.class && auth == o.auth && bucket == o.bucket && + buffer == o.buffer && custom_source_name == o.custom_source_name && id == o.id && inputs == o.inputs && @@ -247,7 +257,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auth, bucket, custom_source_name, id, inputs, region, tls, type, additional_properties].hash + [auth, bucket, buffer, custom_source_name, id, inputs, region, tls, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options.rb b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options.rb new file mode 100644 index 00000000000..ef7445c56a0 --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options.rb @@ -0,0 +1,64 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Configuration for buffer settings on destination components. + module ObservabilityPipelineBufferOptions + class << self + include BaseOneOfModel + include BaseOneOfModelNoDiscriminator + + # List of class defined in oneOf (OpenAPI v3) + def openapi_one_of + [ + :'ObservabilityPipelineDiskBufferOptions', + :'ObservabilityPipelineMemoryBufferOptions', + :'ObservabilityPipelineMemoryBufferSizeOptions' + ] + end + # Builds the object + # @param data [Mixed] Data to be matched against the list of oneOf items + # @return [Object] Returns the model or the data itself + def build(data) + # Go through the list of oneOf items and attempt to identify the appropriate one. + # Note: + # - We do not attempt to check whether exactly one item matches. + # - No advanced validation of types in some cases (e.g. "x: { type: string }" will happily match { x: 123 }) + # due to the way the deserialization is made in the base_object template (it just casts without verifying). + # - TODO: scalar values are de facto behaving as if they were nullable. + # - TODO: logging when debugging is set. + openapi_one_of.each do |klass| + begin + next if klass == :AnyType # "nullable: true" + typed_data = find_and_cast_into_type(klass, data) + next if typed_data.respond_to?(:_unparsed) && typed_data._unparsed + return typed_data if typed_data + rescue # rescue all errors so we keep iterating even if the current item lookup raises + end + end + + if openapi_one_of.include?(:AnyType) + data + else + self._unparsed = true + DatadogAPIClient::UnparsedObject.new(data) + end + end + end + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_disk_type.rb b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_disk_type.rb new file mode 100644 index 00000000000..efe88cd7ce7 --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_disk_type.rb @@ -0,0 +1,26 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The type of the buffer that will be configured, a disk buffer. + class ObservabilityPipelineBufferOptionsDiskType + include BaseEnumModel + + DISK = "disk".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_memory_type.rb b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_memory_type.rb new file mode 100644 index 00000000000..e11826e973f --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_memory_type.rb @@ -0,0 +1,26 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # The type of the buffer that will be configured, a memory buffer. + class ObservabilityPipelineBufferOptionsMemoryType + include BaseEnumModel + + MEMORY = "memory".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_when_full.rb b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_when_full.rb new file mode 100644 index 00000000000..38d6af94c8b --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_buffer_options_when_full.rb @@ -0,0 +1,27 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Behavior when the buffer is full (block and stop accepting new events, or drop new events) + class ObservabilityPipelineBufferOptionsWhenFull + include BaseEnumModel + + BLOCK = "block".freeze + DROP_NEWEST = "drop_newest".freeze + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_crowd_strike_next_gen_siem_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_crowd_strike_next_gen_siem_destination.rb index 3a24137f6c7..04bba5d3a09 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_crowd_strike_next_gen_siem_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_crowd_strike_next_gen_siem_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineCrowdStrikeNextGenSiemDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Compression configuration for log events. attr_accessor :compression @@ -47,6 +50,7 @@ class ObservabilityPipelineCrowdStrikeNextGenSiemDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'compression' => :'compression', :'encoding' => :'encoding', :'id' => :'id', @@ -60,6 +64,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'compression' => :'ObservabilityPipelineCrowdStrikeNextGenSiemDestinationCompression', :'encoding' => :'ObservabilityPipelineCrowdStrikeNextGenSiemDestinationEncoding', :'id' => :'String', @@ -87,6 +92,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'compression') self.compression = attributes[:'compression'] end @@ -191,6 +200,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && compression == o.compression && encoding == o.encoding && id == o.id && @@ -204,7 +214,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [compression, encoding, id, inputs, tls, type, additional_properties].hash + [buffer, compression, encoding, id, inputs, tls, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_datadog_logs_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_datadog_logs_destination.rb index 090ec2243bf..0a9cd1e9d70 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_datadog_logs_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_datadog_logs_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineDatadogLogsDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The unique identifier for this component. attr_reader :id @@ -41,6 +44,7 @@ class ObservabilityPipelineDatadogLogsDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'routes' => :'routes', @@ -52,6 +56,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'routes' => :'Array', @@ -77,6 +82,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -175,6 +184,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && id == o.id && inputs == o.inputs && routes == o.routes && @@ -186,7 +196,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [id, inputs, routes, type, additional_properties].hash + [buffer, id, inputs, routes, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_disk_buffer_options.rb b/lib/datadog_api_client/v2/models/observability_pipeline_disk_buffer_options.rb new file mode 100644 index 00000000000..44be529f2c8 --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_disk_buffer_options.rb @@ -0,0 +1,125 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Options for configuring a disk buffer. + class ObservabilityPipelineDiskBufferOptions + include BaseGenericModel + + # Maximum size of the disk buffer. + attr_accessor :max_size + + # The type of the buffer that will be configured, a disk buffer. + attr_accessor :type + + # Behavior when the buffer is full (block and stop accepting new events, or drop new events) + attr_accessor :when_full + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'max_size' => :'max_size', + :'type' => :'type', + :'when_full' => :'when_full' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'max_size' => :'Integer', + :'type' => :'ObservabilityPipelineBufferOptionsDiskType', + :'when_full' => :'ObservabilityPipelineBufferOptionsWhenFull' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ObservabilityPipelineDiskBufferOptions` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'max_size') + self.max_size = attributes[:'max_size'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + + if attributes.key?(:'when_full') + self.when_full = attributes[:'when_full'] + end + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + max_size == o.max_size && + type == o.type && + when_full == o.when_full && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [max_size, type, when_full, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_elasticsearch_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_elasticsearch_destination.rb index d3e3475ce72..c60d54c5623 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_elasticsearch_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_elasticsearch_destination.rb @@ -26,6 +26,9 @@ class ObservabilityPipelineElasticsearchDestination # The Elasticsearch API version to use. Set to `auto` to auto-detect. attr_accessor :api_version + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The index to write logs to in Elasticsearch. attr_accessor :bulk_index @@ -48,6 +51,7 @@ class ObservabilityPipelineElasticsearchDestination def self.attribute_map { :'api_version' => :'api_version', + :'buffer' => :'buffer', :'bulk_index' => :'bulk_index', :'data_stream' => :'data_stream', :'id' => :'id', @@ -61,6 +65,7 @@ def self.attribute_map def self.openapi_types { :'api_version' => :'ObservabilityPipelineElasticsearchDestinationApiVersion', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'bulk_index' => :'String', :'data_stream' => :'ObservabilityPipelineElasticsearchDestinationDataStream', :'id' => :'String', @@ -91,6 +96,10 @@ def initialize(attributes = {}) self.api_version = attributes[:'api_version'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'bulk_index') self.bulk_index = attributes[:'bulk_index'] end @@ -181,6 +190,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && api_version == o.api_version && + buffer == o.buffer && bulk_index == o.bulk_index && data_stream == o.data_stream && id == o.id && @@ -193,7 +203,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [api_version, bulk_index, data_stream, id, inputs, type, additional_properties].hash + [api_version, buffer, bulk_index, data_stream, id, inputs, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_google_chronicle_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_google_chronicle_destination.rb index 93eed57d636..6535b32ee31 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_google_chronicle_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_google_chronicle_destination.rb @@ -26,6 +26,9 @@ class ObservabilityPipelineGoogleChronicleDestination # GCP credentials used to authenticate with Google Cloud Storage. attr_accessor :auth + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The Google Chronicle customer ID. attr_reader :customer_id @@ -51,6 +54,7 @@ class ObservabilityPipelineGoogleChronicleDestination def self.attribute_map { :'auth' => :'auth', + :'buffer' => :'buffer', :'customer_id' => :'customer_id', :'encoding' => :'encoding', :'id' => :'id', @@ -65,6 +69,7 @@ def self.attribute_map def self.openapi_types { :'auth' => :'ObservabilityPipelineGcpAuth', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'customer_id' => :'String', :'encoding' => :'ObservabilityPipelineGoogleChronicleDestinationEncoding', :'id' => :'String', @@ -96,6 +101,10 @@ def initialize(attributes = {}) self.auth = attributes[:'auth'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'customer_id') self.customer_id = attributes[:'customer_id'] end @@ -201,6 +210,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && auth == o.auth && + buffer == o.buffer && customer_id == o.customer_id && encoding == o.encoding && id == o.id && @@ -214,7 +224,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auth, customer_id, encoding, id, inputs, log_type, type, additional_properties].hash + [auth, buffer, customer_id, encoding, id, inputs, log_type, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_google_cloud_storage_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_google_cloud_storage_destination.rb index e1572e3804a..9379bc1ecb3 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_google_cloud_storage_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_google_cloud_storage_destination.rb @@ -33,6 +33,9 @@ class ObservabilityPipelineGoogleCloudStorageDestination # Name of the GCS bucket. attr_reader :bucket + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Unique identifier for the destination component. attr_reader :id @@ -60,6 +63,7 @@ def self.attribute_map :'acl' => :'acl', :'auth' => :'auth', :'bucket' => :'bucket', + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'key_prefix' => :'key_prefix', @@ -76,6 +80,7 @@ def self.openapi_types :'acl' => :'ObservabilityPipelineGoogleCloudStorageDestinationAcl', :'auth' => :'ObservabilityPipelineGcpAuth', :'bucket' => :'String', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'key_prefix' => :'String', @@ -115,6 +120,10 @@ def initialize(attributes = {}) self.bucket = attributes[:'bucket'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -235,6 +244,7 @@ def ==(o) acl == o.acl && auth == o.auth && bucket == o.bucket && + buffer == o.buffer && id == o.id && inputs == o.inputs && key_prefix == o.key_prefix && @@ -248,7 +258,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [acl, auth, bucket, id, inputs, key_prefix, metadata, storage_class, type, additional_properties].hash + [acl, auth, bucket, buffer, id, inputs, key_prefix, metadata, storage_class, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_google_pub_sub_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_google_pub_sub_destination.rb index f85845c5aea..329b0c19b4b 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_google_pub_sub_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_google_pub_sub_destination.rb @@ -26,6 +26,9 @@ class ObservabilityPipelineGooglePubSubDestination # GCP credentials used to authenticate with Google Cloud Storage. attr_accessor :auth + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Encoding format for log events. attr_reader :encoding @@ -54,6 +57,7 @@ class ObservabilityPipelineGooglePubSubDestination def self.attribute_map { :'auth' => :'auth', + :'buffer' => :'buffer', :'encoding' => :'encoding', :'id' => :'id', :'inputs' => :'inputs', @@ -69,6 +73,7 @@ def self.attribute_map def self.openapi_types { :'auth' => :'ObservabilityPipelineGcpAuth', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'encoding' => :'ObservabilityPipelineGooglePubSubDestinationEncoding', :'id' => :'String', :'inputs' => :'Array', @@ -101,6 +106,10 @@ def initialize(attributes = {}) self.auth = attributes[:'auth'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'encoding') self.encoding = attributes[:'encoding'] end @@ -232,6 +241,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && auth == o.auth && + buffer == o.buffer && encoding == o.encoding && id == o.id && inputs == o.inputs && @@ -246,7 +256,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auth, encoding, id, inputs, project, tls, topic, type, additional_properties].hash + [auth, buffer, encoding, id, inputs, project, tls, topic, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_options.rb b/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_options.rb new file mode 100644 index 00000000000..eb67ff1e90d --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_options.rb @@ -0,0 +1,115 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Options for configuring a memory buffer by byte size. + class ObservabilityPipelineMemoryBufferOptions + include BaseGenericModel + + # Maximum size of the memory buffer. + attr_accessor :max_size + + # The type of the buffer that will be configured, a memory buffer. + attr_accessor :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'max_size' => :'max_size', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'max_size' => :'Integer', + :'type' => :'ObservabilityPipelineBufferOptionsMemoryType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ObservabilityPipelineMemoryBufferOptions` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'max_size') + self.max_size = attributes[:'max_size'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + max_size == o.max_size && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [max_size, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_size_options.rb b/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_size_options.rb new file mode 100644 index 00000000000..04f5e0b68aa --- /dev/null +++ b/lib/datadog_api_client/v2/models/observability_pipeline_memory_buffer_size_options.rb @@ -0,0 +1,115 @@ +=begin +#Datadog API V2 Collection + +#Collection of all Datadog Public endpoints. + +The version of the OpenAPI document: 1.0 +Contact: support@datadoghq.com +Generated by: https://github.com/DataDog/datadog-api-client-ruby/tree/master/.generator + + Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. + This product includes software developed at Datadog (https://www.datadoghq.com/). + Copyright 2020-Present Datadog, Inc. + +=end + +require 'date' +require 'time' + +module DatadogAPIClient::V2 + # Options for configuring a memory buffer by queue length. + class ObservabilityPipelineMemoryBufferSizeOptions + include BaseGenericModel + + # Maximum events for the memory buffer. + attr_accessor :max_events + + # The type of the buffer that will be configured, a memory buffer. + attr_accessor :type + + attr_accessor :additional_properties + + # Attribute mapping from ruby-style variable name to JSON key. + # @!visibility private + def self.attribute_map + { + :'max_events' => :'max_events', + :'type' => :'type' + } + end + + # Attribute type mapping. + # @!visibility private + def self.openapi_types + { + :'max_events' => :'Integer', + :'type' => :'ObservabilityPipelineBufferOptionsMemoryType' + } + end + + # Initializes the object + # @param attributes [Hash] Model attributes in the form of hash + # @!visibility private + def initialize(attributes = {}) + if (!attributes.is_a?(Hash)) + fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V2::ObservabilityPipelineMemoryBufferSizeOptions` initialize method" + end + + self.additional_properties = {} + # check to see if the attribute exists and convert string to symbol for hash key + attributes = attributes.each_with_object({}) { |(k, v), h| + if (!self.class.attribute_map.key?(k.to_sym)) + self.additional_properties[k.to_sym] = v + else + h[k.to_sym] = v + end + } + + if attributes.key?(:'max_events') + self.max_events = attributes[:'max_events'] + end + + if attributes.key?(:'type') + self.type = attributes[:'type'] + end + end + + # Returns the object in the form of hash, with additionalProperties support. + # @return [Hash] Returns the object in the form of hash + # @!visibility private + def to_hash + hash = {} + self.class.attribute_map.each_pair do |attr, param| + value = self.send(attr) + if value.nil? + is_nullable = self.class.openapi_nullable.include?(attr) + next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) + end + + hash[param] = _to_hash(value) + end + self.additional_properties.each_pair do |attr, value| + hash[attr] = value + end + hash + end + + # Checks equality by comparing each attribute. + # @param o [Object] Object to be compared + # @!visibility private + def ==(o) + return true if self.equal?(o) + self.class == o.class && + max_events == o.max_events && + type == o.type && + additional_properties == o.additional_properties + end + + # Calculates hash code according to all attributes. + # @return [Integer] Hash code + # @!visibility private + def hash + [max_events, type, additional_properties].hash + end + end +end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_new_relic_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_new_relic_destination.rb index 79118217199..3bbcfb490b4 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_new_relic_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_new_relic_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineNewRelicDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The unique identifier for this component. attr_reader :id @@ -41,6 +44,7 @@ class ObservabilityPipelineNewRelicDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'region' => :'region', @@ -52,6 +56,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'region' => :'ObservabilityPipelineNewRelicDestinationRegion', @@ -77,6 +82,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -173,6 +182,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && id == o.id && inputs == o.inputs && region == o.region && @@ -184,7 +194,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [id, inputs, region, type, additional_properties].hash + [buffer, id, inputs, region, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_open_search_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_open_search_destination.rb index 54b256eb85f..72e2798c1cb 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_open_search_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_open_search_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineOpenSearchDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The index to write logs to. attr_accessor :bulk_index @@ -44,6 +47,7 @@ class ObservabilityPipelineOpenSearchDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'bulk_index' => :'bulk_index', :'data_stream' => :'data_stream', :'id' => :'id', @@ -56,6 +60,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'bulk_index' => :'String', :'data_stream' => :'ObservabilityPipelineOpenSearchDestinationDataStream', :'id' => :'String', @@ -82,6 +87,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'bulk_index') self.bulk_index = attributes[:'bulk_index'] end @@ -171,6 +180,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && bulk_index == o.bulk_index && data_stream == o.data_stream && id == o.id && @@ -183,7 +193,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [bulk_index, data_stream, id, inputs, type, additional_properties].hash + [buffer, bulk_index, data_stream, id, inputs, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_rsyslog_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_rsyslog_destination.rb index c3151af7153..5a1c16dc797 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_rsyslog_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_rsyslog_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineRsyslogDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The unique identifier for this component. attr_reader :id @@ -44,6 +47,7 @@ class ObservabilityPipelineRsyslogDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'keepalive' => :'keepalive', @@ -56,6 +60,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'keepalive' => :'Integer', @@ -82,6 +87,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -182,6 +191,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && id == o.id && inputs == o.inputs && keepalive == o.keepalive && @@ -194,7 +204,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [id, inputs, keepalive, tls, type, additional_properties].hash + [buffer, id, inputs, keepalive, tls, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_sentinel_one_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_sentinel_one_destination.rb index 4b3548624a7..afd36fa79c2 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_sentinel_one_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_sentinel_one_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineSentinelOneDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The unique identifier for this component. attr_reader :id @@ -41,6 +44,7 @@ class ObservabilityPipelineSentinelOneDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'region' => :'region', @@ -52,6 +56,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'region' => :'ObservabilityPipelineSentinelOneDestinationRegion', @@ -77,6 +82,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -173,6 +182,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && id == o.id && inputs == o.inputs && region == o.region && @@ -184,7 +194,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [id, inputs, region, type, additional_properties].hash + [buffer, id, inputs, region, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_socket_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_socket_destination.rb index 5a8c561616c..44861a7907a 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_socket_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_socket_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineSocketDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Encoding format for log events. attr_reader :encoding @@ -50,6 +53,7 @@ class ObservabilityPipelineSocketDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'encoding' => :'encoding', :'framing' => :'framing', :'id' => :'id', @@ -64,6 +68,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'encoding' => :'ObservabilityPipelineSocketDestinationEncoding', :'framing' => :'ObservabilityPipelineSocketDestinationFraming', :'id' => :'String', @@ -92,6 +97,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'encoding') self.encoding = attributes[:'encoding'] end @@ -222,6 +231,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && encoding == o.encoding && framing == o.framing && id == o.id && @@ -236,7 +246,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [encoding, framing, id, inputs, mode, tls, type, additional_properties].hash + [buffer, encoding, framing, id, inputs, mode, tls, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_splunk_hec_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_splunk_hec_destination.rb index 707c0ff5e12..7c504d81e51 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_splunk_hec_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_splunk_hec_destination.rb @@ -27,6 +27,9 @@ class ObservabilityPipelineSplunkHecDestination # If `false`, Splunk assigns the time the event was received. attr_accessor :auto_extract_timestamp + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # Encoding format for log events. attr_accessor :encoding @@ -52,6 +55,7 @@ class ObservabilityPipelineSplunkHecDestination def self.attribute_map { :'auto_extract_timestamp' => :'auto_extract_timestamp', + :'buffer' => :'buffer', :'encoding' => :'encoding', :'id' => :'id', :'index' => :'index', @@ -66,6 +70,7 @@ def self.attribute_map def self.openapi_types { :'auto_extract_timestamp' => :'Boolean', + :'buffer' => :'ObservabilityPipelineBufferOptions', :'encoding' => :'ObservabilityPipelineSplunkHecDestinationEncoding', :'id' => :'String', :'index' => :'String', @@ -97,6 +102,10 @@ def initialize(attributes = {}) self.auto_extract_timestamp = attributes[:'auto_extract_timestamp'] end + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'encoding') self.encoding = attributes[:'encoding'] end @@ -191,6 +200,7 @@ def ==(o) return true if self.equal?(o) self.class == o.class && auto_extract_timestamp == o.auto_extract_timestamp && + buffer == o.buffer && encoding == o.encoding && id == o.id && index == o.index && @@ -204,7 +214,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [auto_extract_timestamp, encoding, id, index, inputs, sourcetype, type, additional_properties].hash + [auto_extract_timestamp, buffer, encoding, id, index, inputs, sourcetype, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_sumo_logic_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_sumo_logic_destination.rb index 7a3c31742c5..f6346f09295 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_sumo_logic_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_sumo_logic_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineSumoLogicDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The output encoding format. attr_accessor :encoding @@ -53,6 +56,7 @@ class ObservabilityPipelineSumoLogicDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'encoding' => :'encoding', :'header_custom_fields' => :'header_custom_fields', :'header_host_name' => :'header_host_name', @@ -68,6 +72,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'encoding' => :'ObservabilityPipelineSumoLogicDestinationEncoding', :'header_custom_fields' => :'Array', :'header_host_name' => :'String', @@ -97,6 +102,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'encoding') self.encoding = attributes[:'encoding'] end @@ -200,6 +209,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && encoding == o.encoding && header_custom_fields == o.header_custom_fields && header_host_name == o.header_host_name && @@ -215,7 +225,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [encoding, header_custom_fields, header_host_name, header_source_category, header_source_name, id, inputs, type, additional_properties].hash + [buffer, encoding, header_custom_fields, header_host_name, header_source_category, header_source_name, id, inputs, type, additional_properties].hash end end end diff --git a/lib/datadog_api_client/v2/models/observability_pipeline_syslog_ng_destination.rb b/lib/datadog_api_client/v2/models/observability_pipeline_syslog_ng_destination.rb index 132ffd70a89..a816fbcbca7 100644 --- a/lib/datadog_api_client/v2/models/observability_pipeline_syslog_ng_destination.rb +++ b/lib/datadog_api_client/v2/models/observability_pipeline_syslog_ng_destination.rb @@ -23,6 +23,9 @@ module DatadogAPIClient::V2 class ObservabilityPipelineSyslogNgDestination include BaseGenericModel + # Configuration for buffer settings on destination components. + attr_accessor :buffer + # The unique identifier for this component. attr_reader :id @@ -44,6 +47,7 @@ class ObservabilityPipelineSyslogNgDestination # @!visibility private def self.attribute_map { + :'buffer' => :'buffer', :'id' => :'id', :'inputs' => :'inputs', :'keepalive' => :'keepalive', @@ -56,6 +60,7 @@ def self.attribute_map # @!visibility private def self.openapi_types { + :'buffer' => :'ObservabilityPipelineBufferOptions', :'id' => :'String', :'inputs' => :'Array', :'keepalive' => :'Integer', @@ -82,6 +87,10 @@ def initialize(attributes = {}) end } + if attributes.key?(:'buffer') + self.buffer = attributes[:'buffer'] + end + if attributes.key?(:'id') self.id = attributes[:'id'] end @@ -182,6 +191,7 @@ def to_hash def ==(o) return true if self.equal?(o) self.class == o.class && + buffer == o.buffer && id == o.id && inputs == o.inputs && keepalive == o.keepalive && @@ -194,7 +204,7 @@ def ==(o) # @return [Integer] Hash code # @!visibility private def hash - [id, inputs, keepalive, tls, type, additional_properties].hash + [buffer, id, inputs, keepalive, tls, type, additional_properties].hash end end end