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
720 changes: 567 additions & 153 deletions .generator/schemas/v2/openapi.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion examples/v2/observability-pipelines/CreatePipeline.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public static void main(String[] args) {
.type(
ObservabilityPipelineDatadogLogsDestinationType
.DATADOG_LOGS))))
.processors(
.processorGroups(
Collections.singletonList(
new ObservabilityPipelineConfigProcessorGroup()
.enabled(true)
Expand Down
2 changes: 1 addition & 1 deletion examples/v2/observability-pipelines/UpdatePipeline.java
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public static void main(String[] args) {
.type(
ObservabilityPipelineDatadogLogsDestinationType
.DATADOG_LOGS))))
.processors(
.processorGroups(
Collections.singletonList(
new ObservabilityPipelineConfigProcessorGroup()
.enabled(true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public static void main(String[] args) {
.type(
ObservabilityPipelineDatadogLogsDestinationType
.DATADOG_LOGS))))
.processors(
.processorGroups(
Collections.singletonList(
new ObservabilityPipelineConfigProcessorGroup()
.enabled(true)
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/datadog/api/client/ApiClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -800,6 +800,12 @@ public class ApiClient {
put("v2.updateMonitorUserTemplate", false);
put("v2.validateExistingMonitorUserTemplate", false);
put("v2.validateMonitorUserTemplate", false);
put("v2.createPipeline", false);
put("v2.deletePipeline", false);
put("v2.getPipeline", false);
put("v2.listPipelines", false);
put("v2.updatePipeline", false);
put("v2.validatePipeline", false);
put("v2.listRoleTemplates", false);
put("v2.createConnection", false);
put("v2.deleteConnection", false);
Expand All @@ -811,12 +817,6 @@ public class ApiClient {
put("v2.queryEventFilteredUsers", false);
put("v2.queryUsers", false);
put("v2.updateConnection", false);
put("v2.createPipeline", false);
put("v2.deletePipeline", false);
put("v2.getPipeline", false);
put("v2.listPipelines", false);
put("v2.updatePipeline", false);
put("v2.validatePipeline", false);
put("v2.createScorecardOutcomesBatch", false);
put("v2.createScorecardRule", false);
put("v2.deleteScorecardRule", false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public ApiResponse<ObservabilityPipeline> createPipelineWithHttpInfo(
400, "Missing the required parameter 'body' when calling createPipeline");
}
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines";
String localVarPath = "/api/v2/obs-pipelines/pipelines";

Map<String, String> localVarHeaderParams = new HashMap<String, String>();

Expand Down Expand Up @@ -166,7 +166,7 @@ public CompletableFuture<ApiResponse<ObservabilityPipeline>> createPipelineWithH
return result;
}
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines";
String localVarPath = "/api/v2/obs-pipelines/pipelines";

Map<String, String> localVarHeaderParams = new HashMap<String, String>();

Expand Down Expand Up @@ -618,7 +618,7 @@ public ApiResponse<ListPipelinesResponse> listPipelinesWithHttpInfo(
Long pageSize = parameters.pageSize;
Long pageNumber = parameters.pageNumber;
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines";
String localVarPath = "/api/v2/obs-pipelines/pipelines";

List<Pair> localVarQueryParams = new ArrayList<Pair>();
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
Expand Down Expand Up @@ -670,7 +670,7 @@ public CompletableFuture<ApiResponse<ListPipelinesResponse>> listPipelinesWithHt
Long pageSize = parameters.pageSize;
Long pageNumber = parameters.pageNumber;
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines";
String localVarPath = "/api/v2/obs-pipelines/pipelines";

List<Pair> localVarQueryParams = new ArrayList<Pair>();
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
Expand Down Expand Up @@ -946,7 +946,7 @@ public ApiResponse<ValidationResponse> validatePipelineWithHttpInfo(
400, "Missing the required parameter 'body' when calling validatePipeline");
}
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines/validate";
String localVarPath = "/api/v2/obs-pipelines/pipelines/validate";

Map<String, String> localVarHeaderParams = new HashMap<String, String>();

Expand Down Expand Up @@ -1001,7 +1001,7 @@ public CompletableFuture<ApiResponse<ValidationResponse>> validatePipelineWithHt
return result;
}
// create path and map variables
String localVarPath = "/api/v2/remote_config/products/obs_pipelines/pipelines/validate";
String localVarPath = "/api/v2/obs-pipelines/pipelines/validate";

Map<String, String> localVarHeaderParams = new HashMap<String, String>();

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,268 @@
/*
* 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 2019-Present Datadog, Inc.
*/

package com.datadog.api.client.v2.model;

import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import java.util.HashMap;
import java.util.Map;
import java.util.Objects;

/** The <code>add_hostname</code> processor adds the hostname to log events. */
@JsonPropertyOrder({
ObservabilityPipelineAddHostnameProcessor.JSON_PROPERTY_DISPLAY_NAME,
ObservabilityPipelineAddHostnameProcessor.JSON_PROPERTY_ENABLED,
ObservabilityPipelineAddHostnameProcessor.JSON_PROPERTY_ID,
ObservabilityPipelineAddHostnameProcessor.JSON_PROPERTY_INCLUDE,
ObservabilityPipelineAddHostnameProcessor.JSON_PROPERTY_TYPE
})
@jakarta.annotation.Generated(
value = "https://github.com/DataDog/datadog-api-client-java/blob/master/.generator")
public class ObservabilityPipelineAddHostnameProcessor {
@JsonIgnore public boolean unparsed = false;
public static final String JSON_PROPERTY_DISPLAY_NAME = "display_name";
private String displayName;

public static final String JSON_PROPERTY_ENABLED = "enabled";
private Boolean enabled;

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

public static final String JSON_PROPERTY_INCLUDE = "include";
private String include;

public static final String JSON_PROPERTY_TYPE = "type";
private ObservabilityPipelineAddHostnameProcessorType type =
ObservabilityPipelineAddHostnameProcessorType.ADD_HOSTNAME;

public ObservabilityPipelineAddHostnameProcessor() {}

@JsonCreator
public ObservabilityPipelineAddHostnameProcessor(
@JsonProperty(required = true, value = JSON_PROPERTY_ENABLED) Boolean enabled,
@JsonProperty(required = true, value = JSON_PROPERTY_ID) String id,
@JsonProperty(required = true, value = JSON_PROPERTY_INCLUDE) String include,
@JsonProperty(required = true, value = JSON_PROPERTY_TYPE)
ObservabilityPipelineAddHostnameProcessorType type) {
this.enabled = enabled;
this.id = id;
this.include = include;
this.type = type;
this.unparsed |= !type.isValid();
}

public ObservabilityPipelineAddHostnameProcessor displayName(String displayName) {
this.displayName = displayName;
return this;
}

/**
* The display name for a component.
*
* @return displayName
*/
@jakarta.annotation.Nullable
@JsonProperty(JSON_PROPERTY_DISPLAY_NAME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getDisplayName() {
return displayName;
}

public void setDisplayName(String displayName) {
this.displayName = displayName;
}

public ObservabilityPipelineAddHostnameProcessor enabled(Boolean enabled) {
this.enabled = enabled;
return this;
}

/**
* Whether this processor is enabled.
*
* @return enabled
*/
@JsonProperty(JSON_PROPERTY_ENABLED)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public Boolean getEnabled() {
return enabled;
}

public void setEnabled(Boolean enabled) {
this.enabled = enabled;
}

public ObservabilityPipelineAddHostnameProcessor id(String id) {
this.id = id;
return this;
}

/**
* The unique identifier for this component. Used to reference this component in other parts of
* the pipeline (for example, as the <code>input</code> to downstream components).
*
* @return id
*/
@JsonProperty(JSON_PROPERTY_ID)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getId() {
return id;
}

public void setId(String id) {
this.id = id;
}

public ObservabilityPipelineAddHostnameProcessor include(String include) {
this.include = include;
return this;
}

/**
* A Datadog search query used to determine which logs this processor targets.
*
* @return include
*/
@JsonProperty(JSON_PROPERTY_INCLUDE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getInclude() {
return include;
}

public void setInclude(String include) {
this.include = include;
}

public ObservabilityPipelineAddHostnameProcessor type(
ObservabilityPipelineAddHostnameProcessorType type) {
this.type = type;
this.unparsed |= !type.isValid();
return this;
}

/**
* The processor type. The value should always be <code>add_hostname</code>.
*
* @return type
*/
@JsonProperty(JSON_PROPERTY_TYPE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public ObservabilityPipelineAddHostnameProcessorType getType() {
return type;
}

public void setType(ObservabilityPipelineAddHostnameProcessorType type) {
if (!type.isValid()) {
this.unparsed = true;
}
this.type = type;
}

/**
* A container for additional, undeclared properties. This is a holder for any undeclared
* properties as specified with the 'additionalProperties' keyword in the OAS document.
*/
private Map<String, Object> additionalProperties;

/**
* Set the additional (undeclared) property with the specified name and value. If the property
* does not already exist, create it otherwise replace it.
*
* @param key The arbitrary key to set
* @param value The associated value
* @return ObservabilityPipelineAddHostnameProcessor
*/
@JsonAnySetter
public ObservabilityPipelineAddHostnameProcessor putAdditionalProperty(String key, Object value) {
if (this.additionalProperties == null) {
this.additionalProperties = new HashMap<String, Object>();
}
this.additionalProperties.put(key, value);
return this;
}

/**
* Return the additional (undeclared) property.
*
* @return The additional properties
*/
@JsonAnyGetter
public Map<String, Object> getAdditionalProperties() {
return additionalProperties;
}

/**
* Return the additional (undeclared) property with the specified name.
*
* @param key The arbitrary key to get
* @return The specific additional property for the given key
*/
public Object getAdditionalProperty(String key) {
if (this.additionalProperties == null) {
return null;
}
return this.additionalProperties.get(key);
}

/** Return true if this ObservabilityPipelineAddHostnameProcessor object is equal to o. */
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
ObservabilityPipelineAddHostnameProcessor observabilityPipelineAddHostnameProcessor =
(ObservabilityPipelineAddHostnameProcessor) o;
return Objects.equals(this.displayName, observabilityPipelineAddHostnameProcessor.displayName)
&& Objects.equals(this.enabled, observabilityPipelineAddHostnameProcessor.enabled)
&& Objects.equals(this.id, observabilityPipelineAddHostnameProcessor.id)
&& Objects.equals(this.include, observabilityPipelineAddHostnameProcessor.include)
&& Objects.equals(this.type, observabilityPipelineAddHostnameProcessor.type)
&& Objects.equals(
this.additionalProperties,
observabilityPipelineAddHostnameProcessor.additionalProperties);
}

@Override
public int hashCode() {
return Objects.hash(displayName, enabled, id, include, type, additionalProperties);
}

@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class ObservabilityPipelineAddHostnameProcessor {\n");
sb.append(" displayName: ").append(toIndentedString(displayName)).append("\n");
sb.append(" enabled: ").append(toIndentedString(enabled)).append("\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" include: ").append(toIndentedString(include)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" additionalProperties: ")
.append(toIndentedString(additionalProperties))
.append("\n");
sb.append('}');
return sb.toString();
}

/**
* Convert the given object to string with each line indented by 4 spaces (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
Loading
Loading