Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83530,6 +83530,12 @@ components:
description: The index to write logs to.
example: logs-index
type: string
data_stream:
$ref: "#/components/schemas/ObservabilityPipelineOpenSearchDestinationDataStream"
endpoint_url_key:
description: Name of the environment variable or secret that holds the Amazon OpenSearch endpoint URL.
example: AMAZON_OPENSEARCH_ENDPOINT_URL
type: string
id:
description: The unique identifier for this component.
example: elasticsearch-destination
Expand All @@ -83547,13 +83553,13 @@ components:
- id
- type
- inputs
- auth
type: object
x-pipeline-types: [logs]
ObservabilityPipelineAmazonOpenSearchDestinationAuth:
description: |-
Authentication settings for the Amazon OpenSearch destination.
The `strategy` field determines whether basic or AWS-based authentication is used.
When `strategy` is `basic`, use `username_key` and `password_key` to reference credentials stored in environment variables or secrets.
properties:
assume_role:
description: The ARN of the role to assume (used with `aws` strategy).
Expand All @@ -83564,11 +83570,19 @@ components:
external_id:
description: External ID for the assumed role (used with `aws` strategy).
type: string
password_key:
description: Name of the environment variable or secret that holds the Amazon OpenSearch password (used when `strategy` is `basic`).
example: AMAZON_OPENSEARCH_PASSWORD
type: string
session_name:
description: Session name for the assumed role (used with `aws` strategy).
type: string
strategy:
$ref: "#/components/schemas/ObservabilityPipelineAmazonOpenSearchDestinationAuthStrategy"
username_key:
description: Name of the environment variable or secret that holds the Amazon OpenSearch username (used when `strategy` is `basic`).
example: AMAZON_OPENSEARCH_USERNAME
type: string
required:
- strategy
type: object
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_AUTH,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_BUFFER,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_BULK_INDEX,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_DATA_STREAM,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_ENDPOINT_URL_KEY,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_ID,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_INPUTS,
ObservabilityPipelineAmazonOpenSearchDestination.JSON_PROPERTY_TYPE
Expand All @@ -45,6 +47,12 @@ public class ObservabilityPipelineAmazonOpenSearchDestination {
public static final String JSON_PROPERTY_BULK_INDEX = "bulk_index";
private String bulkIndex;

public static final String JSON_PROPERTY_DATA_STREAM = "data_stream";
private ObservabilityPipelineOpenSearchDestinationDataStream dataStream;

public static final String JSON_PROPERTY_ENDPOINT_URL_KEY = "endpoint_url_key";
private String endpointUrlKey;

public static final String JSON_PROPERTY_ID = "id";
private String id;

Expand All @@ -59,14 +67,10 @@ public ObservabilityPipelineAmazonOpenSearchDestination() {}

@JsonCreator
public ObservabilityPipelineAmazonOpenSearchDestination(
@JsonProperty(required = true, value = JSON_PROPERTY_AUTH)
ObservabilityPipelineAmazonOpenSearchDestinationAuth auth,
@JsonProperty(required = true, value = JSON_PROPERTY_ID) String id,
@JsonProperty(required = true, value = JSON_PROPERTY_INPUTS) List<String> inputs,
@JsonProperty(required = true, value = JSON_PROPERTY_TYPE)
ObservabilityPipelineAmazonOpenSearchDestinationType type) {
this.auth = auth;
this.unparsed |= auth.unparsed;
this.id = id;
this.inputs = inputs;
this.type = type;
Expand All @@ -82,12 +86,15 @@ public ObservabilityPipelineAmazonOpenSearchDestination auth(

/**
* Authentication settings for the Amazon OpenSearch destination. The <code>strategy</code> field
* determines whether basic or AWS-based authentication is used.
* determines whether basic or AWS-based authentication is used. When <code>strategy</code> is
* <code>basic</code>, use <code>username_key</code> and <code>password_key</code> to reference
* credentials stored in environment variables or secrets.
*
* @return auth
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_AUTH)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ObservabilityPipelineAmazonOpenSearchDestinationAuth getAuth() {
return auth;
}
Expand Down Expand Up @@ -146,6 +153,53 @@ public void setBulkIndex(String bulkIndex) {
this.bulkIndex = bulkIndex;
}

public ObservabilityPipelineAmazonOpenSearchDestination dataStream(
ObservabilityPipelineOpenSearchDestinationDataStream dataStream) {
this.dataStream = dataStream;
this.unparsed |= dataStream.unparsed;
return this;
}

/**
* Configuration options for writing to OpenSearch Data Streams instead of a fixed index.
*
* @return dataStream
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_DATA_STREAM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ObservabilityPipelineOpenSearchDestinationDataStream getDataStream() {
return dataStream;
}

public void setDataStream(ObservabilityPipelineOpenSearchDestinationDataStream dataStream) {
this.dataStream = dataStream;
if (dataStream != null) {
this.unparsed |= dataStream.unparsed;
}
}

public ObservabilityPipelineAmazonOpenSearchDestination endpointUrlKey(String endpointUrlKey) {
this.endpointUrlKey = endpointUrlKey;
return this;
}

/**
* Name of the environment variable or secret that holds the Amazon OpenSearch endpoint URL.
*
* @return endpointUrlKey
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_ENDPOINT_URL_KEY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getEndpointUrlKey() {
return endpointUrlKey;
}

public void setEndpointUrlKey(String endpointUrlKey) {
this.endpointUrlKey = endpointUrlKey;
}

public ObservabilityPipelineAmazonOpenSearchDestination id(String id) {
this.id = id;
return this;
Expand Down Expand Up @@ -279,6 +333,10 @@ public boolean equals(Object o) {
&& Objects.equals(this.buffer, observabilityPipelineAmazonOpenSearchDestination.buffer)
&& Objects.equals(
this.bulkIndex, observabilityPipelineAmazonOpenSearchDestination.bulkIndex)
&& Objects.equals(
this.dataStream, observabilityPipelineAmazonOpenSearchDestination.dataStream)
&& Objects.equals(
this.endpointUrlKey, observabilityPipelineAmazonOpenSearchDestination.endpointUrlKey)
&& Objects.equals(this.id, observabilityPipelineAmazonOpenSearchDestination.id)
&& Objects.equals(this.inputs, observabilityPipelineAmazonOpenSearchDestination.inputs)
&& Objects.equals(this.type, observabilityPipelineAmazonOpenSearchDestination.type)
Expand All @@ -289,7 +347,16 @@ public boolean equals(Object o) {

@Override
public int hashCode() {
return Objects.hash(auth, buffer, bulkIndex, id, inputs, type, additionalProperties);
return Objects.hash(
auth,
buffer,
bulkIndex,
dataStream,
endpointUrlKey,
id,
inputs,
type,
additionalProperties);
}

@Override
Expand All @@ -299,6 +366,8 @@ public String toString() {
sb.append(" auth: ").append(toIndentedString(auth)).append("\n");
sb.append(" buffer: ").append(toIndentedString(buffer)).append("\n");
sb.append(" bulkIndex: ").append(toIndentedString(bulkIndex)).append("\n");
sb.append(" dataStream: ").append(toIndentedString(dataStream)).append("\n");
sb.append(" endpointUrlKey: ").append(toIndentedString(endpointUrlKey)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" inputs: ").append(toIndentedString(inputs)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,18 @@

/**
* Authentication settings for the Amazon OpenSearch destination. The <code>strategy</code> field
* determines whether basic or AWS-based authentication is used.
* determines whether basic or AWS-based authentication is used. When <code>strategy</code> is
* <code>basic</code>, use <code>username_key</code> and <code>password_key</code> to reference
* credentials stored in environment variables or secrets.
*/
@JsonPropertyOrder({
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_ASSUME_ROLE,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_AWS_REGION,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_EXTERNAL_ID,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_PASSWORD_KEY,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_SESSION_NAME,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_STRATEGY
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_STRATEGY,
ObservabilityPipelineAmazonOpenSearchDestinationAuth.JSON_PROPERTY_USERNAME_KEY
})
@jakarta.annotation.Generated(
value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator")
Expand All @@ -41,12 +45,18 @@ public class ObservabilityPipelineAmazonOpenSearchDestinationAuth {
public static final String JSON_PROPERTY_EXTERNAL_ID = "external_id";
private String externalId;

public static final String JSON_PROPERTY_PASSWORD_KEY = "password_key";
private String passwordKey;

public static final String JSON_PROPERTY_SESSION_NAME = "session_name";
private String sessionName;

public static final String JSON_PROPERTY_STRATEGY = "strategy";
private ObservabilityPipelineAmazonOpenSearchDestinationAuthStrategy strategy;

public static final String JSON_PROPERTY_USERNAME_KEY = "username_key";
private String usernameKey;

public ObservabilityPipelineAmazonOpenSearchDestinationAuth() {}

@JsonCreator
Expand Down Expand Up @@ -120,6 +130,28 @@ public void setExternalId(String externalId) {
this.externalId = externalId;
}

public ObservabilityPipelineAmazonOpenSearchDestinationAuth passwordKey(String passwordKey) {
this.passwordKey = passwordKey;
return this;
}

/**
* Name of the environment variable or secret that holds the Amazon OpenSearch password (used when
* <code>strategy</code> is <code>basic</code>).
*
* @return passwordKey
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_PASSWORD_KEY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getPasswordKey() {
return passwordKey;
}

public void setPasswordKey(String passwordKey) {
this.passwordKey = passwordKey;
}

public ObservabilityPipelineAmazonOpenSearchDestinationAuth sessionName(String sessionName) {
this.sessionName = sessionName;
return this;
Expand Down Expand Up @@ -166,6 +198,28 @@ public void setStrategy(ObservabilityPipelineAmazonOpenSearchDestinationAuthStra
this.strategy = strategy;
}

public ObservabilityPipelineAmazonOpenSearchDestinationAuth usernameKey(String usernameKey) {
this.usernameKey = usernameKey;
return this;
}

/**
* Name of the environment variable or secret that holds the Amazon OpenSearch username (used when
* <code>strategy</code> is <code>basic</code>).
*
* @return usernameKey
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_USERNAME_KEY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getUsernameKey() {
return usernameKey;
}

public void setUsernameKey(String usernameKey) {
this.usernameKey = usernameKey;
}

/**
* A container for additional, undeclared properties. This is a holder for any undeclared
* properties as specified with the 'additionalProperties' keyword in the OAS document.
Expand Down Expand Up @@ -233,10 +287,14 @@ public boolean equals(Object o) {
this.awsRegion, observabilityPipelineAmazonOpenSearchDestinationAuth.awsRegion)
&& Objects.equals(
this.externalId, observabilityPipelineAmazonOpenSearchDestinationAuth.externalId)
&& Objects.equals(
this.passwordKey, observabilityPipelineAmazonOpenSearchDestinationAuth.passwordKey)
&& Objects.equals(
this.sessionName, observabilityPipelineAmazonOpenSearchDestinationAuth.sessionName)
&& Objects.equals(
this.strategy, observabilityPipelineAmazonOpenSearchDestinationAuth.strategy)
&& Objects.equals(
this.usernameKey, observabilityPipelineAmazonOpenSearchDestinationAuth.usernameKey)
&& Objects.equals(
this.additionalProperties,
observabilityPipelineAmazonOpenSearchDestinationAuth.additionalProperties);
Expand All @@ -245,7 +303,14 @@ public boolean equals(Object o) {
@Override
public int hashCode() {
return Objects.hash(
assumeRole, awsRegion, externalId, sessionName, strategy, additionalProperties);
assumeRole,
awsRegion,
externalId,
passwordKey,
sessionName,
strategy,
usernameKey,
additionalProperties);
}

@Override
Expand All @@ -255,8 +320,10 @@ public String toString() {
sb.append(" assumeRole: ").append(toIndentedString(assumeRole)).append("\n");
sb.append(" awsRegion: ").append(toIndentedString(awsRegion)).append("\n");
sb.append(" externalId: ").append(toIndentedString(externalId)).append("\n");
sb.append(" passwordKey: ").append(toIndentedString(passwordKey)).append("\n");
sb.append(" sessionName: ").append(toIndentedString(sessionName)).append("\n");
sb.append(" strategy: ").append(toIndentedString(strategy)).append("\n");
sb.append(" usernameKey: ").append(toIndentedString(usernameKey)).append("\n");
sb.append(" additionalProperties: ")
.append(toIndentedString(additionalProperties))
.append("\n");
Expand Down
Loading