Skip to content

Commit b2b18dc

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Make datadog agent source address configurable in Observability Pipelines (#3625)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent c9b24cb commit b2b18dc

File tree

2 files changed

+35
-2
lines changed

2 files changed

+35
-2
lines changed

.generator/schemas/v2/openapi.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42913,6 +42913,11 @@ components:
4291342913

4291442914
**Supported pipeline types:** logs, metrics'
4291542915
properties:
42916+
address_key:
42917+
description: Name of the environment variable or secret that holds the listen
42918+
address for the Datadog Agent source.
42919+
example: DATADOG_AGENT_ADDRESS
42920+
type: string
4291642921
id:
4291742922
description: The unique identifier for this component. Used in other parts
4291842923
of the pipeline to reference this component (for example, as the `input`

src/main/java/com/datadog/api/client/v2/model/ObservabilityPipelineDatadogAgentSource.java

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
* <p><strong>Supported pipeline types:</strong> logs, metrics
2424
*/
2525
@JsonPropertyOrder({
26+
ObservabilityPipelineDatadogAgentSource.JSON_PROPERTY_ADDRESS_KEY,
2627
ObservabilityPipelineDatadogAgentSource.JSON_PROPERTY_ID,
2728
ObservabilityPipelineDatadogAgentSource.JSON_PROPERTY_TLS,
2829
ObservabilityPipelineDatadogAgentSource.JSON_PROPERTY_TYPE
@@ -31,6 +32,9 @@
3132
value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator")
3233
public class ObservabilityPipelineDatadogAgentSource {
3334
@JsonIgnore public boolean unparsed = false;
35+
public static final String JSON_PROPERTY_ADDRESS_KEY = "address_key";
36+
private String addressKey;
37+
3438
public static final String JSON_PROPERTY_ID = "id";
3539
private String id;
3640

@@ -53,6 +57,28 @@ public ObservabilityPipelineDatadogAgentSource(
5357
this.unparsed |= !type.isValid();
5458
}
5559

60+
public ObservabilityPipelineDatadogAgentSource addressKey(String addressKey) {
61+
this.addressKey = addressKey;
62+
return this;
63+
}
64+
65+
/**
66+
* Name of the environment variable or secret that holds the listen address for the Datadog Agent
67+
* source.
68+
*
69+
* @return addressKey
70+
*/
71+
@jakarta.annotation.Nullable
72+
@JsonProperty(JSON_PROPERTY_ADDRESS_KEY)
73+
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
74+
public String getAddressKey() {
75+
return addressKey;
76+
}
77+
78+
public void setAddressKey(String addressKey) {
79+
this.addressKey = addressKey;
80+
}
81+
5682
public ObservabilityPipelineDatadogAgentSource id(String id) {
5783
this.id = id;
5884
return this;
@@ -178,7 +204,8 @@ public boolean equals(Object o) {
178204
}
179205
ObservabilityPipelineDatadogAgentSource observabilityPipelineDatadogAgentSource =
180206
(ObservabilityPipelineDatadogAgentSource) o;
181-
return Objects.equals(this.id, observabilityPipelineDatadogAgentSource.id)
207+
return Objects.equals(this.addressKey, observabilityPipelineDatadogAgentSource.addressKey)
208+
&& Objects.equals(this.id, observabilityPipelineDatadogAgentSource.id)
182209
&& Objects.equals(this.tls, observabilityPipelineDatadogAgentSource.tls)
183210
&& Objects.equals(this.type, observabilityPipelineDatadogAgentSource.type)
184211
&& Objects.equals(
@@ -188,13 +215,14 @@ public boolean equals(Object o) {
188215

189216
@Override
190217
public int hashCode() {
191-
return Objects.hash(id, tls, type, additionalProperties);
218+
return Objects.hash(addressKey, id, tls, type, additionalProperties);
192219
}
193220

194221
@Override
195222
public String toString() {
196223
StringBuilder sb = new StringBuilder();
197224
sb.append("class ObservabilityPipelineDatadogAgentSource {\n");
225+
sb.append(" addressKey: ").append(toIndentedString(addressKey)).append("\n");
198226
sb.append(" id: ").append(toIndentedString(id)).append("\n");
199227
sb.append(" tls: ").append(toIndentedString(tls)).append("\n");
200228
sb.append(" type: ").append(toIndentedString(type)).append("\n");

0 commit comments

Comments
 (0)