From 8eef4924f4653226875385b80a6718987c2cc530 Mon Sep 17 00:00:00 2001 From: "databricks-ci-ghec-2[bot]" <184307802+databricks-ci-ghec-2[bot]@users.noreply.github.com> Date: Sat, 18 Jul 2026 03:33:43 +0000 Subject: [PATCH] Update SDK to c235e54b9b6176af240981f9efb71bac931e3025 --- .codegen/_openapi_sha | 2 +- NEXT_CHANGELOG.md | 2 + .../sdk/service/ml/StreamSource.java | 42 +++++++++++++++++-- .../sdk/service/ml/UcTraceLocation.java | 23 +++++++++- .../sdk/service/postgres/PostgresAPI.java | 29 +++++++++---- .../sdk/service/postgres/PostgresService.java | 29 +++++++++---- 6 files changed, 103 insertions(+), 24 deletions(-) diff --git a/.codegen/_openapi_sha b/.codegen/_openapi_sha index 3fa3c1d2d..5b1909bd6 100644 --- a/.codegen/_openapi_sha +++ b/.codegen/_openapi_sha @@ -1 +1 @@ -e0647ba6804a08bc727c2c58a0f4cd9774da1313 \ No newline at end of file +c235e54b9b6176af240981f9efb71bac931e3025 \ No newline at end of file diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index 5361e4c66..5a43f0bbc 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -15,3 +15,5 @@ ### Internal Changes ### API Changes +* Add `dataframeSchema` and `transformationSql` fields for `com.databricks.sdk.service.ml.StreamSource`. +* Add `effectiveTablePrefix` field for `com.databricks.sdk.service.ml.UcTraceLocation`. \ No newline at end of file diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/StreamSource.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/StreamSource.java index 536ef9735..e177bab4d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/StreamSource.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/StreamSource.java @@ -10,6 +10,13 @@ /** A Stream entity used as a data source for a feature. */ @Generated public class StreamSource { + /** + * Schema of the resulting dataframe after transformations, in Spark StructType JSON format (from + * df.schema.json()). Any subsequent functions operate against this dataframe. + */ + @JsonProperty("dataframe_schema") + private String dataframeSchema; + /** The filter condition applied to the source data before aggregation. */ @JsonProperty("filter_condition") private String filterCondition; @@ -18,6 +25,22 @@ public class StreamSource { @JsonProperty("full_name") private String fullName; + /** + * The pipeline runs these SQL statements immediately after conversion into the schema specified + * on the Stream object. + */ + @JsonProperty("transformation_sql") + private String transformationSql; + + public StreamSource setDataframeSchema(String dataframeSchema) { + this.dataframeSchema = dataframeSchema; + return this; + } + + public String getDataframeSchema() { + return dataframeSchema; + } + public StreamSource setFilterCondition(String filterCondition) { this.filterCondition = filterCondition; return this; @@ -36,25 +59,38 @@ public String getFullName() { return fullName; } + public StreamSource setTransformationSql(String transformationSql) { + this.transformationSql = transformationSql; + return this; + } + + public String getTransformationSql() { + return transformationSql; + } + @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; StreamSource that = (StreamSource) o; - return Objects.equals(filterCondition, that.filterCondition) - && Objects.equals(fullName, that.fullName); + return Objects.equals(dataframeSchema, that.dataframeSchema) + && Objects.equals(filterCondition, that.filterCondition) + && Objects.equals(fullName, that.fullName) + && Objects.equals(transformationSql, that.transformationSql); } @Override public int hashCode() { - return Objects.hash(filterCondition, fullName); + return Objects.hash(dataframeSchema, filterCondition, fullName, transformationSql); } @Override public String toString() { return new ToStringer(StreamSource.class) + .add("dataframeSchema", dataframeSchema) .add("filterCondition", filterCondition) .add("fullName", fullName) + .add("transformationSql", transformationSql) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/UcTraceLocation.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/UcTraceLocation.java index c88f33589..d60d57e20 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/UcTraceLocation.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/UcTraceLocation.java @@ -17,6 +17,13 @@ public class UcTraceLocation { @JsonProperty("catalog") private String catalog; + /** + * The trace-table prefix actually in effect: `table_prefix` if it was set on creation, otherwise + * the server-generated default. + */ + @JsonProperty("effective_table_prefix") + private String effectiveTablePrefix; + /** The name of the Unity Catalog schema within `catalog`. */ @JsonProperty("schema") private String schema; @@ -24,7 +31,8 @@ public class UcTraceLocation { /** * The prefix for the trace tables, which are named `{catalog}.{schema}.{table_prefix}_otel_*`. * May only contain letters, digits, and underscores, and may be at most 238 characters. When - * unset, a server-generated prefix derived from the experiment ID is used. + * unset, a server-generated prefix derived from the experiment ID is used and this field stays + * empty on read; the resolved value is always available in `effective_table_prefix`. */ @JsonProperty("table_prefix") private String tablePrefix; @@ -38,6 +46,15 @@ public String getCatalog() { return catalog; } + public UcTraceLocation setEffectiveTablePrefix(String effectiveTablePrefix) { + this.effectiveTablePrefix = effectiveTablePrefix; + return this; + } + + public String getEffectiveTablePrefix() { + return effectiveTablePrefix; + } + public UcTraceLocation setSchema(String schema) { this.schema = schema; return this; @@ -62,19 +79,21 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) return false; UcTraceLocation that = (UcTraceLocation) o; return Objects.equals(catalog, that.catalog) + && Objects.equals(effectiveTablePrefix, that.effectiveTablePrefix) && Objects.equals(schema, that.schema) && Objects.equals(tablePrefix, that.tablePrefix); } @Override public int hashCode() { - return Objects.hash(catalog, schema, tablePrefix); + return Objects.hash(catalog, effectiveTablePrefix, schema, tablePrefix); } @Override public String toString() { return new ToStringer(UcTraceLocation.class) .add("catalog", catalog) + .add("effectiveTablePrefix", effectiveTablePrefix) .add("schema", schema) .add("tablePrefix", tablePrefix) .toString(); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresAPI.java index 41afbfd03..ff96fcf4e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresAPI.java @@ -50,9 +50,9 @@ public CreateCatalogOperation createCatalog(CreateCatalogRequest request) { } /** - * Create a Lakebase CDF configuration (CdfConfig). Replicates the tables of a Postgres schema - * into a Unity Catalog schema. Returns ALREADY_EXISTS if a config with the requested id exists, - * or if another config already replicates the target Postgres schema. + * Create a CDF configuration that materializes the change data feed for all tables in a Postgres + * schema as open-format Delta tables in Unity Catalog. Once created, each table's change history + * is continuously written to its corresponding Lakehouse table. */ public CreateCdfConfigOperation createCdfConfig(CreateCdfConfigRequest request) { Operation operation = impl.createCdfConfig(request); @@ -127,8 +127,9 @@ public DeleteCdfConfigOperation deleteCdfConfig(String name) { } /** - * Delete a Lakebase CDF configuration (CdfConfig). Stops replication and removes the config. When - * force is true, also drops the replicated Delta tables in Unity Catalog. + * Delete a CDF configuration and stop materializing the change data feed. When force=true, also + * drops the Delta tables in Unity Catalog. When force=false (default), the existing tables are + * preserved at their last state. */ public DeleteCdfConfigOperation deleteCdfConfig(DeleteCdfConfigRequest request) { Operation operation = impl.deleteCdfConfig(request); @@ -222,7 +223,10 @@ public CdfConfig getCdfConfig(String name) { return getCdfConfig(new GetCdfConfigRequest().setName(name)); } - /** Get a single Lakebase CDF configuration (CdfConfig). */ + /** + * Get a single Lakebase CDF configuration, including the source Postgres schema, target Unity + * Catalog schema, and the identity under which writes are authorized. + */ public CdfConfig getCdfConfig(GetCdfConfigRequest request) { return impl.getCdfConfig(request); } @@ -232,7 +236,8 @@ public CdfStatus getCdfStatus(String name) { } /** - * Get the replication status of a single replicated table within a Lakebase CDF configuration. + * Get the CDF status of a single table within a Lakebase CDF configuration, including its current + * state and the last committed position in the feed. */ public CdfStatus getCdfStatus(GetCdfStatusRequest request) { return impl.getCdfStatus(request); @@ -330,7 +335,10 @@ public Iterable listCdfConfigs(String parent) { return listCdfConfigs(new ListCdfConfigsRequest().setParent(parent)); } - /** List the Lakebase CDF configurations (CdfConfigs) under a database. */ + /** + * List all CDF configurations for a Lakebase database. Each configuration maps a Postgres schema + * to a Unity Catalog schema where the change data feed is materialized. + */ public Iterable listCdfConfigs(ListCdfConfigsRequest request) { return Paginator.newTokenPagination( request, @@ -349,7 +357,10 @@ public Iterable listCdfStatuses(String parent) { return listCdfStatuses(new ListCdfStatusesRequest().setParent(parent)); } - /** List the replication statuses of all tables replicated under a Lakebase CDF configuration. */ + /** + * List the per-table CDF statuses within a Lakebase CDF configuration. Each status shows whether + * a table's change data feed is snapshotting, streaming, or skipped. + */ public Iterable listCdfStatuses(ListCdfStatusesRequest request) { return Paginator.newTokenPagination( request, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresService.java index aa54b53fb..29399356b 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/PostgresService.java @@ -30,9 +30,9 @@ public interface PostgresService { Operation createCatalog(CreateCatalogRequest createCatalogRequest); /** - * Create a Lakebase CDF configuration (CdfConfig). Replicates the tables of a Postgres schema - * into a Unity Catalog schema. Returns ALREADY_EXISTS if a config with the requested id exists, - * or if another config already replicates the target Postgres schema. + * Create a CDF configuration that materializes the change data feed for all tables in a Postgres + * schema as open-format Delta tables in Unity Catalog. Once created, each table's change history + * is continuously written to its corresponding Lakehouse table. */ Operation createCdfConfig(CreateCdfConfigRequest createCdfConfigRequest); @@ -68,8 +68,9 @@ public interface PostgresService { Operation deleteCatalog(DeleteCatalogRequest deleteCatalogRequest); /** - * Delete a Lakebase CDF configuration (CdfConfig). Stops replication and removes the config. When - * force is true, also drops the replicated Delta tables in Unity Catalog. + * Delete a CDF configuration and stop materializing the change data feed. When force=true, also + * drops the Delta tables in Unity Catalog. When force=false (default), the existing tables are + * preserved at their last state. */ Operation deleteCdfConfig(DeleteCdfConfigRequest deleteCdfConfigRequest); @@ -101,11 +102,15 @@ DatabaseCredential generateDatabaseCredential( /** Get a Database Catalog. */ Catalog getCatalog(GetCatalogRequest getCatalogRequest); - /** Get a single Lakebase CDF configuration (CdfConfig). */ + /** + * Get a single Lakebase CDF configuration, including the source Postgres schema, target Unity + * Catalog schema, and the identity under which writes are authorized. + */ CdfConfig getCdfConfig(GetCdfConfigRequest getCdfConfigRequest); /** - * Get the replication status of a single replicated table within a Lakebase CDF configuration. + * Get the CDF status of a single table within a Lakebase CDF configuration, including its current + * state and the last committed position in the feed. */ CdfStatus getCdfStatus(GetCdfStatusRequest getCdfStatusRequest); @@ -139,10 +144,16 @@ DatabaseCredential generateDatabaseCredential( /** Returns a paginated list of database branches in the project. */ ListBranchesResponse listBranches(ListBranchesRequest listBranchesRequest); - /** List the Lakebase CDF configurations (CdfConfigs) under a database. */ + /** + * List all CDF configurations for a Lakebase database. Each configuration maps a Postgres schema + * to a Unity Catalog schema where the change data feed is materialized. + */ ListCdfConfigsResponse listCdfConfigs(ListCdfConfigsRequest listCdfConfigsRequest); - /** List the replication statuses of all tables replicated under a Lakebase CDF configuration. */ + /** + * List the per-table CDF statuses within a Lakebase CDF configuration. Each status shows whether + * a table's change data feed is snapshotting, streaming, or skipped. + */ ListCdfStatusesResponse listCdfStatuses(ListCdfStatusesRequest listCdfStatusesRequest); /** List Databases. */