diff --git a/.codegen/_openapi_sha b/.codegen/_openapi_sha index 37122a118..5a29b9f70 100644 --- a/.codegen/_openapi_sha +++ b/.codegen/_openapi_sha @@ -1 +1 @@ -27f7ea11e6b9d14b29e0881406a7a64bff9905b3 \ No newline at end of file +814778bb58d7b4027343bf0a9bf0d317680b1c0e \ No newline at end of file diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index 85df99641..840666396 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -44,4 +44,5 @@ * [Breaking] Change `projectId` field for `com.databricks.sdk.service.postgres.CreateProjectRequest` to be required. * [Breaking] Remove `default` field for `com.databricks.sdk.service.postgres.BranchSpec`. * [Breaking] Remove `settings` field for `com.databricks.sdk.service.postgres.ProjectSpec`. -* [Breaking] Remove `settings` field for `com.databricks.sdk.service.postgres.ProjectStatus`. \ No newline at end of file +* [Breaking] Remove `settings` field for `com.databricks.sdk.service.postgres.ProjectStatus`. +* Add `noExpiry` field for `com.databricks.sdk.service.postgres.BranchSpec`. \ No newline at end of file diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/BranchSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/BranchSpec.java index 5eb0f0e78..73a875e84 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/BranchSpec.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/BranchSpec.java @@ -22,6 +22,13 @@ public class BranchSpec { @JsonProperty("is_protected") private Boolean isProtected; + /** + * Explicitly disable expiration. When set to true, the branch will not expire. If set to false, + * the request is invalid; provide either ttl or expire_time instead. + */ + @JsonProperty("no_expiry") + private Boolean noExpiry; + /** * The name of the source branch from which this branch was created (data lineage for * point-in-time recovery). If not specified, defaults to the project's default branch. Format: @@ -38,10 +45,7 @@ public class BranchSpec { @JsonProperty("source_branch_time") private Timestamp sourceBranchTime; - /** - * Relative time-to-live duration. When set, the branch will expire at creation_time + ttl. Set to - * -1 second to explicitly disable expiration. - */ + /** Relative time-to-live duration. When set, the branch will expire at creation_time + ttl. */ @JsonProperty("ttl") private Duration ttl; @@ -63,6 +67,15 @@ public Boolean getIsProtected() { return isProtected; } + public BranchSpec setNoExpiry(Boolean noExpiry) { + this.noExpiry = noExpiry; + return this; + } + + public Boolean getNoExpiry() { + return noExpiry; + } + public BranchSpec setSourceBranch(String sourceBranch) { this.sourceBranch = sourceBranch; return this; @@ -106,6 +119,7 @@ public boolean equals(Object o) { BranchSpec that = (BranchSpec) o; return Objects.equals(expireTime, that.expireTime) && Objects.equals(isProtected, that.isProtected) + && Objects.equals(noExpiry, that.noExpiry) && Objects.equals(sourceBranch, that.sourceBranch) && Objects.equals(sourceBranchLsn, that.sourceBranchLsn) && Objects.equals(sourceBranchTime, that.sourceBranchTime) @@ -115,7 +129,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( - expireTime, isProtected, sourceBranch, sourceBranchLsn, sourceBranchTime, ttl); + expireTime, isProtected, noExpiry, sourceBranch, sourceBranchLsn, sourceBranchTime, ttl); } @Override @@ -123,6 +137,7 @@ public String toString() { return new ToStringer(BranchSpec.class) .add("expireTime", expireTime) .add("isProtected", isProtected) + .add("noExpiry", noExpiry) .add("sourceBranch", sourceBranch) .add("sourceBranchLsn", sourceBranchLsn) .add("sourceBranchTime", sourceBranchTime)