From 84029af27e98367c1e6e861fc35f42153f7c0c47 Mon Sep 17 00:00:00 2001 From: "api-clients-generation-pipeline[bot]" <54105614+api-clients-generation-pipeline[bot]@users.noreply.github.com> Date: Wed, 30 Sep 2020 18:36:45 +0200 Subject: [PATCH] Regenerate client from commit cc01f26 of spec repo (#496) Co-authored-by: ci.datadog-api-spec --- .apigentools-info | 8 ++++---- api/v2/datadog/api/openapi.yaml | 7 ++----- api/v2/datadog/api_logs.go | 9 +-------- api/v2/datadog/configuration.go | 1 - tests/api/v2/datadog/features/logs.feature | 3 +-- 5 files changed, 8 insertions(+), 20 deletions(-) diff --git a/.apigentools-info b/.apigentools-info index c0e6224d98e..1eda7655ed3 100644 --- a/.apigentools-info +++ b/.apigentools-info @@ -4,13 +4,13 @@ "spec_versions": { "v1": { "apigentools_version": "1.2.0", - "regenerated": "2020-09-30 14:10:51.893721", - "spec_repo_commit": "8738cfd" + "regenerated": "2020-09-30 16:18:15.216075", + "spec_repo_commit": "cc01f26" }, "v2": { "apigentools_version": "1.2.0", - "regenerated": "2020-09-30 14:10:58.002512", - "spec_repo_commit": "8738cfd" + "regenerated": "2020-09-30 16:18:20.769554", + "spec_repo_commit": "cc01f26" } } } \ No newline at end of file diff --git a/api/v2/datadog/api/openapi.yaml b/api/v2/datadog/api/openapi.yaml index e87c66741c2..be7409daf67 100644 --- a/api/v2/datadog/api/openapi.yaml +++ b/api/v2/datadog/api/openapi.yaml @@ -257,8 +257,8 @@ paths: x-codegen-request-body-name: body /api/v2/logs/analytics/aggregate: post: - description: The public API endpoint to aggregate events into buckets and compute - metrics and timeseries. + description: The API endpoint to aggregate events into buckets and compute metrics + and timeseries. operationId: AggregateLogs requestBody: content: @@ -288,9 +288,6 @@ paths: tags: - Logs x-codegen-request-body-name: body - x-unstable: |- - **Note**: This endpoint is in public beta. - If you have any feedback, contact [Datadog support](https://docs.datadoghq.com/help/). /api/v2/logs/config/archives: get: description: Get the list of configured logs archives with their definitions. diff --git a/api/v2/datadog/api_logs.go b/api/v2/datadog/api_logs.go index 194b56901e9..7afaf7b4927 100644 --- a/api/v2/datadog/api_logs.go +++ b/api/v2/datadog/api_logs.go @@ -43,7 +43,7 @@ func (r ApiAggregateLogsRequest) Execute() (LogsAggregateResponse, *_nethttp.Res /* * AggregateLogs Aggregate events - * The public API endpoint to aggregate events into buckets and compute metrics and timeseries. + * The API endpoint to aggregate events into buckets and compute metrics and timeseries. * @param ctx _context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @return ApiAggregateLogsRequest */ @@ -68,13 +68,6 @@ func (a *LogsApiService) AggregateLogsExecute(r ApiAggregateLogsRequest) (LogsAg localVarReturnValue LogsAggregateResponse ) - operationId := "AggregateLogs" - if r.ApiService.client.cfg.IsUnstableOperationEnabled(operationId) { - _log.Printf("WARNING: Using unstable operation '%s'", operationId) - } else { - return localVarReturnValue, nil, GenericOpenAPIError{error: _fmt.Sprintf("Unstable operation '%s' is disabled", operationId)} - } - localBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, "LogsApiService.AggregateLogs") if err != nil { return localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()} diff --git a/api/v2/datadog/configuration.go b/api/v2/datadog/configuration.go index 0083b3b3241..1edb2eb34fc 100644 --- a/api/v2/datadog/configuration.go +++ b/api/v2/datadog/configuration.go @@ -142,7 +142,6 @@ func NewConfiguration() *Configuration { }, OperationServers: map[string]ServerConfigurations{}, unstableOperations: map[string]bool{ - "AggregateLogs": false, "ListLogs": false, "ListLogsGet": false, "AddReadRoleToArchive": false, diff --git a/tests/api/v2/datadog/features/logs.feature b/tests/api/v2/datadog/features/logs.feature index 43e5f6b0798..32645a15967 100644 --- a/tests/api/v2/datadog/features/logs.feature +++ b/tests/api/v2/datadog/features/logs.feature @@ -27,8 +27,7 @@ Feature: Logs Then the response status is 200 OK Scenario: Aggregate events returns "OK" response - Given operation "AggregateLogs" enabled - And new "AggregateLogs" request + Given new "AggregateLogs" request And body {"compute": [{"aggregation": "count", "interval": "300", "metric": "test.aggregation.{{ unique }}", "type": "timeseries"}], "filter": {"from": "1600348573", "indexes": ["main"], "query": "datadog-agent", "to": "1600348600"}} When the request is sent Then the response status is 200 OK