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
5 changes: 0 additions & 5 deletions .generator/schemas/v2/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38611,7 +38611,6 @@ components:
type: STRING
primary_keys:
- id
sync_enabled: false
tags:
- test_tag
type: reference_table
Expand Down Expand Up @@ -38643,10 +38642,6 @@ components:
$ref: '#/components/schemas/PatchTableRequestDataAttributesFileMetadata'
schema:
$ref: '#/components/schemas/PatchTableRequestDataAttributesSchema'
sync_enabled:
description: Whether this table is synced automatically.
example: false
type: boolean
tags:
description: Tags for organizing and filtering reference tables.
example:
Expand Down
1 change: 0 additions & 1 deletion examples/v2_reference-tables_UpdateReferenceTable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ async fn main() {
vec!["id".to_string()],
),
)
.sync_enabled(false)
.tags(vec!["test_tag".to_string()]),
),
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ pub struct PatchTableRequestDataAttributes {
/// Schema defining the updates to the structure and columns of the reference table. Schema fields cannot be deleted or renamed.
#[serde(rename = "schema")]
pub schema: Option<crate::datadogV2::model::PatchTableRequestDataAttributesSchema>,
/// Whether this table is synced automatically.
#[serde(rename = "sync_enabled")]
pub sync_enabled: Option<bool>,
/// Tags for organizing and filtering reference tables.
#[serde(rename = "tags")]
pub tags: Option<Vec<String>>,
Expand All @@ -39,7 +36,6 @@ impl PatchTableRequestDataAttributes {
description: None,
file_metadata: None,
schema: None,
sync_enabled: None,
tags: None,
additional_properties: std::collections::BTreeMap::new(),
_unparsed: false,
Expand Down Expand Up @@ -67,11 +63,6 @@ impl PatchTableRequestDataAttributes {
self
}

pub fn sync_enabled(mut self, value: bool) -> Self {
self.sync_enabled = Some(value);
self
}

pub fn tags(mut self, value: Vec<String>) -> Self {
self.tags = Some(value);
self
Expand Down Expand Up @@ -116,7 +107,6 @@ impl<'de> Deserialize<'de> for PatchTableRequestDataAttributes {
let mut schema: Option<
crate::datadogV2::model::PatchTableRequestDataAttributesSchema,
> = None;
let mut sync_enabled: Option<bool> = None;
let mut tags: Option<Vec<String>> = None;
let mut additional_properties: std::collections::BTreeMap<
String,
Expand Down Expand Up @@ -154,13 +144,6 @@ impl<'de> Deserialize<'de> for PatchTableRequestDataAttributes {
}
schema = Some(serde_json::from_value(v).map_err(M::Error::custom)?);
}
"sync_enabled" => {
if v.is_null() {
continue;
}
sync_enabled =
Some(serde_json::from_value(v).map_err(M::Error::custom)?);
}
"tags" => {
if v.is_null() {
continue;
Expand All @@ -179,7 +162,6 @@ impl<'de> Deserialize<'de> for PatchTableRequestDataAttributes {
description,
file_metadata,
schema,
sync_enabled,
tags,
additional_properties,
_unparsed,
Expand Down
4 changes: 2 additions & 2 deletions tests/scenarios/features/v2/reference_tables.feature
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,14 @@ Feature: Reference Tables
Scenario: Update reference table returns "Bad Request" response
Given new "UpdateReferenceTable" request
And request contains "id" parameter from "REPLACE.ME"
And body with value {"data": {"attributes": {"description": "this is a cloud table generated via a cloud bucket sync", "file_metadata": {"access_details": {"aws_detail": {"aws_account_id": "test-account-id", "aws_bucket_name": "test-bucket", "file_path": "test_rt.csv"}}, "sync_enabled": true}, "schema": {"fields": [{"name": "id", "type": "INT32"}, {"name": "name", "type": "STRING"}], "primary_keys": ["id"]}, "sync_enabled": false, "tags": ["test_tag"]}, "type": "reference_table"}}
And body with value {"data": {"attributes": {"description": "this is a cloud table generated via a cloud bucket sync", "file_metadata": {"access_details": {"aws_detail": {"aws_account_id": "test-account-id", "aws_bucket_name": "test-bucket", "file_path": "test_rt.csv"}}, "sync_enabled": true}, "schema": {"fields": [{"name": "id", "type": "INT32"}, {"name": "name", "type": "STRING"}], "primary_keys": ["id"]}, "tags": ["test_tag"]}, "type": "reference_table"}}
When the request is sent
Then the response status is 400 Bad Request

@generated @skip @team:DataDog/redapl-experiences
Scenario: Update reference table returns "OK" response
Given new "UpdateReferenceTable" request
And request contains "id" parameter from "REPLACE.ME"
And body with value {"data": {"attributes": {"description": "this is a cloud table generated via a cloud bucket sync", "file_metadata": {"access_details": {"aws_detail": {"aws_account_id": "test-account-id", "aws_bucket_name": "test-bucket", "file_path": "test_rt.csv"}}, "sync_enabled": true}, "schema": {"fields": [{"name": "id", "type": "INT32"}, {"name": "name", "type": "STRING"}], "primary_keys": ["id"]}, "sync_enabled": false, "tags": ["test_tag"]}, "type": "reference_table"}}
And body with value {"data": {"attributes": {"description": "this is a cloud table generated via a cloud bucket sync", "file_metadata": {"access_details": {"aws_detail": {"aws_account_id": "test-account-id", "aws_bucket_name": "test-bucket", "file_path": "test_rt.csv"}}, "sync_enabled": true}, "schema": {"fields": [{"name": "id", "type": "INT32"}, {"name": "name", "type": "STRING"}], "primary_keys": ["id"]}, "tags": ["test_tag"]}, "type": "reference_table"}}
When the request is sent
Then the response status is 200 OK