From 489412c8ad101902c44cd5351d98e8cfdd63ca5f Mon Sep 17 00:00:00 2001 From: Ly Nguyen Date: Thu, 31 Aug 2023 13:13:12 -0700 Subject: [PATCH 1/3] Release note: changes to Discovery API endpoints --- .../deprecation-endpoints-discovery.md | 126 ++++++++++++++++++ 1 file changed, 126 insertions(+) create mode 100644 website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md diff --git a/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md new file mode 100644 index 00000000000..b821a5ae764 --- /dev/null +++ b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md @@ -0,0 +1,126 @@ +--- +title: "Query patterns and endpoints in the dbt Cloud Discovery API" +description: "August 2023: Learn about the upcoming deprecation of certain endpoints and query patterns in the Discovery API." +sidebar_position: 6 +sidebar_label: "Deprecation: Certain Dicovery API endpoints and query patterns" +tags: [Aug-2023, API] +date: 2023-08-31 +--- + +dbt Labs has deprecated and will be deprecating certain query patterns and replacing them with new conventions that will enhance the performance of the dbt Cloud [Discovery API](/docs/dbt-cloud-apis/discovery-api). + +All these changes will be in effect on _September 7, 2023_. + +We understand that these changes might require adjustments to your existing integration with the Discovery API. Please [contact us](mailto:support@getdbt.com) with any questions. We're here to help you during this transition period. + +## Job-based queries + +Job-based queries that use the data type `Int` for IDs will be deprecated. They will be marked as deprecated in the [GraphQL explorer](https://metadata.cloud.getdbt.com/graphql). The new convention will be for you to use the data type `BigInt` instead. + +This change will be in effect starting September 7, 2023. + + +Example of query before deprecation: + +```graphql +query ($jobId: Int!) { + models(jobId: $jobId){ + uniqueId + } +} +``` + +Example of query after deprecation: + +```graphql +query ($jobId: BigInt!) { + job(id: $jobId) { + models { + uniqueId + } + } +} +``` + +## modelByEnvironment queries + +The `modelByEnvironment` object will be renamed and is being moved into the `environment` object. This change is in effect starting August 15, 2023. + +Example of query before deprecation: + +```graphql +query ($environmentId: Int!, $uniqueId: String) { + modelByEnvironment(environmentId: $environmentId, uniqueId: $uniqueId) { + uniqueId + executionTime + executeCompletedAt + } +} +``` + +Example of query after deprecation: + +```graphql +query ($environmentId: BigInt!, $uniqueId: String) { + environment(id: $environmentId) { + applied { + modelHistoricalRuns(uniqueId: $uniqueId) { + uniqueId + executionTime + executeCompletedAt + } + } + } +} +``` + + +## Environment and account queries + +Environment and account queries that use `Int` as a data type for ID is deprecated. IDs now must be in `BigInt`. This change is in effect starting on August 15, 2023. + + +Example of query before deprecation: + +```graphql +query ($environmentId: Int!, $first: Int!) { + environment(id: $environmentId) { + applied { + models(first: $first) { + edges { + node { + uniqueId + executionInfo { + lastRunId + } + } + } + } + } + } +} +``` + + +Example of query after deprecation: + +```graphql +query ($environmentId: BigInt!, $first: Int!) { + environment(id: $environmentId) { + applied { + models(first: $first) { + edges { + node { + uniqueId + executionInfo { + lastRunId + } + } + } + } + } + } +} +``` + + From e85a2a61c892546be8bd922c88994d9df605b265 Mon Sep 17 00:00:00 2001 From: Ly Nguyen Date: Thu, 31 Aug 2023 13:41:08 -0700 Subject: [PATCH 2/3] Minor tweaks --- .../05-Aug-2023/deprecation-endpoints-discovery.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md index b821a5ae764..540d6d21b18 100644 --- a/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md +++ b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md @@ -7,7 +7,7 @@ tags: [Aug-2023, API] date: 2023-08-31 --- -dbt Labs has deprecated and will be deprecating certain query patterns and replacing them with new conventions that will enhance the performance of the dbt Cloud [Discovery API](/docs/dbt-cloud-apis/discovery-api). +dbt Labs has deprecated and will be deprecating certain query patterns and replacing them with new conventions to enhance the performance of the dbt Cloud [Discovery API](/docs/dbt-cloud-apis/discovery-api). All these changes will be in effect on _September 7, 2023_. @@ -44,7 +44,7 @@ query ($jobId: BigInt!) { ## modelByEnvironment queries -The `modelByEnvironment` object will be renamed and is being moved into the `environment` object. This change is in effect starting August 15, 2023. +The `modelByEnvironment` object has been renamed and moved into the `environment` object. This change is in effect and has been since August 15, 2023. Example of query before deprecation: @@ -77,7 +77,7 @@ query ($environmentId: BigInt!, $uniqueId: String) { ## Environment and account queries -Environment and account queries that use `Int` as a data type for ID is deprecated. IDs now must be in `BigInt`. This change is in effect starting on August 15, 2023. +Environment and account queries that use `Int` as a data type for ID has been deprecated. IDs must now be in `BigInt`. This change is in effect and has been since August 15, 2023. Example of query before deprecation: From 84fe4a912b637903181ccc22464969e7281c5c9a Mon Sep 17 00:00:00 2001 From: Ly Nguyen <107218380+nghi-ly@users.noreply.github.com> Date: Thu, 31 Aug 2023 15:12:18 -0700 Subject: [PATCH 3/3] Update website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md follow convention for sidebar label --- .../05-Aug-2023/deprecation-endpoints-discovery.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md index 540d6d21b18..d53f892a1ba 100644 --- a/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md +++ b/website/docs/docs/dbt-versions/release-notes/05-Aug-2023/deprecation-endpoints-discovery.md @@ -1,5 +1,5 @@ --- -title: "Query patterns and endpoints in the dbt Cloud Discovery API" +title: "Deprecation: Query patterns and endpoints in the dbt Cloud Discovery API" description: "August 2023: Learn about the upcoming deprecation of certain endpoints and query patterns in the Discovery API." sidebar_position: 6 sidebar_label: "Deprecation: Certain Dicovery API endpoints and query patterns"