From 79eac32931ef1b3621ec1c2a7752eef3a2e5c7ec Mon Sep 17 00:00:00 2001 From: "databricks-ci-ghec-1[bot]" <184311507+databricks-ci-ghec-1[bot]@users.noreply.github.com> Date: Wed, 1 Jul 2026 03:49:50 +0000 Subject: [PATCH] Update SDK to 654461451d03b1cac88e8b2c30f15060d27f6295 --- .codegen/_openapi_sha | 2 +- .gitattributes | 31 +- .github/workflows/next-changelog.yml | 0 .github/workflows/tagging.yml | 4 +- NEXT_CHANGELOG.md | 41 + .../bundledeployments/WorkspaceInfo.java | 22 +- .../sdk/service/catalog/ConnectionType.java | 1 - .../sdk/service/catalog/CredentialType.java | 1 - .../sdk/service/catalog/Privilege.java | 1 + .../sdk/service/catalog/SchemaInfo.java | 1 - .../sdk/service/catalog/SecurableKind.java | 5 - .../service/catalog/UpdatePermissions.java | 20 +- .../catalog/ValidateCredentialRequest.java | 1 - .../cleanrooms/CleanRoomAssetNotebook.java | 4 +- .../sdk/service/cleanrooms/CleanRoomsAPI.java | 4 +- .../service/cleanrooms/CleanRoomsService.java | 4 +- ...ancelPendingClusterEnforcementRequest.java | 63 ++ ...ncelPendingClusterEnforcementResponse.java | 32 + .../service/compute/ClusterAttributes.java | 8 +- .../service/compute/ClusterCompliance.java | 20 +- .../sdk/service/compute/ClusterDetails.java | 8 +- .../sdk/service/compute/ClusterSpec.java | 8 +- .../sdk/service/compute/CreateCluster.java | 8 +- .../service/compute/CreateInstancePool.java | 8 +- .../sdk/service/compute/EditCluster.java | 8 +- .../sdk/service/compute/EditInstancePool.java | 4 +- .../EnforceClusterComplianceRequest.java | 29 +- .../EnforceClusterComplianceResponse.java | 21 +- ...PolicyComplianceForClusterEnforceMode.java | 11 + ...anceForClusterResponseClusterSettings.java | 706 ++++++++++++++++++ ...lianceForClusterResponseEnforceResult.java | 12 + .../sdk/service/compute/EventType.java | 2 + .../compute/GetClusterComplianceResponse.java | 20 +- .../sdk/service/compute/GetInstancePool.java | 8 +- .../service/compute/InstancePoolAndStats.java | 8 +- .../service/compute/PendingEnforcement.java | 119 +++ .../PendingEnforcementEnforcementStatus.java | 11 + .../PolicyComplianceForClustersAPI.java | 19 +- .../PolicyComplianceForClustersImpl.java | 19 + .../PolicyComplianceForClustersService.java | 17 +- .../compute/UpdateClusterResource.java | 8 +- ...MessageAttachmentVisualizationRequest.java | 47 ++ ...essageAttachmentVisualizationResponse.java | 45 ++ .../sdk/service/dashboards/GenieAPI.java | 16 + .../service/dashboards/GenieAttachment.java | 19 +- ...GenieCreateConversationMessageRequest.java | 17 +- .../sdk/service/dashboards/GenieImpl.java | 18 + .../sdk/service/dashboards/GenieService.java | 8 + .../GenieStartConversationMessageRequest.java | 20 +- .../dashboards/GenieVizAttachment.java | 63 ++ .../dashboards/ListDashboardsRequest.java | 2 +- .../dataclassification/CatalogConfig.java | 28 +- .../CatalogConfigSchemaNames.java | 2 +- .../dataquality/CreateRefreshRequest.java | 2 +- .../sdk/service/dataquality/Refresh.java | 2 +- .../disasterrecovery/FailoverGroup.java | 5 +- .../service/disasterrecovery/StableUrl.java | 2 +- .../UpdateFailoverGroupRequest.java | 24 +- .../disasterrecovery/WorkspaceSet.java | 5 +- .../service/environments/EnvironmentSpec.java | 73 ++ .../WorkspaceBaseEnvironment.java | 16 + .../databricks/sdk/service/iamv2/User.java | 30 +- .../{UserName.java => UserFullName.java} | 10 +- .../sdk/service/jobs/AiRuntimeTask.java | 138 ++++ .../sdk/service/jobs/AiRuntimeTaskOutput.java | 91 +++ .../sdk/service/jobs/ComputeSpec.java | 70 ++ .../jobs/ComputeSpecAcceleratorType.java | 22 + .../sdk/service/jobs/CronSchedule.java | 21 +- .../sdk/service/jobs/DeploymentSpec.java | 89 +++ .../sdk/service/jobs/ResolvedValues.java | 21 +- ...lvedValuesAiRuntimeTaskResolvedValues.java | 33 + .../sdk/service/jobs/RunOutput.java | 23 +- .../databricks/sdk/service/jobs/RunTask.java | 21 +- .../jobs/SqlConditionConfiguration.java | 80 ++ .../jobs/SqlConditionRunInfoDetails.java | 89 +++ .../sdk/service/jobs/SqlConditionState.java | 89 +++ .../service/jobs/SqlConditionTriggerMode.java | 22 + .../sdk/service/jobs/SubmitTask.java | 21 +- .../com/databricks/sdk/service/jobs/Task.java | 21 +- .../sdk/service/jobs/TriggerInfo.java | 22 +- .../sdk/service/jobs/TriggerSettings.java | 20 +- .../sdk/service/jobs/TriggerStateProto.java | 20 +- .../sdk/service/ml/AggregationFunction.java | 64 ++ .../service/ml/FirstDistinctNFunction.java | 56 ++ .../sdk/service/ml/FirstNFunction.java | 56 ++ .../sdk/service/ml/LastDistinctNFunction.java | 56 ++ .../sdk/service/ml/LastNFunction.java | 56 ++ .../oauth2/CustomAppIntegrationAPI.java | 12 +- .../oauth2/CustomAppIntegrationService.java | 12 +- .../oauth2/PublishedAppIntegrationAPI.java | 16 +- .../PublishedAppIntegrationService.java | 16 +- .../postgres/CreateDatabaseRequest.java | 20 +- .../service/postgres/CreateRoleRequest.java | 25 +- .../sdk/service/postgres/EndpointHosts.java | 42 +- .../sdk/service/postgres/EndpointStatus.java | 17 + .../GenerateDatabaseCredentialRequest.java | 61 +- .../service/postgres/InitialBranchSpec.java | 43 ++ .../service/postgres/InitialEndpointSpec.java | 77 +- .../sdk/service/postgres/Project.java | 20 + .../sdk/service/postgres/ProjectStatus.java | 17 + .../serving/CreateServingEndpoint.java | 23 +- .../sdk/service/serving/ServingEndpoint.java | 16 + .../serving/ServingEndpointDetailed.java | 20 +- .../sdk/service/serving/TelemetryConfig.java | 45 ++ .../TelemetryInferenceTableConfig.java | 63 ++ .../service/settings/IpAccessListsAPI.java | 12 +- .../settings/IpAccessListsService.java | 12 +- .../gentesting/unittests/HttpPathTest.java | 23 +- .../sdk/service/httpcallv2/HttpCallV2API.java | 35 +- .../service/httpcallv2/HttpCallV2Impl.java | 21 + .../service/httpcallv2/HttpCallV2Service.java | 33 +- .../httpcallv2/SyncResourceRequest.java | 75 ++ .../sdk/service/lrotesting/LroTestingAPI.java | 8 +- .../service/lrotesting/LroTestingService.java | 8 +- tagging.py | 1 - 115 files changed, 3600 insertions(+), 147 deletions(-) mode change 100755 => 100644 .codegen/_openapi_sha mode change 100755 => 100644 .gitattributes mode change 100755 => 100644 .github/workflows/next-changelog.yml mode change 100755 => 100644 .github/workflows/tagging.yml create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementRequest.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementResponse.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterEnforceMode.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseClusterSettings.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseEnforceResult.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcement.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcementEnforcementStatus.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationRequest.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationResponse.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieVizAttachment.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentSpec.java rename databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/{UserName.java => UserFullName.java} (83%) create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTask.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTaskOutput.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpec.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpecAcceleratorType.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeploymentSpec.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValuesAiRuntimeTaskResolvedValues.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionConfiguration.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionRunInfoDetails.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionState.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionTriggerMode.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstDistinctNFunction.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstNFunction.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastDistinctNFunction.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastNFunction.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialBranchSpec.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryConfig.java create mode 100644 databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryInferenceTableConfig.java create mode 100644 databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/SyncResourceRequest.java mode change 100755 => 100644 tagging.py diff --git a/.codegen/_openapi_sha b/.codegen/_openapi_sha old mode 100755 new mode 100644 index e68a3ddf5..205b97c58 --- a/.codegen/_openapi_sha +++ b/.codegen/_openapi_sha @@ -1 +1 @@ -951ffbf1551ea1d4347a91e1b3955298605c7526 \ No newline at end of file +654461451d03b1cac88e8b2c30f15060d27f6295 \ No newline at end of file diff --git a/.gitattributes b/.gitattributes old mode 100755 new mode 100644 index 8d685aa26..7bcd5ffe0 --- a/.gitattributes +++ b/.gitattributes @@ -867,6 +867,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/AwsAvailabi databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/AzureAttributes.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/AzureAvailability.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelCommand.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementResponse.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ChangeClusterOwner.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClientsTypes.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CloneCluster.java linguist-generated=true @@ -945,6 +947,9 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditInstanc databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditPolicy.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceResponse.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterEnforceMode.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseClusterSettings.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseEnforceResult.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/Environment.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventDetails.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventDetailsCause.java linguist-generated=true @@ -1044,6 +1049,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/MavenLibrar databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/NodeInstanceType.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/NodeType.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/NodeTypeFlexibility.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcement.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcementEnforcementStatus.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingInstanceError.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PermanentDeleteCluster.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PinCluster.java linguist-generated=true @@ -1089,6 +1096,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/Dashboar databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DashboardView.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DeleteScheduleRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DeleteSubscriptionRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationResponse.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/EvaluationStatusType.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAPI.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAttachment.java linguist-generated=true @@ -1149,6 +1158,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieSta databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieSuggestedQuestionsAttachment.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieTrashSpaceRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieUpdateSpaceRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieVizAttachment.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GetDashboardRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GetPublishedDashboardRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GetPublishedDashboardTokenInfoRequest.java linguist-generated=true @@ -1331,6 +1341,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/Create databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/DatabricksServiceExceptionWithDetailsProto.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/DefaultWorkspaceBaseEnvironment.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/DeleteWorkspaceBaseEnvironmentRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentSpec.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentsAPI.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentsImpl.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentsService.java linguist-generated=true @@ -1560,7 +1571,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/State.java li databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UpdateWorkspaceAssignmentDetailProxyRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UpdateWorkspaceAssignmentDetailRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/User.java linguist-generated=true -databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserName.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserFullName.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceAccessDetail.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceAccessDetailAccessType.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceAccessDetailView.java linguist-generated=true @@ -1569,6 +1580,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceIamV databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceIamV2Impl.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspaceIamV2Service.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/WorkspacePermission.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTask.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTaskOutput.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AlertEvaluationState.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AlertTask.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AlertTaskOutput.java linguist-generated=true @@ -1587,6 +1600,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ClusterInstanc databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ClusterSpec.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Compute.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeConfig.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpec.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpecAcceleratorType.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Condition.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ConditionTask.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ConditionTaskOp.java linguist-generated=true @@ -1608,6 +1623,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DbtPlatformTas databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DbtTask.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeleteJob.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeleteRun.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeploymentSpec.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/EnforcePolicyComplianceForJobResponseJobClusterSettingsChange.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/EnforcePolicyComplianceRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/EnforcePolicyComplianceResponse.java linguist-generated=true @@ -1704,6 +1720,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedPython databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedRunJobTaskValues.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedStringParamsValues.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValues.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValuesAiRuntimeTaskResolvedValues.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Run.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunConditionTask.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunForEachTask.java linguist-generated=true @@ -1728,6 +1745,10 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SparkSubmitTas databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SparseCheckout.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlAlertOutput.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlAlertState.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionConfiguration.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionRunInfoDetails.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionState.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionTriggerMode.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlDashboardOutput.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlDashboardWidgetOutput.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlDashboardWidgetOutputStatus.java linguist-generated=true @@ -2071,7 +2092,9 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FieldDefinition. databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FileInfo.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FinalizeLoggedModelRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FinalizeLoggedModelResponse.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstDistinctNFunction.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstFunction.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstNFunction.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FlatSchema.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/ForecastingAPI.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/ForecastingExperiment.java linguist-generated=true @@ -2125,7 +2148,9 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/KafkaConfig.java databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/KafkaSource.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/KafkaStreamConfig.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/KafkaSubscriptionMode.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastDistinctNFunction.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastFunction.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastNFunction.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LineageContext.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LinkedFeature.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/ListArtifactsRequest.java linguist-generated=true @@ -2556,6 +2581,7 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GetOperati databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GetProjectRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GetRoleRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GetSyncedTableRequest.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialBranchSpec.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialEndpointSpec.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ListBranchesRequest.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ListBranchesResponse.java linguist-generated=true @@ -2828,6 +2854,8 @@ databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndp databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointsImpl.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointsService.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingModelWorkloadType.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryConfig.java linguist-generated=true +databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryInferenceTableConfig.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TrafficConfig.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/UpdateInferenceEndpointNotifications.java linguist-generated=true databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/UpdateInferenceEndpointNotificationsResponse.java linguist-generated=true @@ -3826,6 +3854,7 @@ databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCall databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Impl.java linguist-generated=true databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Service.java linguist-generated=true databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/Resource.java linguist-generated=true +databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/SyncResourceRequest.java linguist-generated=true databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/UpdateResourceRequest.java linguist-generated=true databricks-sdk-java/src/test/java/com/databricks/sdk/service/idempotencytesting/CreateTestResourceRequest.java linguist-generated=true databricks-sdk-java/src/test/java/com/databricks/sdk/service/idempotencytesting/IdempotencyTestingAPI.java linguist-generated=true diff --git a/.github/workflows/next-changelog.yml b/.github/workflows/next-changelog.yml old mode 100755 new mode 100644 diff --git a/.github/workflows/tagging.yml b/.github/workflows/tagging.yml old mode 100755 new mode 100644 index caa826d93..d240f16ee --- a/.github/workflows/tagging.yml +++ b/.github/workflows/tagging.yml @@ -66,7 +66,7 @@ jobs: git config user.email "DECO-SDK-Tagging[bot]@users.noreply.github.com" - name: Install uv - uses: astral-sh/setup-uv@38f3f104447c67c051c4a08e39b64a148898af3a # v4.2.0 + uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0 - name: Run script env: @@ -82,7 +82,7 @@ jobs: - name: Upload created tags artifact if: always() - uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 with: name: created-tags path: created_tags.json diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index 4fd053c6c..38d505bfe 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -18,3 +18,44 @@ formats when the default JDK is older than 17 (mirroring the `make fmt` behaviour). ### API Changes +* Add `cancelPendingClusterEnforcement()` method for `workspaceClient.policyComplianceForClusters()` service. +* Add `downloadMessageAttachmentVisualization()` method for `workspaceClient.genie()` service. +* Add `bundleRootPath` field for `com.databricks.sdk.service.bundledeployments.WorkspaceInfo`. +* Add `omitPermissionsInResponse` field for `com.databricks.sdk.service.catalog.UpdatePermissions`. +* Add `pendingEnforcement` field for `com.databricks.sdk.service.compute.ClusterCompliance`. +* Add `enforceMode` field for `com.databricks.sdk.service.compute.EnforceClusterComplianceRequest`. +* Add `enforceResult` field for `com.databricks.sdk.service.compute.EnforceClusterComplianceResponse`. +* Add `pendingEnforcement` field for `com.databricks.sdk.service.compute.GetClusterComplianceResponse`. +* Add `viz` field for `com.databricks.sdk.service.dashboards.GenieAttachment`. +* Add `enableVisualization` field for `com.databricks.sdk.service.dashboards.GenieCreateConversationMessageRequest`. +* Add `enableVisualization` field for `com.databricks.sdk.service.dashboards.GenieStartConversationMessageRequest`. +* Add `excludedSchemas` field for `com.databricks.sdk.service.dataclassification.CatalogConfig`. +* Add `etag` field for `com.databricks.sdk.service.disasterrecovery.UpdateFailoverGroupRequest`. +* Add `spec` field for `com.databricks.sdk.service.environments.WorkspaceBaseEnvironment`. +* Add `fullName` field for `com.databricks.sdk.service.iamv2.User`. +* Add `sqlCondition` field for `com.databricks.sdk.service.jobs.CronSchedule`. +* Add `aiRuntimeTask` field for `com.databricks.sdk.service.jobs.ResolvedValues`. +* Add `aiRuntimeTaskOutput` field for `com.databricks.sdk.service.jobs.RunOutput`. +* Add `aiRuntimeTask` field for `com.databricks.sdk.service.jobs.RunTask`. +* Add `aiRuntimeTask` field for `com.databricks.sdk.service.jobs.SubmitTask`. +* Add `aiRuntimeTask` field for `com.databricks.sdk.service.jobs.Task`. +* Add `sqlCondition` field for `com.databricks.sdk.service.jobs.TriggerInfo`. +* Add `sqlCondition` field for `com.databricks.sdk.service.jobs.TriggerSettings`. +* Add `sqlCondition` field for `com.databricks.sdk.service.jobs.TriggerStateProto`. +* Add `firstDistinctN`, `firstN`, `lastDistinctN` and `lastN` fields for `com.databricks.sdk.service.ml.AggregationFunction`. +* Add `replaceExisting` field for `com.databricks.sdk.service.postgres.CreateDatabaseRequest`. +* Add `replaceExisting` field for `com.databricks.sdk.service.postgres.CreateRoleRequest`. +* Add `readOnlyPooledHost` and `readWritePooledHost` fields for `com.databricks.sdk.service.postgres.EndpointHosts`. +* Add `lastActiveTime` field for `com.databricks.sdk.service.postgres.EndpointStatus`. +* Add `expireTime`, `groupName` and `ttl` fields for `com.databricks.sdk.service.postgres.GenerateDatabaseCredentialRequest`. +* Add `autoscalingLimitMaxCu`, `autoscalingLimitMinCu`, `noSuspension` and `suspendTimeoutDuration` fields for `com.databricks.sdk.service.postgres.InitialEndpointSpec`. +* Add `initialBranchSpec` field for `com.databricks.sdk.service.postgres.Project`. +* Add `computeLastActiveTime` field for `com.databricks.sdk.service.postgres.ProjectStatus`. +* Add `telemetryConfig` field for `com.databricks.sdk.service.serving.CreateServingEndpoint`. +* Add `telemetryConfig` field for `com.databricks.sdk.service.serving.ServingEndpoint`. +* Add `telemetryConfig` field for `com.databricks.sdk.service.serving.ServingEndpointDetailed`. +* Add `READ_METADATA` enum value for `com.databricks.sdk.service.catalog.Privilege`. +* Add `DEFERRED_POLICY_ENFORCEMENT_SCHEDULED` and `DEFERRED_POLICY_ENFORCEMENT_FAILED` enum values for `com.databricks.sdk.service.compute.EventType`. +* Change `replicateWorkspaceAssets` field for `com.databricks.sdk.service.disasterrecovery.WorkspaceSet` to no longer be required. +* [Breaking] Change `replicateWorkspaceAssets` field for `com.databricks.sdk.service.disasterrecovery.WorkspaceSet` to no longer be required. +* [Breaking] Remove `name` field for `com.databricks.sdk.service.iamv2.User`. \ No newline at end of file diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/bundledeployments/WorkspaceInfo.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/bundledeployments/WorkspaceInfo.java index 22cf66d44..99330c6c4 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/bundledeployments/WorkspaceInfo.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/bundledeployments/WorkspaceInfo.java @@ -10,6 +10,13 @@ /** Workspace location of a bundle deployment, captured at deploy time. */ @Generated public class WorkspaceInfo { + /** + * Path of the bundle root (the directory containing databricks.yml) relative to git_folder_path. + * Empty when the deployment is not from a Databricks Git folder. + */ + @JsonProperty("bundle_root_path") + private String bundleRootPath; + /** * Absolute workspace path where the deployed bundle files live. Mirrors the workspace.file_path * field in DABs bundle config. @@ -38,6 +45,15 @@ public class WorkspaceInfo { @JsonProperty("source_linked") private Boolean sourceLinked; + public WorkspaceInfo setBundleRootPath(String bundleRootPath) { + this.bundleRootPath = bundleRootPath; + return this; + } + + public String getBundleRootPath() { + return bundleRootPath; + } + public WorkspaceInfo setFilePath(String filePath) { this.filePath = filePath; return this; @@ -79,7 +95,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; WorkspaceInfo that = (WorkspaceInfo) o; - return Objects.equals(filePath, that.filePath) + return Objects.equals(bundleRootPath, that.bundleRootPath) + && Objects.equals(filePath, that.filePath) && Objects.equals(gitFolderPath, that.gitFolderPath) && Objects.equals(rootPath, that.rootPath) && Objects.equals(sourceLinked, that.sourceLinked); @@ -87,12 +104,13 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(filePath, gitFolderPath, rootPath, sourceLinked); + return Objects.hash(bundleRootPath, filePath, gitFolderPath, rootPath, sourceLinked); } @Override public String toString() { return new ToStringer(WorkspaceInfo.class) + .add("bundleRootPath", bundleRootPath) .add("filePath", filePath) .add("gitFolderPath", gitFolderPath) .add("rootPath", rootPath) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ConnectionType.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ConnectionType.java index 77f7a4661..225c96c78 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ConnectionType.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ConnectionType.java @@ -4,7 +4,6 @@ import com.databricks.sdk.support.Generated; -/** Next Id: 127 */ @Generated public enum ConnectionType { BIGQUERY, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/CredentialType.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/CredentialType.java index c15da41ae..9a643ff4a 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/CredentialType.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/CredentialType.java @@ -4,7 +4,6 @@ import com.databricks.sdk.support.Generated; -/** Next Id: 20 */ @Generated public enum CredentialType { ANY_STATIC_CREDENTIAL, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/Privilege.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/Privilege.java index 5b76c8967..bb1f82893 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/Privilege.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/Privilege.java @@ -40,6 +40,7 @@ public enum Privilege { MODIFY, MODIFY_CLEAN_ROOM, READ_FILES, + READ_METADATA, READ_PRIVATE_FILES, READ_VOLUME, REFRESH, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SchemaInfo.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SchemaInfo.java index 8c226865e..593560059 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SchemaInfo.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SchemaInfo.java @@ -8,7 +8,6 @@ import java.util.Map; import java.util.Objects; -/** Next ID: 45 */ @Generated public class SchemaInfo { /** diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SecurableKind.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SecurableKind.java index 9df855e0a..a6a0868ab 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SecurableKind.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/SecurableKind.java @@ -4,11 +4,6 @@ import com.databricks.sdk.support.Generated; -/** - * Latest kind: CONNECTION_MARKETO_OAUTH_M2M = 347; Next id: 348. Reserved numbers: 316, 317, 327, - * 330, 341 (former ENDPOINT_LLM_*, MODEL_SERVICE_STANDARD, MODEL_SERVICE_SYSTEM_DELTASHARING, - * MCP_SERVICE_STANDARD). - */ @Generated public enum SecurableKind { TABLE_DB_STORAGE, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/UpdatePermissions.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/UpdatePermissions.java index 4f2e5568d..e1b9522a2 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/UpdatePermissions.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/UpdatePermissions.java @@ -18,6 +18,13 @@ public class UpdatePermissions { /** Full name of securable. */ @JsonIgnore private String fullName; + /** + * Optional, default false. Specifies whether all the permissions should be returned in the + * response. + */ + @JsonProperty("omit_permissions_in_response") + private Boolean omitPermissionsInResponse; + /** Type of securable. */ @JsonIgnore private String securableType; @@ -39,6 +46,15 @@ public String getFullName() { return fullName; } + public UpdatePermissions setOmitPermissionsInResponse(Boolean omitPermissionsInResponse) { + this.omitPermissionsInResponse = omitPermissionsInResponse; + return this; + } + + public Boolean getOmitPermissionsInResponse() { + return omitPermissionsInResponse; + } + public UpdatePermissions setSecurableType(String securableType) { this.securableType = securableType; return this; @@ -55,12 +71,13 @@ public boolean equals(Object o) { UpdatePermissions that = (UpdatePermissions) o; return Objects.equals(changes, that.changes) && Objects.equals(fullName, that.fullName) + && Objects.equals(omitPermissionsInResponse, that.omitPermissionsInResponse) && Objects.equals(securableType, that.securableType); } @Override public int hashCode() { - return Objects.hash(changes, fullName, securableType); + return Objects.hash(changes, fullName, omitPermissionsInResponse, securableType); } @Override @@ -68,6 +85,7 @@ public String toString() { return new ToStringer(UpdatePermissions.class) .add("changes", changes) .add("fullName", fullName) + .add("omitPermissionsInResponse", omitPermissionsInResponse) .add("securableType", securableType) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ValidateCredentialRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ValidateCredentialRequest.java index dd405f9c3..8344f2947 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ValidateCredentialRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/catalog/ValidateCredentialRequest.java @@ -7,7 +7,6 @@ import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Objects; -/** Next ID: 18 */ @Generated public class ValidateCredentialRequest { /** */ diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomAssetNotebook.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomAssetNotebook.java index c4d6211cc..d27804512 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomAssetNotebook.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomAssetNotebook.java @@ -16,7 +16,9 @@ public class CleanRoomAssetNotebook { /** * Base 64 representation of the notebook contents. This is the same format as returned by - * :method:workspace/export with the format of **HTML**. + * [workspace/export] with the format of **HTML**. + * + *

[workspace/export]: https://docs.databricks.com/api/workspace/workspace/export */ @JsonProperty("notebook_content") private String notebookContent; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsAPI.java index f33cc5551..d1a028851 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsAPI.java @@ -75,12 +75,14 @@ public CleanRoom waitGetCleanRoomActive( /** * Create a new clean room with the specified collaborators. This method is asynchronous; the * returned name field inside the clean_room field can be used to poll the clean room status, - * using the :method:cleanrooms/get method. When this method returns, the clean room will be in a + * using the [cleanrooms/get] method. When this method returns, the clean room will be in a * PROVISIONING state, with only name, owner, comment, created_at and status populated. The clean * room will be usable once it enters an ACTIVE state. * *

The caller must be a metastore admin or have the **CREATE_CLEAN_ROOM** privilege on the * metastore. + * + *

[cleanrooms/get]: https://docs.databricks.com/api/workspace/cleanrooms/get */ public Wait create(CreateCleanRoomRequest request) { CleanRoom response = impl.create(request); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsService.java index 56c3b7fb3..c945f99c1 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/cleanrooms/CleanRoomsService.java @@ -17,12 +17,14 @@ public interface CleanRoomsService { /** * Create a new clean room with the specified collaborators. This method is asynchronous; the * returned name field inside the clean_room field can be used to poll the clean room status, - * using the :method:cleanrooms/get method. When this method returns, the clean room will be in a + * using the [cleanrooms/get] method. When this method returns, the clean room will be in a * PROVISIONING state, with only name, owner, comment, created_at and status populated. The clean * room will be usable once it enters an ACTIVE state. * *

The caller must be a metastore admin or have the **CREATE_CLEAN_ROOM** privilege on the * metastore. + * + *

[cleanrooms/get]: https://docs.databricks.com/api/workspace/cleanrooms/get */ CleanRoom create(CreateCleanRoomRequest createCleanRoomRequest); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementRequest.java new file mode 100644 index 000000000..8991cd36d --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementRequest.java @@ -0,0 +1,63 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Request to cancel the pending enforcement for a cluster. */ +@Generated +public class CancelPendingClusterEnforcementRequest { + /** + * If true and no pending enforcement exists, the request will succeed but no action will be + * taken. + */ + @JsonProperty("allow_missing") + private Boolean allowMissing; + + /** The ID of the cluster to cancel the pending enforcement for. */ + @JsonProperty("cluster_id") + private String clusterId; + + public CancelPendingClusterEnforcementRequest setAllowMissing(Boolean allowMissing) { + this.allowMissing = allowMissing; + return this; + } + + public Boolean getAllowMissing() { + return allowMissing; + } + + public CancelPendingClusterEnforcementRequest setClusterId(String clusterId) { + this.clusterId = clusterId; + return this; + } + + public String getClusterId() { + return clusterId; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + CancelPendingClusterEnforcementRequest that = (CancelPendingClusterEnforcementRequest) o; + return Objects.equals(allowMissing, that.allowMissing) + && Objects.equals(clusterId, that.clusterId); + } + + @Override + public int hashCode() { + return Objects.hash(allowMissing, clusterId); + } + + @Override + public String toString() { + return new ToStringer(CancelPendingClusterEnforcementRequest.class) + .add("allowMissing", allowMissing) + .add("clusterId", clusterId) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementResponse.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementResponse.java new file mode 100644 index 000000000..b0607964a --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CancelPendingClusterEnforcementResponse.java @@ -0,0 +1,32 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import java.util.Objects; + +/** + * Response for canceling the pending enforcement for a cluster. If the cancel request succeeds, an + * empty response object is returned. Otherwise, an error response is returned. + */ +@Generated +public class CancelPendingClusterEnforcementResponse { + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + return true; + } + + @Override + public int hashCode() { + return Objects.hash(); + } + + @Override + public String toString() { + return new ToStringer(CancelPendingClusterEnforcementResponse.class).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterAttributes.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterAttributes.java index 468dabd30..d0477e1ff 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterAttributes.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterAttributes.java @@ -145,7 +145,9 @@ public class ClusterAttributes { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -203,7 +205,9 @@ public class ClusterAttributes { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterCompliance.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterCompliance.java index 35489f994..6d2fcc35d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterCompliance.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterCompliance.java @@ -18,6 +18,13 @@ public class ClusterCompliance { @JsonProperty("is_compliant") private Boolean isCompliant; + /** + * Information about the pending enforcement for the cluster. Only present if a pending + * enforcement is scheduled for the cluster. + */ + @JsonProperty("pending_enforcement") + private PendingEnforcement pendingEnforcement; + /** * An object containing key-value mappings representing the first 200 policy validation errors. * The keys indicate the path where the policy validation error is occurring. The values indicate @@ -44,6 +51,15 @@ public Boolean getIsCompliant() { return isCompliant; } + public ClusterCompliance setPendingEnforcement(PendingEnforcement pendingEnforcement) { + this.pendingEnforcement = pendingEnforcement; + return this; + } + + public PendingEnforcement getPendingEnforcement() { + return pendingEnforcement; + } + public ClusterCompliance setViolations(Map violations) { this.violations = violations; return this; @@ -60,12 +76,13 @@ public boolean equals(Object o) { ClusterCompliance that = (ClusterCompliance) o; return Objects.equals(clusterId, that.clusterId) && Objects.equals(isCompliant, that.isCompliant) + && Objects.equals(pendingEnforcement, that.pendingEnforcement) && Objects.equals(violations, that.violations); } @Override public int hashCode() { - return Objects.hash(clusterId, isCompliant, violations); + return Objects.hash(clusterId, isCompliant, pendingEnforcement, violations); } @Override @@ -73,6 +90,7 @@ public String toString() { return new ToStringer(ClusterCompliance.class) .add("clusterId", clusterId) .add("isCompliant", isCompliant) + .add("pendingEnforcement", pendingEnforcement) .add("violations", violations) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterDetails.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterDetails.java index 142f7384c..983bfa9c8 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterDetails.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterDetails.java @@ -228,7 +228,9 @@ public class ClusterDetails { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -307,7 +309,9 @@ public class ClusterDetails { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterSpec.java index 70344f42a..14f0ad817 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterSpec.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClusterSpec.java @@ -159,7 +159,9 @@ public class ClusterSpec { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -230,7 +232,9 @@ public class ClusterSpec { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateCluster.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateCluster.java index f224a7630..cdcdf4ce9 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateCluster.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateCluster.java @@ -162,7 +162,9 @@ public class CreateCluster { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -233,7 +235,9 @@ public class CreateCluster { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateInstancePool.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateInstancePool.java index 9365e599a..b46f9c56b 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateInstancePool.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/CreateInstancePool.java @@ -91,7 +91,9 @@ public class CreateInstancePool { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -103,7 +105,9 @@ public class CreateInstancePool { /** * A list containing at most one preloaded Spark image version for the pool. Pool-backed clusters * started with the preloaded Spark version will start faster. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("preloaded_spark_versions") private Collection preloadedSparkVersions; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditCluster.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditCluster.java index cbf9d6aaf..5c8763038 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditCluster.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditCluster.java @@ -159,7 +159,9 @@ public class EditCluster { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -230,7 +232,9 @@ public class EditCluster { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditInstancePool.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditInstancePool.java index b5cd70eb2..ea4d5d4e7 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditInstancePool.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EditInstancePool.java @@ -56,7 +56,9 @@ public class EditInstancePool { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceRequest.java index 82d881714..a5e6b19dc 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceRequest.java @@ -13,6 +13,21 @@ public class EnforceClusterComplianceRequest { @JsonProperty("cluster_id") private String clusterId; + /** + * Determines how changes should be made to clusters that are not in `TERMINATED` state. + * + *

- `ENFORCE_IMMEDIATELY`: If the cluster is in a `RUNNING` state, it will be restarted so + * that the new attributes can take effect. For other states aside from `TERMINATED` state, the + * request will be rejected. - `WAIT_FOR_TERMINATION`: The cluster is not immediately edited. + * Instead, a pending enforcement is scheduled to update the cluster when it terminates or + * restarts. When this occurs, `enforce_result` will contain `DEFERRED`. Only workspace admins can + * use this mode. + * + *

Regardless of the enforce mode, clusters in `TERMINATED` state are immediately edited. + */ + @JsonProperty("enforce_mode") + private EnforcePolicyComplianceForClusterEnforceMode enforceMode; + /** * If set, previews the changes that would be made to a cluster to enforce compliance but does not * update the cluster. @@ -29,6 +44,16 @@ public String getClusterId() { return clusterId; } + public EnforceClusterComplianceRequest setEnforceMode( + EnforcePolicyComplianceForClusterEnforceMode enforceMode) { + this.enforceMode = enforceMode; + return this; + } + + public EnforcePolicyComplianceForClusterEnforceMode getEnforceMode() { + return enforceMode; + } + public EnforceClusterComplianceRequest setValidateOnly(Boolean validateOnly) { this.validateOnly = validateOnly; return this; @@ -44,18 +69,20 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) return false; EnforceClusterComplianceRequest that = (EnforceClusterComplianceRequest) o; return Objects.equals(clusterId, that.clusterId) + && Objects.equals(enforceMode, that.enforceMode) && Objects.equals(validateOnly, that.validateOnly); } @Override public int hashCode() { - return Objects.hash(clusterId, validateOnly); + return Objects.hash(clusterId, enforceMode, validateOnly); } @Override public String toString() { return new ToStringer(EnforceClusterComplianceRequest.class) .add("clusterId", clusterId) + .add("enforceMode", enforceMode) .add("validateOnly", validateOnly) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceResponse.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceResponse.java index 8cc88b0c6..2804b9dab 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceResponse.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforceClusterComplianceResponse.java @@ -17,6 +17,10 @@ public class EnforceClusterComplianceResponse { @JsonProperty("changes") private Collection changes; + /** Describes whether changes have been applied to the cluster. */ + @JsonProperty("enforce_result") + private EnforcePolicyComplianceForClusterResponseEnforceResult enforceResult; + /** * Whether any changes have been made to the cluster settings for the cluster to become compliant * with its policy. @@ -33,6 +37,16 @@ public Collection getChanges() { return changes; } + public EnforceClusterComplianceResponse setEnforceResult( + EnforcePolicyComplianceForClusterResponseEnforceResult enforceResult) { + this.enforceResult = enforceResult; + return this; + } + + public EnforcePolicyComplianceForClusterResponseEnforceResult getEnforceResult() { + return enforceResult; + } + public EnforceClusterComplianceResponse setHasChanges(Boolean hasChanges) { this.hasChanges = hasChanges; return this; @@ -47,18 +61,21 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EnforceClusterComplianceResponse that = (EnforceClusterComplianceResponse) o; - return Objects.equals(changes, that.changes) && Objects.equals(hasChanges, that.hasChanges); + return Objects.equals(changes, that.changes) + && Objects.equals(enforceResult, that.enforceResult) + && Objects.equals(hasChanges, that.hasChanges); } @Override public int hashCode() { - return Objects.hash(changes, hasChanges); + return Objects.hash(changes, enforceResult, hasChanges); } @Override public String toString() { return new ToStringer(EnforceClusterComplianceResponse.class) .add("changes", changes) + .add("enforceResult", enforceResult) .add("hasChanges", hasChanges) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterEnforceMode.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterEnforceMode.java new file mode 100644 index 000000000..aab6f9efb --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterEnforceMode.java @@ -0,0 +1,11 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; + +@Generated +public enum EnforcePolicyComplianceForClusterEnforceMode { + ENFORCE_IMMEDIATELY, + WAIT_FOR_TERMINATION, +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseClusterSettings.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseClusterSettings.java new file mode 100644 index 000000000..a268b036b --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseClusterSettings.java @@ -0,0 +1,706 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Collection; +import java.util.Map; +import java.util.Objects; + +@Generated +public class EnforcePolicyComplianceForClusterResponseClusterSettings { + /** + * Parameters needed in order to automatically scale clusters up and down based on load. Note: + * autoscaling works best with DB runtime versions 3.0 or later. + */ + @JsonProperty("autoscale") + private AutoScale autoscale; + + /** + * Automatically terminates the cluster after it is inactive for this time in minutes. If not set, + * this cluster will not be automatically terminated. If specified, the threshold must be between + * 10 and 10000 minutes. Users can also set this value to 0 to explicitly disable automatic + * termination. + */ + @JsonProperty("autotermination_minutes") + private Long autoterminationMinutes; + + /** + * Attributes related to clusters running on Amazon Web Services. If not specified at cluster + * creation, a set of default values will be used. + */ + @JsonProperty("aws_attributes") + private AwsAttributes awsAttributes; + + /** + * Attributes related to clusters running on Microsoft Azure. If not specified at cluster + * creation, a set of default values will be used. + */ + @JsonProperty("azure_attributes") + private AzureAttributes azureAttributes; + + /** + * The configuration for delivering spark logs to a long-term storage destination. Three kinds of + * destinations (DBFS, S3 and Unity Catalog volumes) are supported. Only one destination can be + * specified for one cluster. If the conf is given, the logs will be delivered to the destination + * every `5 mins`. The destination of driver logs is `$destination/$clusterId/driver`, while the + * destination of executor logs is `$destination/$clusterId/executor`. + */ + @JsonProperty("cluster_log_conf") + private ClusterLogConf clusterLogConf; + + /** + * Cluster name requested by the user. This doesn't have to be unique. If not specified at + * creation, the cluster name will be an empty string. For job clusters, the cluster name is + * automatically set based on the job and job run IDs. + */ + @JsonProperty("cluster_name") + private String clusterName; + + /** + * Additional tags for cluster resources. Databricks will tag all cluster resources (e.g., AWS + * instances and EBS volumes) with these tags in addition to `default_tags`. Notes: + * + *

- Currently, Databricks allows at most 45 custom tags + * + *

- Clusters can only reuse cloud resources if the resources' tags are a subset of the cluster + * tags + */ + @JsonProperty("custom_tags") + private Map customTags; + + /** */ + @JsonProperty("data_security_mode") + private DataSecurityMode dataSecurityMode; + + /** Custom docker image BYOC */ + @JsonProperty("docker_image") + private DockerImage dockerImage; + + /** + * The optional ID of the instance pool for the driver of the cluster belongs. The pool cluster + * uses the instance pool with id (instance_pool_id) if the driver pool is not assigned. + */ + @JsonProperty("driver_instance_pool_id") + private String driverInstancePoolId; + + /** Flexible node type configuration for the driver node. */ + @JsonProperty("driver_node_type_flexibility") + private NodeTypeFlexibility driverNodeTypeFlexibility; + + /** + * The node type of the Spark driver. Note that this field is optional; if unset, the driver node + * type will be set as the same value as `node_type_id` defined above. + * + *

This field, along with node_type_id, should not be set if virtual_cluster_size is set. If + * both driver_node_type_id, node_type_id, and virtual_cluster_size are specified, + * driver_node_type_id and node_type_id take precedence. + */ + @JsonProperty("driver_node_type_id") + private String driverNodeTypeId; + + /** + * Autoscaling Local Storage: when enabled, this cluster will dynamically acquire additional disk + * space when its Spark workers are running low on disk space. + */ + @JsonProperty("enable_elastic_disk") + private Boolean enableElasticDisk; + + /** Whether to enable LUKS on cluster VMs' local disks */ + @JsonProperty("enable_local_disk_encryption") + private Boolean enableLocalDiskEncryption; + + /** + * Attributes related to clusters running on Google Cloud Platform. If not specified at cluster + * creation, a set of default values will be used. + */ + @JsonProperty("gcp_attributes") + private GcpAttributes gcpAttributes; + + /** + * The configuration for storing init scripts. Any number of destinations can be specified. The + * scripts are executed sequentially in the order provided. If `cluster_log_conf` is specified, + * init script logs are sent to `//init_scripts`. + */ + @JsonProperty("init_scripts") + private Collection initScripts; + + /** The optional ID of the instance pool to which the cluster belongs. */ + @JsonProperty("instance_pool_id") + private String instancePoolId; + + /** + * This field can only be used when `kind = CLASSIC_PREVIEW`. + * + *

When set to true, Databricks will automatically set single node related `custom_tags`, + * `spark_conf`, and `num_workers` + */ + @JsonProperty("is_single_node") + private Boolean isSingleNode; + + /** */ + @JsonProperty("kind") + private Kind kind; + + /** + * This field encodes, through a single value, the resources available to each of the Spark nodes + * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or + * compute intensive workloads. A list of available node types can be retrieved by using the + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes + */ + @JsonProperty("node_type_id") + private String nodeTypeId; + + /** + * Number of worker nodes that this cluster should have. A cluster has one Spark Driver and + * `num_workers` Executors for a total of `num_workers` + 1 Spark nodes. + * + *

Note: When reading the properties of a cluster, this field reflects the desired number of + * workers rather than the actual current number of workers. For instance, if a cluster is resized + * from 5 to 10 workers, this field will immediately be updated to reflect the target size of 10 + * workers, whereas the workers listed in `spark_info` will gradually increase from 5 to 10 as the + * new nodes are provisioned. + */ + @JsonProperty("num_workers") + private Long numWorkers; + + /** The ID of the cluster policy used to create the cluster if applicable. */ + @JsonProperty("policy_id") + private String policyId; + + /** + * If set, what the configurable throughput (in Mb/s) for the remote disk is. Currently only + * supported for GCP HYPERDISK_BALANCED disks. + */ + @JsonProperty("remote_disk_throughput") + private Long remoteDiskThroughput; + + /** + * Determines the cluster's runtime engine, either standard or Photon. + * + *

This field is not compatible with legacy `spark_version` values that contain `-photon-`. + * Remove `-photon-` from the `spark_version` and set `runtime_engine` to `PHOTON`. + * + *

If left unspecified, the runtime engine defaults to standard unless the spark_version + * contains -photon-, in which case Photon will be used. + */ + @JsonProperty("runtime_engine") + private RuntimeEngine runtimeEngine; + + /** Single user name if data_security_mode is `SINGLE_USER` */ + @JsonProperty("single_user_name") + private String singleUserName; + + /** + * An object containing a set of optional, user-specified Spark configuration key-value pairs. + * Users can also pass in a string of extra JVM options to the driver and the executors via + * `spark.driver.extraJavaOptions` and `spark.executor.extraJavaOptions` respectively. + */ + @JsonProperty("spark_conf") + private Map sparkConf; + + /** + * An object containing a set of optional, user-specified environment variable key-value pairs. + * Please note that key-value pair of the form (X,Y) will be exported as is (i.e., `export X='Y'`) + * while launching the driver and workers. + * + *

In order to specify an additional set of `SPARK_DAEMON_JAVA_OPTS`, we recommend appending + * them to `$SPARK_DAEMON_JAVA_OPTS` as shown in the example below. This ensures that all default + * databricks managed environmental variables are included as well. + * + *

Example Spark environment variables: `{"SPARK_WORKER_MEMORY": "28000m", "SPARK_LOCAL_DIRS": + * "/local_disk0"}` or `{"SPARK_DAEMON_JAVA_OPTS": "$SPARK_DAEMON_JAVA_OPTS + * -Dspark.shuffle.service.enabled=true"}` + */ + @JsonProperty("spark_env_vars") + private Map sparkEnvVars; + + /** + * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions + */ + @JsonProperty("spark_version") + private String sparkVersion; + + /** + * SSH public key contents that will be added to each Spark node in this cluster. The + * corresponding private keys can be used to login with the user name `ubuntu` on port `2200`. Up + * to 10 keys can be specified. + */ + @JsonProperty("ssh_public_keys") + private Collection sshPublicKeys; + + /** + * If set, what the total initial volume size (in GB) of the remote disks should be. Currently + * only supported for GCP HYPERDISK_BALANCED disks. + */ + @JsonProperty("total_initial_remote_disk_size") + private Long totalInitialRemoteDiskSize; + + /** + * This field can only be used when `kind = CLASSIC_PREVIEW`. + * + *

`effective_spark_version` is determined by `spark_version` (DBR release), this field + * `use_ml_runtime`, and whether `node_type_id` is gpu node or not. + */ + @JsonProperty("use_ml_runtime") + private Boolean useMlRuntime; + + /** Flexible node type configuration for worker nodes. */ + @JsonProperty("worker_node_type_flexibility") + private NodeTypeFlexibility workerNodeTypeFlexibility; + + /** */ + @JsonProperty("workload_type") + private WorkloadType workloadType; + + public EnforcePolicyComplianceForClusterResponseClusterSettings setAutoscale( + AutoScale autoscale) { + this.autoscale = autoscale; + return this; + } + + public AutoScale getAutoscale() { + return autoscale; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setAutoterminationMinutes( + Long autoterminationMinutes) { + this.autoterminationMinutes = autoterminationMinutes; + return this; + } + + public Long getAutoterminationMinutes() { + return autoterminationMinutes; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setAwsAttributes( + AwsAttributes awsAttributes) { + this.awsAttributes = awsAttributes; + return this; + } + + public AwsAttributes getAwsAttributes() { + return awsAttributes; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setAzureAttributes( + AzureAttributes azureAttributes) { + this.azureAttributes = azureAttributes; + return this; + } + + public AzureAttributes getAzureAttributes() { + return azureAttributes; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setClusterLogConf( + ClusterLogConf clusterLogConf) { + this.clusterLogConf = clusterLogConf; + return this; + } + + public ClusterLogConf getClusterLogConf() { + return clusterLogConf; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setClusterName( + String clusterName) { + this.clusterName = clusterName; + return this; + } + + public String getClusterName() { + return clusterName; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setCustomTags( + Map customTags) { + this.customTags = customTags; + return this; + } + + public Map getCustomTags() { + return customTags; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setDataSecurityMode( + DataSecurityMode dataSecurityMode) { + this.dataSecurityMode = dataSecurityMode; + return this; + } + + public DataSecurityMode getDataSecurityMode() { + return dataSecurityMode; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setDockerImage( + DockerImage dockerImage) { + this.dockerImage = dockerImage; + return this; + } + + public DockerImage getDockerImage() { + return dockerImage; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setDriverInstancePoolId( + String driverInstancePoolId) { + this.driverInstancePoolId = driverInstancePoolId; + return this; + } + + public String getDriverInstancePoolId() { + return driverInstancePoolId; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setDriverNodeTypeFlexibility( + NodeTypeFlexibility driverNodeTypeFlexibility) { + this.driverNodeTypeFlexibility = driverNodeTypeFlexibility; + return this; + } + + public NodeTypeFlexibility getDriverNodeTypeFlexibility() { + return driverNodeTypeFlexibility; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setDriverNodeTypeId( + String driverNodeTypeId) { + this.driverNodeTypeId = driverNodeTypeId; + return this; + } + + public String getDriverNodeTypeId() { + return driverNodeTypeId; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setEnableElasticDisk( + Boolean enableElasticDisk) { + this.enableElasticDisk = enableElasticDisk; + return this; + } + + public Boolean getEnableElasticDisk() { + return enableElasticDisk; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setEnableLocalDiskEncryption( + Boolean enableLocalDiskEncryption) { + this.enableLocalDiskEncryption = enableLocalDiskEncryption; + return this; + } + + public Boolean getEnableLocalDiskEncryption() { + return enableLocalDiskEncryption; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setGcpAttributes( + GcpAttributes gcpAttributes) { + this.gcpAttributes = gcpAttributes; + return this; + } + + public GcpAttributes getGcpAttributes() { + return gcpAttributes; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setInitScripts( + Collection initScripts) { + this.initScripts = initScripts; + return this; + } + + public Collection getInitScripts() { + return initScripts; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setInstancePoolId( + String instancePoolId) { + this.instancePoolId = instancePoolId; + return this; + } + + public String getInstancePoolId() { + return instancePoolId; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setIsSingleNode( + Boolean isSingleNode) { + this.isSingleNode = isSingleNode; + return this; + } + + public Boolean getIsSingleNode() { + return isSingleNode; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setKind(Kind kind) { + this.kind = kind; + return this; + } + + public Kind getKind() { + return kind; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setNodeTypeId(String nodeTypeId) { + this.nodeTypeId = nodeTypeId; + return this; + } + + public String getNodeTypeId() { + return nodeTypeId; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setNumWorkers(Long numWorkers) { + this.numWorkers = numWorkers; + return this; + } + + public Long getNumWorkers() { + return numWorkers; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setPolicyId(String policyId) { + this.policyId = policyId; + return this; + } + + public String getPolicyId() { + return policyId; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setRemoteDiskThroughput( + Long remoteDiskThroughput) { + this.remoteDiskThroughput = remoteDiskThroughput; + return this; + } + + public Long getRemoteDiskThroughput() { + return remoteDiskThroughput; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setRuntimeEngine( + RuntimeEngine runtimeEngine) { + this.runtimeEngine = runtimeEngine; + return this; + } + + public RuntimeEngine getRuntimeEngine() { + return runtimeEngine; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setSingleUserName( + String singleUserName) { + this.singleUserName = singleUserName; + return this; + } + + public String getSingleUserName() { + return singleUserName; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setSparkConf( + Map sparkConf) { + this.sparkConf = sparkConf; + return this; + } + + public Map getSparkConf() { + return sparkConf; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setSparkEnvVars( + Map sparkEnvVars) { + this.sparkEnvVars = sparkEnvVars; + return this; + } + + public Map getSparkEnvVars() { + return sparkEnvVars; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setSparkVersion( + String sparkVersion) { + this.sparkVersion = sparkVersion; + return this; + } + + public String getSparkVersion() { + return sparkVersion; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setSshPublicKeys( + Collection sshPublicKeys) { + this.sshPublicKeys = sshPublicKeys; + return this; + } + + public Collection getSshPublicKeys() { + return sshPublicKeys; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setTotalInitialRemoteDiskSize( + Long totalInitialRemoteDiskSize) { + this.totalInitialRemoteDiskSize = totalInitialRemoteDiskSize; + return this; + } + + public Long getTotalInitialRemoteDiskSize() { + return totalInitialRemoteDiskSize; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setUseMlRuntime( + Boolean useMlRuntime) { + this.useMlRuntime = useMlRuntime; + return this; + } + + public Boolean getUseMlRuntime() { + return useMlRuntime; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setWorkerNodeTypeFlexibility( + NodeTypeFlexibility workerNodeTypeFlexibility) { + this.workerNodeTypeFlexibility = workerNodeTypeFlexibility; + return this; + } + + public NodeTypeFlexibility getWorkerNodeTypeFlexibility() { + return workerNodeTypeFlexibility; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings setWorkloadType( + WorkloadType workloadType) { + this.workloadType = workloadType; + return this; + } + + public WorkloadType getWorkloadType() { + return workloadType; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + EnforcePolicyComplianceForClusterResponseClusterSettings that = + (EnforcePolicyComplianceForClusterResponseClusterSettings) o; + return Objects.equals(autoscale, that.autoscale) + && Objects.equals(autoterminationMinutes, that.autoterminationMinutes) + && Objects.equals(awsAttributes, that.awsAttributes) + && Objects.equals(azureAttributes, that.azureAttributes) + && Objects.equals(clusterLogConf, that.clusterLogConf) + && Objects.equals(clusterName, that.clusterName) + && Objects.equals(customTags, that.customTags) + && Objects.equals(dataSecurityMode, that.dataSecurityMode) + && Objects.equals(dockerImage, that.dockerImage) + && Objects.equals(driverInstancePoolId, that.driverInstancePoolId) + && Objects.equals(driverNodeTypeFlexibility, that.driverNodeTypeFlexibility) + && Objects.equals(driverNodeTypeId, that.driverNodeTypeId) + && Objects.equals(enableElasticDisk, that.enableElasticDisk) + && Objects.equals(enableLocalDiskEncryption, that.enableLocalDiskEncryption) + && Objects.equals(gcpAttributes, that.gcpAttributes) + && Objects.equals(initScripts, that.initScripts) + && Objects.equals(instancePoolId, that.instancePoolId) + && Objects.equals(isSingleNode, that.isSingleNode) + && Objects.equals(kind, that.kind) + && Objects.equals(nodeTypeId, that.nodeTypeId) + && Objects.equals(numWorkers, that.numWorkers) + && Objects.equals(policyId, that.policyId) + && Objects.equals(remoteDiskThroughput, that.remoteDiskThroughput) + && Objects.equals(runtimeEngine, that.runtimeEngine) + && Objects.equals(singleUserName, that.singleUserName) + && Objects.equals(sparkConf, that.sparkConf) + && Objects.equals(sparkEnvVars, that.sparkEnvVars) + && Objects.equals(sparkVersion, that.sparkVersion) + && Objects.equals(sshPublicKeys, that.sshPublicKeys) + && Objects.equals(totalInitialRemoteDiskSize, that.totalInitialRemoteDiskSize) + && Objects.equals(useMlRuntime, that.useMlRuntime) + && Objects.equals(workerNodeTypeFlexibility, that.workerNodeTypeFlexibility) + && Objects.equals(workloadType, that.workloadType); + } + + @Override + public int hashCode() { + return Objects.hash( + autoscale, + autoterminationMinutes, + awsAttributes, + azureAttributes, + clusterLogConf, + clusterName, + customTags, + dataSecurityMode, + dockerImage, + driverInstancePoolId, + driverNodeTypeFlexibility, + driverNodeTypeId, + enableElasticDisk, + enableLocalDiskEncryption, + gcpAttributes, + initScripts, + instancePoolId, + isSingleNode, + kind, + nodeTypeId, + numWorkers, + policyId, + remoteDiskThroughput, + runtimeEngine, + singleUserName, + sparkConf, + sparkEnvVars, + sparkVersion, + sshPublicKeys, + totalInitialRemoteDiskSize, + useMlRuntime, + workerNodeTypeFlexibility, + workloadType); + } + + @Override + public String toString() { + return new ToStringer(EnforcePolicyComplianceForClusterResponseClusterSettings.class) + .add("autoscale", autoscale) + .add("autoterminationMinutes", autoterminationMinutes) + .add("awsAttributes", awsAttributes) + .add("azureAttributes", azureAttributes) + .add("clusterLogConf", clusterLogConf) + .add("clusterName", clusterName) + .add("customTags", customTags) + .add("dataSecurityMode", dataSecurityMode) + .add("dockerImage", dockerImage) + .add("driverInstancePoolId", driverInstancePoolId) + .add("driverNodeTypeFlexibility", driverNodeTypeFlexibility) + .add("driverNodeTypeId", driverNodeTypeId) + .add("enableElasticDisk", enableElasticDisk) + .add("enableLocalDiskEncryption", enableLocalDiskEncryption) + .add("gcpAttributes", gcpAttributes) + .add("initScripts", initScripts) + .add("instancePoolId", instancePoolId) + .add("isSingleNode", isSingleNode) + .add("kind", kind) + .add("nodeTypeId", nodeTypeId) + .add("numWorkers", numWorkers) + .add("policyId", policyId) + .add("remoteDiskThroughput", remoteDiskThroughput) + .add("runtimeEngine", runtimeEngine) + .add("singleUserName", singleUserName) + .add("sparkConf", sparkConf) + .add("sparkEnvVars", sparkEnvVars) + .add("sparkVersion", sparkVersion) + .add("sshPublicKeys", sshPublicKeys) + .add("totalInitialRemoteDiskSize", totalInitialRemoteDiskSize) + .add("useMlRuntime", useMlRuntime) + .add("workerNodeTypeFlexibility", workerNodeTypeFlexibility) + .add("workloadType", workloadType) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseEnforceResult.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseEnforceResult.java new file mode 100644 index 000000000..9db711e24 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EnforcePolicyComplianceForClusterResponseEnforceResult.java @@ -0,0 +1,12 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; + +@Generated +public enum EnforcePolicyComplianceForClusterResponseEnforceResult { + APPLIED, + DEFERRED, + NO_CHANGES, +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventType.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventType.java index 1f16c75b0..2e98c400d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventType.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/EventType.java @@ -16,6 +16,8 @@ public enum EventType { DBFS_DOWN, DECOMMISSION_ENDED, DECOMMISSION_STARTED, + DEFERRED_POLICY_ENFORCEMENT_FAILED, + DEFERRED_POLICY_ENFORCEMENT_SCHEDULED, DID_NOT_EXPAND_DISK, DRIVER_HEALTHY, DRIVER_NOT_RESPONDING, diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetClusterComplianceResponse.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetClusterComplianceResponse.java index 27af99b58..99b426752 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetClusterComplianceResponse.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetClusterComplianceResponse.java @@ -17,6 +17,13 @@ public class GetClusterComplianceResponse { @JsonProperty("is_compliant") private Boolean isCompliant; + /** + * Information about the pending enforcement for the cluster. Only present if a pending + * enforcement is scheduled for the cluster. + */ + @JsonProperty("pending_enforcement") + private PendingEnforcement pendingEnforcement; + /** * An object containing key-value mappings representing the first 200 policy validation errors. * The keys indicate the path where the policy validation error is occurring. The values indicate @@ -34,6 +41,15 @@ public Boolean getIsCompliant() { return isCompliant; } + public GetClusterComplianceResponse setPendingEnforcement(PendingEnforcement pendingEnforcement) { + this.pendingEnforcement = pendingEnforcement; + return this; + } + + public PendingEnforcement getPendingEnforcement() { + return pendingEnforcement; + } + public GetClusterComplianceResponse setViolations(Map violations) { this.violations = violations; return this; @@ -49,18 +65,20 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) return false; GetClusterComplianceResponse that = (GetClusterComplianceResponse) o; return Objects.equals(isCompliant, that.isCompliant) + && Objects.equals(pendingEnforcement, that.pendingEnforcement) && Objects.equals(violations, that.violations); } @Override public int hashCode() { - return Objects.hash(isCompliant, violations); + return Objects.hash(isCompliant, pendingEnforcement, violations); } @Override public String toString() { return new ToStringer(GetClusterComplianceResponse.class) .add("isCompliant", isCompliant) + .add("pendingEnforcement", pendingEnforcement) .add("violations", violations) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetInstancePool.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetInstancePool.java index 815a259cf..34093c31d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetInstancePool.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/GetInstancePool.java @@ -109,7 +109,9 @@ public class GetInstancePool { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -121,7 +123,9 @@ public class GetInstancePool { /** * A list containing at most one preloaded Spark image version for the pool. Pool-backed clusters * started with the preloaded Spark version will start faster. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("preloaded_spark_versions") private Collection preloadedSparkVersions; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/InstancePoolAndStats.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/InstancePoolAndStats.java index ab828292d..a2d48745e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/InstancePoolAndStats.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/InstancePoolAndStats.java @@ -109,7 +109,9 @@ public class InstancePoolAndStats { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -121,7 +123,9 @@ public class InstancePoolAndStats { /** * A list containing at most one preloaded Spark image version for the pool. Pool-backed clusters * started with the preloaded Spark version will start faster. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("preloaded_spark_versions") private Collection preloadedSparkVersions; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcement.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcement.java new file mode 100644 index 000000000..7cf0f7d1b --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcement.java @@ -0,0 +1,119 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.google.protobuf.Timestamp; +import java.util.Collection; +import java.util.Objects; + +/** + * Represents a pending enforcement on a cluster, which contains the changes to make to the cluster + * configuration when the cluster is next terminated or restarted. + */ +@Generated +public class PendingEnforcement { + /** + * Whether the pending enforcement will be applied. A pending enforcement begins in `ACTIVE` + * state. If the enforcement fails to apply too many times, the state transitions to `INACTIVE`. + * Afterwards, the enforcement must be re-scheduled to become `ACTIVE` again. + */ + @JsonProperty("enforcement_status") + private PendingEnforcementEnforcementStatus enforcementStatus; + + /** The time the pending enforcement was initiated. */ + @JsonProperty("initiate_time") + private Timestamp initiateTime; + + /** The user who initiated the pending enforcement. */ + @JsonProperty("initiator_user") + private String initiatorUser; + + /** + * A list of changes that will be made to the cluster configuration when the pending enforcement + * is applied. + */ + @JsonProperty("target_changes") + private Collection targetChanges; + + /** The new configuration to apply upon cluster termination or restart. */ + @JsonProperty("target_spec") + private EnforcePolicyComplianceForClusterResponseClusterSettings targetSpec; + + public PendingEnforcement setEnforcementStatus( + PendingEnforcementEnforcementStatus enforcementStatus) { + this.enforcementStatus = enforcementStatus; + return this; + } + + public PendingEnforcementEnforcementStatus getEnforcementStatus() { + return enforcementStatus; + } + + public PendingEnforcement setInitiateTime(Timestamp initiateTime) { + this.initiateTime = initiateTime; + return this; + } + + public Timestamp getInitiateTime() { + return initiateTime; + } + + public PendingEnforcement setInitiatorUser(String initiatorUser) { + this.initiatorUser = initiatorUser; + return this; + } + + public String getInitiatorUser() { + return initiatorUser; + } + + public PendingEnforcement setTargetChanges(Collection targetChanges) { + this.targetChanges = targetChanges; + return this; + } + + public Collection getTargetChanges() { + return targetChanges; + } + + public PendingEnforcement setTargetSpec( + EnforcePolicyComplianceForClusterResponseClusterSettings targetSpec) { + this.targetSpec = targetSpec; + return this; + } + + public EnforcePolicyComplianceForClusterResponseClusterSettings getTargetSpec() { + return targetSpec; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + PendingEnforcement that = (PendingEnforcement) o; + return Objects.equals(enforcementStatus, that.enforcementStatus) + && Objects.equals(initiateTime, that.initiateTime) + && Objects.equals(initiatorUser, that.initiatorUser) + && Objects.equals(targetChanges, that.targetChanges) + && Objects.equals(targetSpec, that.targetSpec); + } + + @Override + public int hashCode() { + return Objects.hash(enforcementStatus, initiateTime, initiatorUser, targetChanges, targetSpec); + } + + @Override + public String toString() { + return new ToStringer(PendingEnforcement.class) + .add("enforcementStatus", enforcementStatus) + .add("initiateTime", initiateTime) + .add("initiatorUser", initiatorUser) + .add("targetChanges", targetChanges) + .add("targetSpec", targetSpec) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcementEnforcementStatus.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcementEnforcementStatus.java new file mode 100644 index 000000000..50deab221 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PendingEnforcementEnforcementStatus.java @@ -0,0 +1,11 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.compute; + +import com.databricks.sdk.support.Generated; + +@Generated +public enum PendingEnforcementEnforcementStatus { + ACTIVE, + INACTIVE, +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersAPI.java index 9933b1997..7e27b8c1e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersAPI.java @@ -36,15 +36,24 @@ public PolicyComplianceForClustersAPI(PolicyComplianceForClustersService mock) { } /** - * Updates a cluster to be compliant with the current version of its policy. A cluster can be - * updated if it is in a `RUNNING` or `TERMINATED` state. - * - *

If a cluster is updated while in a `RUNNING` state, it will be restarted so that the new - * attributes can take effect. + * Cancels a pending enforcement on a cluster. After canceling the pending enforcement, the + * cluster will no longer update on the next termination or restart. Pending enforcements cannot + * be canceled when a cluster is in `TERMINATING` state. Only workspace admins can cancel pending + * enforcements. + */ + public CancelPendingClusterEnforcementResponse cancelPendingClusterEnforcement( + CancelPendingClusterEnforcementRequest request) { + return impl.cancelPendingClusterEnforcement(request); + } + + /** + * Updates a cluster to be compliant with the current version of its policy. * *

If a cluster is updated while in a `TERMINATED` state, it will remain `TERMINATED`. The next * time the cluster is started, the new attributes will take effect. * + *

For clusters in other states, the behavior depends on the `enforce_mode` used. + * *

Clusters created by the Databricks Jobs, SDP, or Models services cannot be enforced by this * API. Instead, use the "Enforce job policy compliance" API to enforce policy compliance on jobs. */ diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersImpl.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersImpl.java index 451967d80..d86c100ca 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersImpl.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersImpl.java @@ -16,6 +16,25 @@ public PolicyComplianceForClustersImpl(ApiClient apiClient) { this.apiClient = apiClient; } + @Override + public CancelPendingClusterEnforcementResponse cancelPendingClusterEnforcement( + CancelPendingClusterEnforcementRequest request) { + String path = "/api/2.0/policies/clusters:cancelPendingClusterEnforcement"; + try { + Request req = new Request("POST", path, apiClient.serialize(request)); + + ApiClient.setQuery(req, request); + req.withHeader("Accept", "application/json"); + req.withHeader("Content-Type", "application/json"); + if (apiClient.workspaceId() != null) { + req.withHeader("X-Databricks-Workspace-Id", apiClient.workspaceId()); + } + return apiClient.execute(req, CancelPendingClusterEnforcementResponse.class); + } catch (IOException e) { + throw new DatabricksException("IO error: " + e.getMessage(), e); + } + } + @Override public EnforceClusterComplianceResponse enforceCompliance( EnforceClusterComplianceRequest request) { diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersService.java index cd613370b..83d5d3ddc 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/PolicyComplianceForClustersService.java @@ -22,15 +22,22 @@ @Generated public interface PolicyComplianceForClustersService { /** - * Updates a cluster to be compliant with the current version of its policy. A cluster can be - * updated if it is in a `RUNNING` or `TERMINATED` state. - * - *

If a cluster is updated while in a `RUNNING` state, it will be restarted so that the new - * attributes can take effect. + * Cancels a pending enforcement on a cluster. After canceling the pending enforcement, the + * cluster will no longer update on the next termination or restart. Pending enforcements cannot + * be canceled when a cluster is in `TERMINATING` state. Only workspace admins can cancel pending + * enforcements. + */ + CancelPendingClusterEnforcementResponse cancelPendingClusterEnforcement( + CancelPendingClusterEnforcementRequest cancelPendingClusterEnforcementRequest); + + /** + * Updates a cluster to be compliant with the current version of its policy. * *

If a cluster is updated while in a `TERMINATED` state, it will remain `TERMINATED`. The next * time the cluster is started, the new attributes will take effect. * + *

For clusters in other states, the behavior depends on the `enforce_mode` used. + * *

Clusters created by the Databricks Jobs, SDP, or Models services cannot be enforced by this * API. Instead, use the "Enforce job policy compliance" API to enforce policy compliance on jobs. */ diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/UpdateClusterResource.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/UpdateClusterResource.java index a981f6779..83f3c08e2 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/UpdateClusterResource.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/UpdateClusterResource.java @@ -148,7 +148,9 @@ public class UpdateClusterResource { * This field encodes, through a single value, the resources available to each of the Spark nodes * in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or * compute intensive workloads. A list of available node types can be retrieved by using the - * :method:clusters/listNodeTypes API call. + * [clusters/listNodeTypes] API call. + * + *

[clusters/listNodeTypes]: https://docs.databricks.com/api/workspace/clusters/listnodetypes */ @JsonProperty("node_type_id") private String nodeTypeId; @@ -219,7 +221,9 @@ public class UpdateClusterResource { /** * The Spark version of the cluster, e.g. `3.3.x-scala2.11`. A list of available Spark versions - * can be retrieved by using the :method:clusters/sparkVersions API call. + * can be retrieved by using the [clusters/sparkVersions] API call. + * + *

[clusters/sparkVersions]: https://docs.databricks.com/api/workspace/clusters/sparkversions */ @JsonProperty("spark_version") private String sparkVersion; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationRequest.java new file mode 100644 index 000000000..d93b5d93e --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationRequest.java @@ -0,0 +1,47 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.dashboards; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonIgnore; +import java.util.Objects; + +@Generated +public class DownloadMessageAttachmentVisualizationRequest { + /** + * The resource name of the attachment to render, in the format + * `spaces/{space_id}/conversations/{conversation_id}/messages/{message_id}/attachments/{attachment_id}`. + */ + @JsonIgnore private String name; + + public DownloadMessageAttachmentVisualizationRequest setName(String name) { + this.name = name; + return this; + } + + public String getName() { + return name; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + DownloadMessageAttachmentVisualizationRequest that = + (DownloadMessageAttachmentVisualizationRequest) o; + return Objects.equals(name, that.name); + } + + @Override + public int hashCode() { + return Objects.hash(name); + } + + @Override + public String toString() { + return new ToStringer(DownloadMessageAttachmentVisualizationRequest.class) + .add("name", name) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationResponse.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationResponse.java new file mode 100644 index 000000000..b279ac331 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/DownloadMessageAttachmentVisualizationResponse.java @@ -0,0 +1,45 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.dashboards; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonIgnore; +import java.io.InputStream; +import java.util.Objects; + +@Generated +public class DownloadMessageAttachmentVisualizationResponse { + /** */ + @JsonIgnore private InputStream contents; + + public DownloadMessageAttachmentVisualizationResponse setContents(InputStream contents) { + this.contents = contents; + return this; + } + + public InputStream getContents() { + return contents; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + DownloadMessageAttachmentVisualizationResponse that = + (DownloadMessageAttachmentVisualizationResponse) o; + return Objects.equals(contents, that.contents); + } + + @Override + public int hashCode() { + return Objects.hash(contents); + } + + @Override + public String toString() { + return new ToStringer(DownloadMessageAttachmentVisualizationResponse.class) + .add("contents", contents) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAPI.java index f672f229f..58e4f5379 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAPI.java @@ -143,6 +143,22 @@ public void deleteConversationMessage(GenieDeleteConversationMessageRequest requ impl.deleteConversationMessage(request); } + public DownloadMessageAttachmentVisualizationResponse downloadMessageAttachmentVisualization( + String name) { + return downloadMessageAttachmentVisualization( + new DownloadMessageAttachmentVisualizationRequest().setName(name)); + } + + /** + * Download a rendered image of a message visualization attachment. The response body is the raw + * PNG image, not a JSON payload. This is only available if the attachment is a visualization and + * the message status is `COMPLETED`. + */ + public DownloadMessageAttachmentVisualizationResponse downloadMessageAttachmentVisualization( + DownloadMessageAttachmentVisualizationRequest request) { + return impl.downloadMessageAttachmentVisualization(request); + } + /** * Execute the SQL for a message query attachment. Use this API when the query attachment has * expired and needs to be re-executed. diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAttachment.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAttachment.java index b20827178..9e568fd08 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAttachment.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieAttachment.java @@ -29,6 +29,10 @@ public class GenieAttachment { @JsonProperty("text") private TextAttachment text; + /** Visualization generated by Genie, if requested via `enable_visualization` */ + @JsonProperty("viz") + private GenieVizAttachment viz; + public GenieAttachment setAttachmentId(String attachmentId) { this.attachmentId = attachmentId; return this; @@ -66,6 +70,15 @@ public TextAttachment getText() { return text; } + public GenieAttachment setViz(GenieVizAttachment viz) { + this.viz = viz; + return this; + } + + public GenieVizAttachment getViz() { + return viz; + } + @Override public boolean equals(Object o) { if (this == o) return true; @@ -74,12 +87,13 @@ public boolean equals(Object o) { return Objects.equals(attachmentId, that.attachmentId) && Objects.equals(query, that.query) && Objects.equals(suggestedQuestions, that.suggestedQuestions) - && Objects.equals(text, that.text); + && Objects.equals(text, that.text) + && Objects.equals(viz, that.viz); } @Override public int hashCode() { - return Objects.hash(attachmentId, query, suggestedQuestions, text); + return Objects.hash(attachmentId, query, suggestedQuestions, text, viz); } @Override @@ -89,6 +103,7 @@ public String toString() { .add("query", query) .add("suggestedQuestions", suggestedQuestions) .add("text", text) + .add("viz", viz) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieCreateConversationMessageRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieCreateConversationMessageRequest.java index 0628a2e08..8ea2c4db0 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieCreateConversationMessageRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieCreateConversationMessageRequest.java @@ -17,6 +17,10 @@ public class GenieCreateConversationMessageRequest { /** The ID associated with the conversation. */ @JsonIgnore private String conversationId; + /** Enable visualization generation. */ + @JsonProperty("enable_visualization") + private Boolean enableVisualization; + /** The ID associated with the Genie space where the conversation is started. */ @JsonIgnore private String spaceId; @@ -38,6 +42,15 @@ public String getConversationId() { return conversationId; } + public GenieCreateConversationMessageRequest setEnableVisualization(Boolean enableVisualization) { + this.enableVisualization = enableVisualization; + return this; + } + + public Boolean getEnableVisualization() { + return enableVisualization; + } + public GenieCreateConversationMessageRequest setSpaceId(String spaceId) { this.spaceId = spaceId; return this; @@ -54,12 +67,13 @@ public boolean equals(Object o) { GenieCreateConversationMessageRequest that = (GenieCreateConversationMessageRequest) o; return Objects.equals(content, that.content) && Objects.equals(conversationId, that.conversationId) + && Objects.equals(enableVisualization, that.enableVisualization) && Objects.equals(spaceId, that.spaceId); } @Override public int hashCode() { - return Objects.hash(content, conversationId, spaceId); + return Objects.hash(content, conversationId, enableVisualization, spaceId); } @Override @@ -67,6 +81,7 @@ public String toString() { return new ToStringer(GenieCreateConversationMessageRequest.class) .add("content", content) .add("conversationId", conversationId) + .add("enableVisualization", enableVisualization) .add("spaceId", spaceId) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieImpl.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieImpl.java index 97d1849ed..e57ab4e44 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieImpl.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieImpl.java @@ -116,6 +116,24 @@ public void deleteConversationMessage(GenieDeleteConversationMessageRequest requ } } + @Override + public DownloadMessageAttachmentVisualizationResponse downloadMessageAttachmentVisualization( + DownloadMessageAttachmentVisualizationRequest request) { + String path = String.format("/api/2.0/genie/%s/download-visualization", request.getName()); + try { + Request req = new Request("GET", path); + + ApiClient.setQuery(req, request); + req.withHeader("Accept", "application/octet-stream"); + if (apiClient.workspaceId() != null) { + req.withHeader("X-Databricks-Workspace-Id", apiClient.workspaceId()); + } + return apiClient.execute(req, DownloadMessageAttachmentVisualizationResponse.class); + } catch (IOException e) { + throw new DatabricksException("IO error: " + e.getMessage(), e); + } + } + @Override public GenieGetMessageQueryResultResponse executeMessageAttachmentQuery( GenieExecuteMessageAttachmentQueryRequest request) { diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieService.java index 262956231..e7ccd1dde 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieService.java @@ -36,6 +36,14 @@ GenieMessageComment createMessageComment( void deleteConversationMessage( GenieDeleteConversationMessageRequest genieDeleteConversationMessageRequest); + /** + * Download a rendered image of a message visualization attachment. The response body is the raw + * PNG image, not a JSON payload. This is only available if the attachment is a visualization and + * the message status is `COMPLETED`. + */ + DownloadMessageAttachmentVisualizationResponse downloadMessageAttachmentVisualization( + DownloadMessageAttachmentVisualizationRequest downloadMessageAttachmentVisualizationRequest); + /** * Execute the SQL for a message query attachment. Use this API when the query attachment has * expired and needs to be re-executed. diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieStartConversationMessageRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieStartConversationMessageRequest.java index 1d4df5b07..ef2056241 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieStartConversationMessageRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieStartConversationMessageRequest.java @@ -14,6 +14,10 @@ public class GenieStartConversationMessageRequest { @JsonProperty("content") private String content; + /** Enable visualization generation. */ + @JsonProperty("enable_visualization") + private Boolean enableVisualization; + /** The ID associated with the Genie space where you want to start a conversation. */ @JsonIgnore private String spaceId; @@ -26,6 +30,15 @@ public String getContent() { return content; } + public GenieStartConversationMessageRequest setEnableVisualization(Boolean enableVisualization) { + this.enableVisualization = enableVisualization; + return this; + } + + public Boolean getEnableVisualization() { + return enableVisualization; + } + public GenieStartConversationMessageRequest setSpaceId(String spaceId) { this.spaceId = spaceId; return this; @@ -40,18 +53,21 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; GenieStartConversationMessageRequest that = (GenieStartConversationMessageRequest) o; - return Objects.equals(content, that.content) && Objects.equals(spaceId, that.spaceId); + return Objects.equals(content, that.content) + && Objects.equals(enableVisualization, that.enableVisualization) + && Objects.equals(spaceId, that.spaceId); } @Override public int hashCode() { - return Objects.hash(content, spaceId); + return Objects.hash(content, enableVisualization, spaceId); } @Override public String toString() { return new ToStringer(GenieStartConversationMessageRequest.class) .add("content", content) + .add("enableVisualization", enableVisualization) .add("spaceId", spaceId) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieVizAttachment.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieVizAttachment.java new file mode 100644 index 000000000..07224de66 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/GenieVizAttachment.java @@ -0,0 +1,63 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.dashboards; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** + * Visualization generated by Genie for a query result. Use the attachment ID with the download + * visualization API to retrieve the rendered image. + */ +@Generated +public class GenieVizAttachment { + /** The ID of the query attachment the visualization was generated from */ + @JsonProperty("query_attachment_id") + private String queryAttachmentId; + + /** Name of the visualization */ + @JsonProperty("title") + private String title; + + public GenieVizAttachment setQueryAttachmentId(String queryAttachmentId) { + this.queryAttachmentId = queryAttachmentId; + return this; + } + + public String getQueryAttachmentId() { + return queryAttachmentId; + } + + public GenieVizAttachment setTitle(String title) { + this.title = title; + return this; + } + + public String getTitle() { + return title; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + GenieVizAttachment that = (GenieVizAttachment) o; + return Objects.equals(queryAttachmentId, that.queryAttachmentId) + && Objects.equals(title, that.title); + } + + @Override + public int hashCode() { + return Objects.hash(queryAttachmentId, title); + } + + @Override + public String toString() { + return new ToStringer(GenieVizAttachment.class) + .add("queryAttachmentId", queryAttachmentId) + .add("title", title) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/ListDashboardsRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/ListDashboardsRequest.java index 27e018055..4324f9c5c 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/ListDashboardsRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dashboards/ListDashboardsRequest.java @@ -31,7 +31,7 @@ public class ListDashboardsRequest { @QueryParam("show_trashed") private Boolean showTrashed; - /** `DASHBOARD_VIEW_BASIC`only includes summary metadata from the dashboard. */ + /** `DASHBOARD_VIEW_BASIC` only includes summary metadata from the dashboard. */ @JsonIgnore @QueryParam("view") private DashboardView view; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfig.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfig.java index d36081ec8..ab62c2dcd 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfig.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfig.java @@ -24,8 +24,19 @@ public class CatalogConfig { private Collection autoTagConfigs; /** - * Schemas to include in the scan. Empty list is not supported as it results in a no-op scan. If - * `included_schemas` is not set, all schemas are scanned. + * Schemas to exclude from the scan, each named relative to the parent catalog. If specified, all + * schemas except the specified ones will be scanned. Mutually exclusive with `included_schemas`: + * only one may be set per request. If neither `included_schemas` nor `excluded_schemas` is set, + * all schemas are scanned. + */ + @JsonProperty("excluded_schemas") + private CatalogConfigSchemaNames excludedSchemas; + + /** + * Schemas to include in the scan, each named relative to the parent catalog. If specified, only + * listed schemas will be scanned. Mutually exclusive with `excluded_schemas`: only one may be set + * per request. If neither `included_schemas` nor `excluded_schemas` is set, all schemas are + * scanned. */ @JsonProperty("included_schemas") private CatalogConfigSchemaNames includedSchemas; @@ -43,6 +54,15 @@ public Collection getAutoTagConfigs() { return autoTagConfigs; } + public CatalogConfig setExcludedSchemas(CatalogConfigSchemaNames excludedSchemas) { + this.excludedSchemas = excludedSchemas; + return this; + } + + public CatalogConfigSchemaNames getExcludedSchemas() { + return excludedSchemas; + } + public CatalogConfig setIncludedSchemas(CatalogConfigSchemaNames includedSchemas) { this.includedSchemas = includedSchemas; return this; @@ -67,19 +87,21 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) return false; CatalogConfig that = (CatalogConfig) o; return Objects.equals(autoTagConfigs, that.autoTagConfigs) + && Objects.equals(excludedSchemas, that.excludedSchemas) && Objects.equals(includedSchemas, that.includedSchemas) && Objects.equals(name, that.name); } @Override public int hashCode() { - return Objects.hash(autoTagConfigs, includedSchemas, name); + return Objects.hash(autoTagConfigs, excludedSchemas, includedSchemas, name); } @Override public String toString() { return new ToStringer(CatalogConfig.class) .add("autoTagConfigs", autoTagConfigs) + .add("excludedSchemas", excludedSchemas) .add("includedSchemas", includedSchemas) .add("name", name) .toString(); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfigSchemaNames.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfigSchemaNames.java index a2901aada..11f34ede8 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfigSchemaNames.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataclassification/CatalogConfigSchemaNames.java @@ -11,7 +11,7 @@ /** Wrapper message for a list of schema names. */ @Generated public class CatalogConfigSchemaNames { - /** */ + /** Schema names, each relative to the parent catalog. Must not be empty. */ @JsonProperty("names") private Collection names; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/CreateRefreshRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/CreateRefreshRequest.java index a907fea44..d0e000ffa 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/CreateRefreshRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/CreateRefreshRequest.java @@ -25,7 +25,7 @@ public class CreateRefreshRequest { */ @JsonIgnore private String objectId; - /** The type of the monitored object. Can be one of the following: `schema`or `table`. */ + /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ @JsonIgnore private String objectType; /** The refresh to create */ diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/Refresh.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/Refresh.java index e5d1e7659..3498838d8 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/Refresh.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/dataquality/Refresh.java @@ -37,7 +37,7 @@ public class Refresh { @JsonProperty("object_id") private String objectId; - /** The type of the monitored object. Can be one of the following: `schema`or `table`. */ + /** The type of the monitored object. Can be one of the following: `schema` or `table`. */ @JsonProperty("object_type") private String objectType; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/FailoverGroup.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/FailoverGroup.java index fa6fc2a87..e50c051e1 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/FailoverGroup.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/FailoverGroup.java @@ -26,10 +26,7 @@ public class FailoverGroup { @JsonProperty("effective_primary_region") private String effectivePrimaryRegion; - /** - * Opaque version string for optimistic locking. Server-generated, returned in responses. Must be - * provided on Update requests to prevent concurrent modifications. - */ + /** Opaque version string for optimistic locking. Server-generated and returned in responses. */ @JsonProperty("etag") private String etag; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/StableUrl.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/StableUrl.java index 3e6b30ea1..c128cb2b7 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/StableUrl.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/StableUrl.java @@ -34,7 +34,7 @@ public class StableUrl { /** * The stable URL endpoint. Generated on creation and immutable thereafter. For non-Private-Link - * workspaces this is `https:///?c=`. For Private-Link workspaces this + * workspaces this is `https:///?w=`. For Private-Link workspaces this * is the per-connection hostname. */ @JsonProperty("url") diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/UpdateFailoverGroupRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/UpdateFailoverGroupRequest.java index 777ad584b..dea3350e6 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/UpdateFailoverGroupRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/UpdateFailoverGroupRequest.java @@ -12,6 +12,15 @@ @Generated public class UpdateFailoverGroupRequest { + /** + * Optional opaque version string for optimistic locking, obtained from a prior read of the + * failover group. If provided, the update is rejected unless it matches the failover group's + * current etag. If omitted, the update proceeds without an optimistic-lock check. + */ + @JsonIgnore + @QueryParam("etag") + private String etag; + /** * The failover group with updated fields. The name field identifies the resource and is populated * from the URL path. @@ -30,6 +39,15 @@ public class UpdateFailoverGroupRequest { @QueryParam("update_mask") private FieldMask updateMask; + public UpdateFailoverGroupRequest setEtag(String etag) { + this.etag = etag; + return this; + } + + public String getEtag() { + return etag; + } + public UpdateFailoverGroupRequest setFailoverGroup(FailoverGroup failoverGroup) { this.failoverGroup = failoverGroup; return this; @@ -62,19 +80,21 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; UpdateFailoverGroupRequest that = (UpdateFailoverGroupRequest) o; - return Objects.equals(failoverGroup, that.failoverGroup) + return Objects.equals(etag, that.etag) + && Objects.equals(failoverGroup, that.failoverGroup) && Objects.equals(name, that.name) && Objects.equals(updateMask, that.updateMask); } @Override public int hashCode() { - return Objects.hash(failoverGroup, name, updateMask); + return Objects.hash(etag, failoverGroup, name, updateMask); } @Override public String toString() { return new ToStringer(UpdateFailoverGroupRequest.class) + .add("etag", etag) .add("failoverGroup", failoverGroup) .add("name", name) .add("updateMask", updateMask) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/WorkspaceSet.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/WorkspaceSet.java index 32e7bd999..73ff75dcf 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/WorkspaceSet.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/disasterrecovery/WorkspaceSet.java @@ -15,7 +15,10 @@ public class WorkspaceSet { @JsonProperty("name") private String name; - /** Whether to enable control plane DR (notebooks, jobs, clusters, etc.) for this set. */ + /** + * Whether to enable control plane DR (notebooks, jobs, clusters, etc.) for this set. Defaults to + * false. + */ @JsonProperty("replicate_workspace_assets") private Boolean replicateWorkspaceAssets; diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentSpec.java new file mode 100644 index 000000000..65b76628a --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/EnvironmentSpec.java @@ -0,0 +1,73 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.environments; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Collection; +import java.util.Objects; + +/** + * Environment specification for a WorkspaceBaseEnvironment. Contains the environment version and + * dependencies configuration. + */ +@Generated +public class EnvironmentSpec { + /** + * List of pip dependencies, as supported by the version of pip in this environment. Each + * dependency is a valid pip requirements file line per + * https://pip.pypa.io/en/stable/reference/requirements-file-format/. Allowed dependencies include + * a requirement specifier, an archive URL, a local project path (such as WSFS or UC Volumes in + * Databricks), or a VCS project URL. + */ + @JsonProperty("dependencies") + private Collection dependencies; + + /** + * Environment version used by the environment. Each version comes with a specific Python version + * and a set of Python packages. The version is a string, consisting of an integer. + */ + @JsonProperty("environment_version") + private String environmentVersion; + + public EnvironmentSpec setDependencies(Collection dependencies) { + this.dependencies = dependencies; + return this; + } + + public Collection getDependencies() { + return dependencies; + } + + public EnvironmentSpec setEnvironmentVersion(String environmentVersion) { + this.environmentVersion = environmentVersion; + return this; + } + + public String getEnvironmentVersion() { + return environmentVersion; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + EnvironmentSpec that = (EnvironmentSpec) o; + return Objects.equals(dependencies, that.dependencies) + && Objects.equals(environmentVersion, that.environmentVersion); + } + + @Override + public int hashCode() { + return Objects.hash(dependencies, environmentVersion); + } + + @Override + public String toString() { + return new ToStringer(EnvironmentSpec.class) + .add("dependencies", dependencies) + .add("environmentVersion", environmentVersion) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/WorkspaceBaseEnvironment.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/WorkspaceBaseEnvironment.java index 7c21fccb6..211926f25 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/WorkspaceBaseEnvironment.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/environments/WorkspaceBaseEnvironment.java @@ -53,6 +53,10 @@ public class WorkspaceBaseEnvironment { @JsonProperty("name") private String name; + /** The environment specification containing version and dependencies. */ + @JsonProperty("spec") + private EnvironmentSpec spec; + /** The status of the materialized workspace base environment. */ @JsonProperty("status") private WorkspaceBaseEnvironmentCacheStatus status; @@ -142,6 +146,15 @@ public String getName() { return name; } + public WorkspaceBaseEnvironment setSpec(EnvironmentSpec spec) { + this.spec = spec; + return this; + } + + public EnvironmentSpec getSpec() { + return spec; + } + public WorkspaceBaseEnvironment setStatus(WorkspaceBaseEnvironmentCacheStatus status) { this.status = status; return this; @@ -174,6 +187,7 @@ public boolean equals(Object o) { && Objects.equals(lastUpdatedUserId, that.lastUpdatedUserId) && Objects.equals(message, that.message) && Objects.equals(name, that.name) + && Objects.equals(spec, that.spec) && Objects.equals(status, that.status) && Objects.equals(updateTime, that.updateTime); } @@ -190,6 +204,7 @@ public int hashCode() { lastUpdatedUserId, message, name, + spec, status, updateTime); } @@ -206,6 +221,7 @@ public String toString() { .add("lastUpdatedUserId", lastUpdatedUserId) .add("message", message) .add("name", name) + .add("spec", spec) .add("status", status) .add("updateTime", updateTime) .toString(); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/User.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/User.java index 5f5c699d9..f33c8ab39 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/User.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/User.java @@ -22,14 +22,14 @@ public class User { @JsonProperty("external_id") private String externalId; + /** */ + @JsonProperty("full_name") + private UserFullName fullName; + /** Internal userId of the user in Databricks. */ @JsonProperty("internal_id") private Long internalId; - /** */ - @JsonProperty("name") - private UserName name; - /** Username/email of the user. */ @JsonProperty("username") private String username; @@ -61,22 +61,22 @@ public String getExternalId() { return externalId; } - public User setInternalId(Long internalId) { - this.internalId = internalId; + public User setFullName(UserFullName fullName) { + this.fullName = fullName; return this; } - public Long getInternalId() { - return internalId; + public UserFullName getFullName() { + return fullName; } - public User setName(UserName name) { - this.name = name; + public User setInternalId(Long internalId) { + this.internalId = internalId; return this; } - public UserName getName() { - return name; + public Long getInternalId() { + return internalId; } public User setUsername(String username) { @@ -96,14 +96,14 @@ public boolean equals(Object o) { return Objects.equals(accountId, that.accountId) && Objects.equals(accountUserStatus, that.accountUserStatus) && Objects.equals(externalId, that.externalId) + && Objects.equals(fullName, that.fullName) && Objects.equals(internalId, that.internalId) - && Objects.equals(name, that.name) && Objects.equals(username, that.username); } @Override public int hashCode() { - return Objects.hash(accountId, accountUserStatus, externalId, internalId, name, username); + return Objects.hash(accountId, accountUserStatus, externalId, fullName, internalId, username); } @Override @@ -112,8 +112,8 @@ public String toString() { .add("accountId", accountId) .add("accountUserStatus", accountUserStatus) .add("externalId", externalId) + .add("fullName", fullName) .add("internalId", internalId) - .add("name", name) .add("username", username) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserName.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserFullName.java similarity index 83% rename from databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserName.java rename to databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserFullName.java index 5a69df404..225c61a21 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserName.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/iamv2/UserFullName.java @@ -8,7 +8,7 @@ import java.util.Objects; @Generated -public class UserName { +public class UserFullName { /** */ @JsonProperty("family_name") private String familyName; @@ -17,7 +17,7 @@ public class UserName { @JsonProperty("given_name") private String givenName; - public UserName setFamilyName(String familyName) { + public UserFullName setFamilyName(String familyName) { this.familyName = familyName; return this; } @@ -26,7 +26,7 @@ public String getFamilyName() { return familyName; } - public UserName setGivenName(String givenName) { + public UserFullName setGivenName(String givenName) { this.givenName = givenName; return this; } @@ -39,7 +39,7 @@ public String getGivenName() { public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; - UserName that = (UserName) o; + UserFullName that = (UserFullName) o; return Objects.equals(familyName, that.familyName) && Objects.equals(givenName, that.givenName); } @@ -50,7 +50,7 @@ public int hashCode() { @Override public String toString() { - return new ToStringer(UserName.class) + return new ToStringer(UserFullName.class) .add("familyName", familyName) .add("givenName", givenName) .toString(); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTask.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTask.java new file mode 100644 index 000000000..b7b916498 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTask.java @@ -0,0 +1,138 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Collection; +import java.util.Objects; + +/** + * AiRuntimeTask: multi-node GPU compute task definition for Databricks AI Runtime workloads. + * + *

Jobs-framework-level concepts (retries, per-task timeout, idempotency token, usage/budget + * policy, permissions) live on the surrounding TaskSettings / run-submit request and are + * intentionally NOT duplicated here. Users compose `ai_runtime_task` with the standard Jobs/DABs + * task wrapper to get those. + */ +@Generated +public class AiRuntimeTask { + /** + * Optional workspace or UC volume path of the uploaded code-source archive. The CLI packages the + * user's local code directory into an archive and populates this. Customers calling the Jobs API + * directly should upload their archive to the workspace or a UC volume first and supply the + * resulting path here. + * + *

When set, the training node exposes the value via the `$CODE_SOURCE` environment variable. + */ + @JsonProperty("code_source_path") + private String codeSourcePath; + + /** + * Deployment specs for this task. Exactly one deployment is currently supported (a single entry + * where every node runs the same command); this is a current-Preview constraint. Role-split + * workloads (driver + worker, parameter server, separate eval node, etc.) with multiple entries + * are the eventual intent but not yet supported. + */ + @JsonProperty("deployments") + private Collection deployments; + + /** + * MLflow experiment name for this run. If an experiment with this name already exists under the + * calling user, the run is appended to it; otherwise a new experiment is created. To target a + * specific MLflow storage location (for example, when running as a service principal), set + * `mlflow_experiment_directory`. + */ + @JsonProperty("experiment") + private String experiment; + + /** + * Optional workspace directory under which the MLflow experiment named in `experiment` is + * created. Must start with `/Workspace`. Set this when running as a service principal that has no + * default user directory; for regular users the experiment defaults to the user's home directory. + */ + @JsonProperty("mlflow_experiment_directory") + private String mlflowExperimentDirectory; + + /** + * Optional display name for the MLflow run created under `experiment`. If omitted, MLflow + * generates a default name. + */ + @JsonProperty("mlflow_run") + private String mlflowRun; + + public AiRuntimeTask setCodeSourcePath(String codeSourcePath) { + this.codeSourcePath = codeSourcePath; + return this; + } + + public String getCodeSourcePath() { + return codeSourcePath; + } + + public AiRuntimeTask setDeployments(Collection deployments) { + this.deployments = deployments; + return this; + } + + public Collection getDeployments() { + return deployments; + } + + public AiRuntimeTask setExperiment(String experiment) { + this.experiment = experiment; + return this; + } + + public String getExperiment() { + return experiment; + } + + public AiRuntimeTask setMlflowExperimentDirectory(String mlflowExperimentDirectory) { + this.mlflowExperimentDirectory = mlflowExperimentDirectory; + return this; + } + + public String getMlflowExperimentDirectory() { + return mlflowExperimentDirectory; + } + + public AiRuntimeTask setMlflowRun(String mlflowRun) { + this.mlflowRun = mlflowRun; + return this; + } + + public String getMlflowRun() { + return mlflowRun; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + AiRuntimeTask that = (AiRuntimeTask) o; + return Objects.equals(codeSourcePath, that.codeSourcePath) + && Objects.equals(deployments, that.deployments) + && Objects.equals(experiment, that.experiment) + && Objects.equals(mlflowExperimentDirectory, that.mlflowExperimentDirectory) + && Objects.equals(mlflowRun, that.mlflowRun); + } + + @Override + public int hashCode() { + return Objects.hash( + codeSourcePath, deployments, experiment, mlflowExperimentDirectory, mlflowRun); + } + + @Override + public String toString() { + return new ToStringer(AiRuntimeTask.class) + .add("codeSourcePath", codeSourcePath) + .add("deployments", deployments) + .add("experiment", experiment) + .add("mlflowExperimentDirectory", mlflowExperimentDirectory) + .add("mlflowRun", mlflowRun) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTaskOutput.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTaskOutput.java new file mode 100644 index 000000000..95a778c4b --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/AiRuntimeTaskOutput.java @@ -0,0 +1,91 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** + * AiRuntimeTaskOutput: output identifiers for an AiRuntimeTask run — the MLflow experiment and run + * IDs the task wrote to. + * + *

Run lifecycle and termination status are not on this message; they live on the surrounding + * `RunTask.status` field (see `runs.proto:RunTask.status`). + */ +@Generated +public class AiRuntimeTaskOutput { + /** + * MLflow experiment ID the run was logged to. Use it to look up the experiment in MLflow APIs or + * the workspace MLflow UI. + */ + @JsonProperty("mlflow_experiment_id") + private String mlflowExperimentId; + + /** + * MLflow run ID for this task execution. Use it to look up the run in MLflow APIs or the + * workspace MLflow UI. + */ + @JsonProperty("mlflow_run_id") + private String mlflowRunId; + + /** + * Human-readable status message for this run, suitable for display to the user (for example, that + * the run is still waiting for GPU compute). Set by the server only when there is something to + * surface; empty otherwise. + */ + @JsonProperty("status_message") + private String statusMessage; + + public AiRuntimeTaskOutput setMlflowExperimentId(String mlflowExperimentId) { + this.mlflowExperimentId = mlflowExperimentId; + return this; + } + + public String getMlflowExperimentId() { + return mlflowExperimentId; + } + + public AiRuntimeTaskOutput setMlflowRunId(String mlflowRunId) { + this.mlflowRunId = mlflowRunId; + return this; + } + + public String getMlflowRunId() { + return mlflowRunId; + } + + public AiRuntimeTaskOutput setStatusMessage(String statusMessage) { + this.statusMessage = statusMessage; + return this; + } + + public String getStatusMessage() { + return statusMessage; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + AiRuntimeTaskOutput that = (AiRuntimeTaskOutput) o; + return Objects.equals(mlflowExperimentId, that.mlflowExperimentId) + && Objects.equals(mlflowRunId, that.mlflowRunId) + && Objects.equals(statusMessage, that.statusMessage); + } + + @Override + public int hashCode() { + return Objects.hash(mlflowExperimentId, mlflowRunId, statusMessage); + } + + @Override + public String toString() { + return new ToStringer(AiRuntimeTaskOutput.class) + .add("mlflowExperimentId", mlflowExperimentId) + .add("mlflowRunId", mlflowRunId) + .add("statusMessage", statusMessage) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpec.java new file mode 100644 index 000000000..ce50fddaa --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpec.java @@ -0,0 +1,70 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** + * ComputeSpec: compute configuration — accelerator type and total accelerator count across all + * nodes. + */ +@Generated +public class ComputeSpec { + /** + * Total number of accelerators across all nodes. Must be a positive multiple of the per-node + * accelerator count encoded in `accelerator_type`. For example, `GPU_8xH100` with + * `accelerator_count: 16` allocates 2 nodes (8 GPUs per node). + */ + @JsonProperty("accelerator_count") + private Long acceleratorCount; + + /** + * Hardware accelerator type (for example, `GPU_1xA10` or `GPU_8xH100`). The number of + * accelerators per node is encoded in the enum value — `GPU_8xH100` means 8 H100 GPUs per node. + */ + @JsonProperty("accelerator_type") + private ComputeSpecAcceleratorType acceleratorType; + + public ComputeSpec setAcceleratorCount(Long acceleratorCount) { + this.acceleratorCount = acceleratorCount; + return this; + } + + public Long getAcceleratorCount() { + return acceleratorCount; + } + + public ComputeSpec setAcceleratorType(ComputeSpecAcceleratorType acceleratorType) { + this.acceleratorType = acceleratorType; + return this; + } + + public ComputeSpecAcceleratorType getAcceleratorType() { + return acceleratorType; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + ComputeSpec that = (ComputeSpec) o; + return Objects.equals(acceleratorCount, that.acceleratorCount) + && Objects.equals(acceleratorType, that.acceleratorType); + } + + @Override + public int hashCode() { + return Objects.hash(acceleratorCount, acceleratorType); + } + + @Override + public String toString() { + return new ToStringer(ComputeSpec.class) + .add("acceleratorCount", acceleratorCount) + .add("acceleratorType", acceleratorType) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpecAcceleratorType.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpecAcceleratorType.java new file mode 100644 index 000000000..8687116a5 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ComputeSpecAcceleratorType.java @@ -0,0 +1,22 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Customer-facing AcceleratorType: hardware accelerator type for the AiRuntime workload. Per-node + * accelerator count is encoded in the value name (e.g. `GPU_8xH100` means 8 H100s per node). + */ +@Generated +public enum ComputeSpecAcceleratorType { + @JsonProperty("GPU_1xA10") + GPU_1X_A10, + + @JsonProperty("GPU_1xH100") + GPU_1X_H100, + + @JsonProperty("GPU_8xH100") + GPU_8X_H100, +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/CronSchedule.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/CronSchedule.java index 6cbe5d60a..fa3c22e74 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/CronSchedule.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/CronSchedule.java @@ -23,6 +23,14 @@ public class CronSchedule { @JsonProperty("quartz_cron_expression") private String quartzCronExpression; + /** + * SQL condition that must be satisfied before a scheduled run is triggered. The condition is + * evaluated after the cron expression fires and must return a truthy result for the run to + * proceed. + */ + @JsonProperty("sql_condition") + private SqlConditionConfiguration sqlCondition; + /** * A Java timezone ID. The schedule for a job is resolved with respect to this timezone. See [Java * TimeZone] for details. This field is required. @@ -50,6 +58,15 @@ public String getQuartzCronExpression() { return quartzCronExpression; } + public CronSchedule setSqlCondition(SqlConditionConfiguration sqlCondition) { + this.sqlCondition = sqlCondition; + return this; + } + + public SqlConditionConfiguration getSqlCondition() { + return sqlCondition; + } + public CronSchedule setTimezoneId(String timezoneId) { this.timezoneId = timezoneId; return this; @@ -66,12 +83,13 @@ public boolean equals(Object o) { CronSchedule that = (CronSchedule) o; return Objects.equals(pauseStatus, that.pauseStatus) && Objects.equals(quartzCronExpression, that.quartzCronExpression) + && Objects.equals(sqlCondition, that.sqlCondition) && Objects.equals(timezoneId, that.timezoneId); } @Override public int hashCode() { - return Objects.hash(pauseStatus, quartzCronExpression, timezoneId); + return Objects.hash(pauseStatus, quartzCronExpression, sqlCondition, timezoneId); } @Override @@ -79,6 +97,7 @@ public String toString() { return new ToStringer(CronSchedule.class) .add("pauseStatus", pauseStatus) .add("quartzCronExpression", quartzCronExpression) + .add("sqlCondition", sqlCondition) .add("timezoneId", timezoneId) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeploymentSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeploymentSpec.java new file mode 100644 index 000000000..cd64998f7 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/DeploymentSpec.java @@ -0,0 +1,89 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** + * DeploymentSpec: configuration for one deployment within an AiRuntimeTask. Each entry in + * `AiRuntimeTask.deployments` describes a group of nodes that share the same command and compute. + * Many single-program training algorithms use a single entry where every node runs the same + * command; role-split workloads (driver + worker, parameter server, separate eval node, etc.) use + * multiple entries. + */ +@Generated +public class DeploymentSpec { + /** + * Workspace path of the bash script to execute on each node in this deployment. The CLI uploads + * the user's script and populates this. Customers calling the Jobs API directly should upload + * their script to the workspace first and supply the resulting path here. + */ + @JsonProperty("command_path") + private String commandPath; + + /** Compute resources allocated to each node in this deployment. */ + @JsonProperty("compute") + private ComputeSpec compute; + + /** + * Optional human-readable name for this deployment (for example, `driver`, `worker`, + * `param_server`). Used for log and UI display. Distinct names are recommended so deployments can + * be told apart, but uniqueness is not enforced. + */ + @JsonProperty("name") + private String name; + + public DeploymentSpec setCommandPath(String commandPath) { + this.commandPath = commandPath; + return this; + } + + public String getCommandPath() { + return commandPath; + } + + public DeploymentSpec setCompute(ComputeSpec compute) { + this.compute = compute; + return this; + } + + public ComputeSpec getCompute() { + return compute; + } + + public DeploymentSpec setName(String name) { + this.name = name; + return this; + } + + public String getName() { + return name; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + DeploymentSpec that = (DeploymentSpec) o; + return Objects.equals(commandPath, that.commandPath) + && Objects.equals(compute, that.compute) + && Objects.equals(name, that.name); + } + + @Override + public int hashCode() { + return Objects.hash(commandPath, compute, name); + } + + @Override + public String toString() { + return new ToStringer(DeploymentSpec.class) + .add("commandPath", commandPath) + .add("compute", compute) + .add("name", name) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValues.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValues.java index 66ad847eb..a9b800513 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValues.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValues.java @@ -9,6 +9,13 @@ @Generated public class ResolvedValues { + /** + * Resolved values for an AI Runtime task — env_vars with `{{tasks..values.}}` + * references substituted to concrete values before submission to the training service. + */ + @JsonProperty("ai_runtime_task") + private ResolvedValuesAiRuntimeTaskResolvedValues aiRuntimeTask; + /** */ @JsonProperty("condition_task") private ResolvedConditionTaskValues conditionTask; @@ -53,6 +60,15 @@ public class ResolvedValues { @JsonProperty("sql_task") private ResolvedParamPairValues sqlTask; + public ResolvedValues setAiRuntimeTask(ResolvedValuesAiRuntimeTaskResolvedValues aiRuntimeTask) { + this.aiRuntimeTask = aiRuntimeTask; + return this; + } + + public ResolvedValuesAiRuntimeTaskResolvedValues getAiRuntimeTask() { + return aiRuntimeTask; + } + public ResolvedValues setConditionTask(ResolvedConditionTaskValues conditionTask) { this.conditionTask = conditionTask; return this; @@ -157,7 +173,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; ResolvedValues that = (ResolvedValues) o; - return Objects.equals(conditionTask, that.conditionTask) + return Objects.equals(aiRuntimeTask, that.aiRuntimeTask) + && Objects.equals(conditionTask, that.conditionTask) && Objects.equals(dbtTask, that.dbtTask) && Objects.equals(notebookTask, that.notebookTask) && Objects.equals(pipelineTask, that.pipelineTask) @@ -173,6 +190,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( + aiRuntimeTask, conditionTask, dbtTask, notebookTask, @@ -189,6 +207,7 @@ public int hashCode() { @Override public String toString() { return new ToStringer(ResolvedValues.class) + .add("aiRuntimeTask", aiRuntimeTask) .add("conditionTask", conditionTask) .add("dbtTask", dbtTask) .add("notebookTask", notebookTask) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValuesAiRuntimeTaskResolvedValues.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValuesAiRuntimeTaskResolvedValues.java new file mode 100644 index 000000000..d540dfcad --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/ResolvedValuesAiRuntimeTaskResolvedValues.java @@ -0,0 +1,33 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import java.util.Objects; + +/** + * Resolved env_vars for an AiRuntimeTask after dynamic-value substitution. Mirrors the task's + * `resolved_parameters_field` (env_vars) so Jobs can expand `{{tasks..values.}}` + * references before submission. + */ +@Generated +public class ResolvedValuesAiRuntimeTaskResolvedValues { + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + return true; + } + + @Override + public int hashCode() { + return Objects.hash(); + } + + @Override + public String toString() { + return new ToStringer(ResolvedValuesAiRuntimeTaskResolvedValues.class).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunOutput.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunOutput.java index d4a77c84e..9b74bbcf2 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunOutput.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunOutput.java @@ -10,6 +10,15 @@ /** Run output was retrieved successfully. */ @Generated public class RunOutput { + /** + * The output of an AiRuntimeTask, if available — MLflow identifiers, artifact paths, and + * per-replica allocated compute. Run lifecycle / termination status lives on the surrounding + * framework `RunTask.status` (`runs.proto:RunTask.status` of type `RunStatus`), not on this + * output. See `tasks/genai/ai_runtime_task.proto:AiRuntimeTaskOutput`. + */ + @JsonProperty("ai_runtime_task_output") + private AiRuntimeTaskOutput aiRuntimeTaskOutput; + /** The output of an alert task, if available */ @JsonProperty("alert_output") private AlertTaskOutput alertOutput; @@ -89,6 +98,15 @@ public class RunOutput { @JsonProperty("sql_output") private SqlOutput sqlOutput; + public RunOutput setAiRuntimeTaskOutput(AiRuntimeTaskOutput aiRuntimeTaskOutput) { + this.aiRuntimeTaskOutput = aiRuntimeTaskOutput; + return this; + } + + public AiRuntimeTaskOutput getAiRuntimeTaskOutput() { + return aiRuntimeTaskOutput; + } + public RunOutput setAlertOutput(AlertTaskOutput alertOutput) { this.alertOutput = alertOutput; return this; @@ -230,7 +248,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; RunOutput that = (RunOutput) o; - return Objects.equals(alertOutput, that.alertOutput) + return Objects.equals(aiRuntimeTaskOutput, that.aiRuntimeTaskOutput) + && Objects.equals(alertOutput, that.alertOutput) && Objects.equals(cleanRoomsNotebookOutput, that.cleanRoomsNotebookOutput) && Objects.equals(dashboardOutput, that.dashboardOutput) && Objects.equals(dbtCloudOutput, that.dbtCloudOutput) @@ -250,6 +269,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( + aiRuntimeTaskOutput, alertOutput, cleanRoomsNotebookOutput, dashboardOutput, @@ -270,6 +290,7 @@ public int hashCode() { @Override public String toString() { return new ToStringer(RunOutput.class) + .add("aiRuntimeTaskOutput", aiRuntimeTaskOutput) .add("alertOutput", alertOutput) .add("cleanRoomsNotebookOutput", cleanRoomsNotebookOutput) .add("dashboardOutput", dashboardOutput) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunTask.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunTask.java index 46aa89996..14c3d285e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunTask.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/RunTask.java @@ -11,6 +11,13 @@ /** Used when outputting a child run, in GetRun or ListRuns. */ @Generated public class RunTask { + /** + * The task runs a multi-node GPU compute workload on Databricks AI Runtime. External-facing + * surface; mirrors the AIR CLI (fka SGCLI) v2 YAML schema. + */ + @JsonProperty("ai_runtime_task") + private AiRuntimeTask aiRuntimeTask; + /** * The task evaluates a Databricks alert and sends notifications to subscribers when the * `alert_task` field is present. @@ -353,6 +360,15 @@ public class RunTask { @JsonProperty("webhook_notifications") private WebhookNotifications webhookNotifications; + public RunTask setAiRuntimeTask(AiRuntimeTask aiRuntimeTask) { + this.aiRuntimeTask = aiRuntimeTask; + return this; + } + + public AiRuntimeTask getAiRuntimeTask() { + return aiRuntimeTask; + } + public RunTask setAlertTask(AlertTask alertTask) { this.alertTask = alertTask; return this; @@ -844,7 +860,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; RunTask that = (RunTask) o; - return Objects.equals(alertTask, that.alertTask) + return Objects.equals(aiRuntimeTask, that.aiRuntimeTask) + && Objects.equals(alertTask, that.alertTask) && Objects.equals(attemptNumber, that.attemptNumber) && Objects.equals(cleanRoomsNotebookTask, that.cleanRoomsNotebookTask) && Objects.equals(cleanupDuration, that.cleanupDuration) @@ -903,6 +920,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( + aiRuntimeTask, alertTask, attemptNumber, cleanRoomsNotebookTask, @@ -962,6 +980,7 @@ public int hashCode() { @Override public String toString() { return new ToStringer(RunTask.class) + .add("aiRuntimeTask", aiRuntimeTask) .add("alertTask", alertTask) .add("attemptNumber", attemptNumber) .add("cleanRoomsNotebookTask", cleanRoomsNotebookTask) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionConfiguration.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionConfiguration.java new file mode 100644 index 000000000..1f1f92c23 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionConfiguration.java @@ -0,0 +1,80 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +@Generated +public class SqlConditionConfiguration { + /** The ID of the SQL query to evaluate as the trigger condition. */ + @JsonProperty("sql_query_id") + private String sqlQueryId; + + /** + * Determines how the SQL query result is interpreted to decide whether the condition fires. Must + * be set to a recognized value when provided. When unset on an existing serialized configuration, + * the server preserves the original semantics by interpreting it as `QUERY_RETURNS_ROWS`. New + * configurations should set this explicitly — explicit `SQL_CONDITION_TRIGGER_MODE_UNSPECIFIED` + * is rejected at validation. + */ + @JsonProperty("trigger_mode") + private SqlConditionTriggerMode triggerMode; + + /** The canonical identifier of the SQL warehouse to run the condition query against. */ + @JsonProperty("warehouse_id") + private String warehouseId; + + public SqlConditionConfiguration setSqlQueryId(String sqlQueryId) { + this.sqlQueryId = sqlQueryId; + return this; + } + + public String getSqlQueryId() { + return sqlQueryId; + } + + public SqlConditionConfiguration setTriggerMode(SqlConditionTriggerMode triggerMode) { + this.triggerMode = triggerMode; + return this; + } + + public SqlConditionTriggerMode getTriggerMode() { + return triggerMode; + } + + public SqlConditionConfiguration setWarehouseId(String warehouseId) { + this.warehouseId = warehouseId; + return this; + } + + public String getWarehouseId() { + return warehouseId; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + SqlConditionConfiguration that = (SqlConditionConfiguration) o; + return Objects.equals(sqlQueryId, that.sqlQueryId) + && Objects.equals(triggerMode, that.triggerMode) + && Objects.equals(warehouseId, that.warehouseId); + } + + @Override + public int hashCode() { + return Objects.hash(sqlQueryId, triggerMode, warehouseId); + } + + @Override + public String toString() { + return new ToStringer(SqlConditionConfiguration.class) + .add("sqlQueryId", sqlQueryId) + .add("triggerMode", triggerMode) + .add("warehouseId", warehouseId) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionRunInfoDetails.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionRunInfoDetails.java new file mode 100644 index 000000000..642aae3f3 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionRunInfoDetails.java @@ -0,0 +1,89 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** SQL condition evaluation details captured at the time the run was triggered */ +@Generated +public class SqlConditionRunInfoDetails { + /** Whether the last condition evaluation was satisfied (query returned truthy result). */ + @JsonProperty("condition_evaluation_satisfied") + private Boolean conditionEvaluationSatisfied; + + /** + * The ID of the SQL session, used by the UI to track session context. Set for the + * QUERY_RETURNS_ROWS trigger mode. + */ + @JsonProperty("condition_evaluation_sql_session_id") + private String conditionEvaluationSqlSessionId; + + /** + * The SQL statement ID of the condition evaluation, set when the condition is evaluated by + * running a single SQL statement (the RESULT_VALUE_CHANGES trigger mode). The UI uses it to link + * to the query execution details. + */ + @JsonProperty("condition_evaluation_sql_statement_id") + private String conditionEvaluationSqlStatementId; + + public SqlConditionRunInfoDetails setConditionEvaluationSatisfied( + Boolean conditionEvaluationSatisfied) { + this.conditionEvaluationSatisfied = conditionEvaluationSatisfied; + return this; + } + + public Boolean getConditionEvaluationSatisfied() { + return conditionEvaluationSatisfied; + } + + public SqlConditionRunInfoDetails setConditionEvaluationSqlSessionId( + String conditionEvaluationSqlSessionId) { + this.conditionEvaluationSqlSessionId = conditionEvaluationSqlSessionId; + return this; + } + + public String getConditionEvaluationSqlSessionId() { + return conditionEvaluationSqlSessionId; + } + + public SqlConditionRunInfoDetails setConditionEvaluationSqlStatementId( + String conditionEvaluationSqlStatementId) { + this.conditionEvaluationSqlStatementId = conditionEvaluationSqlStatementId; + return this; + } + + public String getConditionEvaluationSqlStatementId() { + return conditionEvaluationSqlStatementId; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + SqlConditionRunInfoDetails that = (SqlConditionRunInfoDetails) o; + return Objects.equals(conditionEvaluationSatisfied, that.conditionEvaluationSatisfied) + && Objects.equals(conditionEvaluationSqlSessionId, that.conditionEvaluationSqlSessionId) + && Objects.equals( + conditionEvaluationSqlStatementId, that.conditionEvaluationSqlStatementId); + } + + @Override + public int hashCode() { + return Objects.hash( + conditionEvaluationSatisfied, + conditionEvaluationSqlSessionId, + conditionEvaluationSqlStatementId); + } + + @Override + public String toString() { + return new ToStringer(SqlConditionRunInfoDetails.class) + .add("conditionEvaluationSatisfied", conditionEvaluationSatisfied) + .add("conditionEvaluationSqlSessionId", conditionEvaluationSqlSessionId) + .add("conditionEvaluationSqlStatementId", conditionEvaluationSqlStatementId) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionState.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionState.java new file mode 100644 index 000000000..6d797b003 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionState.java @@ -0,0 +1,89 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +@Generated +public class SqlConditionState { + /** Whether the last condition evaluation was satisfied (query returned truthy result). */ + @JsonProperty("latest_condition_evaluation_satisfied") + private Boolean latestConditionEvaluationSatisfied; + + /** + * The ID of the SQL session, used by UI to track session context. Populated for + * QUERY_RETURNS_ROWS, which executes the query through Redash. + */ + @JsonProperty("latest_condition_evaluation_sql_session_id") + private String latestConditionEvaluationSqlSessionId; + + /** + * The SEA statement ID of the SQL statement executed for the latest condition evaluation. + * Populated for RESULT_VALUE_CHANGES, which executes the query through the SQL execution API. + */ + @JsonProperty("latest_condition_evaluation_sql_statement_id") + private String latestConditionEvaluationSqlStatementId; + + public SqlConditionState setLatestConditionEvaluationSatisfied( + Boolean latestConditionEvaluationSatisfied) { + this.latestConditionEvaluationSatisfied = latestConditionEvaluationSatisfied; + return this; + } + + public Boolean getLatestConditionEvaluationSatisfied() { + return latestConditionEvaluationSatisfied; + } + + public SqlConditionState setLatestConditionEvaluationSqlSessionId( + String latestConditionEvaluationSqlSessionId) { + this.latestConditionEvaluationSqlSessionId = latestConditionEvaluationSqlSessionId; + return this; + } + + public String getLatestConditionEvaluationSqlSessionId() { + return latestConditionEvaluationSqlSessionId; + } + + public SqlConditionState setLatestConditionEvaluationSqlStatementId( + String latestConditionEvaluationSqlStatementId) { + this.latestConditionEvaluationSqlStatementId = latestConditionEvaluationSqlStatementId; + return this; + } + + public String getLatestConditionEvaluationSqlStatementId() { + return latestConditionEvaluationSqlStatementId; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + SqlConditionState that = (SqlConditionState) o; + return Objects.equals( + latestConditionEvaluationSatisfied, that.latestConditionEvaluationSatisfied) + && Objects.equals( + latestConditionEvaluationSqlSessionId, that.latestConditionEvaluationSqlSessionId) + && Objects.equals( + latestConditionEvaluationSqlStatementId, that.latestConditionEvaluationSqlStatementId); + } + + @Override + public int hashCode() { + return Objects.hash( + latestConditionEvaluationSatisfied, + latestConditionEvaluationSqlSessionId, + latestConditionEvaluationSqlStatementId); + } + + @Override + public String toString() { + return new ToStringer(SqlConditionState.class) + .add("latestConditionEvaluationSatisfied", latestConditionEvaluationSatisfied) + .add("latestConditionEvaluationSqlSessionId", latestConditionEvaluationSqlSessionId) + .add("latestConditionEvaluationSqlStatementId", latestConditionEvaluationSqlStatementId) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionTriggerMode.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionTriggerMode.java new file mode 100644 index 000000000..bc35d242e --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SqlConditionTriggerMode.java @@ -0,0 +1,22 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.jobs; + +import com.databricks.sdk.support.Generated; + +/** + * The strategy used to evaluate a SQL condition trigger against a query result set. + * + *

* `SQL_CONDITION_TRIGGER_MODE_UNSPECIFIED`: Sentinel zero-value. Not a valid input — the + * validator rejects this when sent explicitly. Internally treated as `QUERY_RETURNS_ROWS` when + * reading legacy data that predates this field. * `QUERY_RETURNS_ROWS`: Fires whenever the result + * set has at least one row. Zero rows means the condition is not met. This is the original SQL + * condition behavior. * `RESULT_VALUE_CHANGES`: Fires whenever the query's single result value + * differs from the previous evaluation. The first evaluation always fires. Queries must return + * exactly one cell (one row, one column). + */ +@Generated +public enum SqlConditionTriggerMode { + QUERY_RETURNS_ROWS, // Fires whenever the result set has at least one row. Zero rows means + RESULT_VALUE_CHANGES, // Fires whenever the query's single result value differs from the +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SubmitTask.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SubmitTask.java index e972cb15e..c23d97989 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SubmitTask.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/SubmitTask.java @@ -10,6 +10,13 @@ @Generated public class SubmitTask { + /** + * The task runs a multi-node GPU compute workload on Databricks AI Runtime. External-facing + * surface; mirrors the AIR CLI (fka SGCLI) v2 YAML schema. + */ + @JsonProperty("ai_runtime_task") + private AiRuntimeTask aiRuntimeTask; + /** * The task evaluates a Databricks alert and sends notifications to subscribers when the * `alert_task` field is present. @@ -237,6 +244,15 @@ public class SubmitTask { @JsonProperty("webhook_notifications") private WebhookNotifications webhookNotifications; + public SubmitTask setAiRuntimeTask(AiRuntimeTask aiRuntimeTask) { + this.aiRuntimeTask = aiRuntimeTask; + return this; + } + + public AiRuntimeTask getAiRuntimeTask() { + return aiRuntimeTask; + } + public SubmitTask setAlertTask(AlertTask alertTask) { this.alertTask = alertTask; return this; @@ -584,7 +600,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; SubmitTask that = (SubmitTask) o; - return Objects.equals(alertTask, that.alertTask) + return Objects.equals(aiRuntimeTask, that.aiRuntimeTask) + && Objects.equals(alertTask, that.alertTask) && Objects.equals(cleanRoomsNotebookTask, that.cleanRoomsNotebookTask) && Objects.equals(compute, that.compute) && Objects.equals(conditionTask, that.conditionTask) @@ -627,6 +644,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( + aiRuntimeTask, alertTask, cleanRoomsNotebookTask, compute, @@ -670,6 +688,7 @@ public int hashCode() { @Override public String toString() { return new ToStringer(SubmitTask.class) + .add("aiRuntimeTask", aiRuntimeTask) .add("alertTask", alertTask) .add("cleanRoomsNotebookTask", cleanRoomsNotebookTask) .add("compute", compute) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Task.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Task.java index a1eca711e..997b2cac8 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Task.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/Task.java @@ -10,6 +10,13 @@ @Generated public class Task { + /** + * The task runs a multi-node GPU compute workload on Databricks AI Runtime. External-facing + * surface; mirrors the AIR CLI (fka SGCLI) v2 YAML schema. + */ + @JsonProperty("ai_runtime_task") + private AiRuntimeTask aiRuntimeTask; + /** * The task evaluates a Databricks alert and sends notifications to subscribers when the * `alert_task` field is present. @@ -249,6 +256,15 @@ public class Task { @JsonProperty("webhook_notifications") private WebhookNotifications webhookNotifications; + public Task setAiRuntimeTask(AiRuntimeTask aiRuntimeTask) { + this.aiRuntimeTask = aiRuntimeTask; + return this; + } + + public AiRuntimeTask getAiRuntimeTask() { + return aiRuntimeTask; + } + public Task setAlertTask(AlertTask alertTask) { this.alertTask = alertTask; return this; @@ -605,7 +621,8 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; Task that = (Task) o; - return Objects.equals(alertTask, that.alertTask) + return Objects.equals(aiRuntimeTask, that.aiRuntimeTask) + && Objects.equals(alertTask, that.alertTask) && Objects.equals(cleanRoomsNotebookTask, that.cleanRoomsNotebookTask) && Objects.equals(compute, that.compute) && Objects.equals(conditionTask, that.conditionTask) @@ -649,6 +666,7 @@ public boolean equals(Object o) { @Override public int hashCode() { return Objects.hash( + aiRuntimeTask, alertTask, cleanRoomsNotebookTask, compute, @@ -693,6 +711,7 @@ public int hashCode() { @Override public String toString() { return new ToStringer(Task.class) + .add("aiRuntimeTask", aiRuntimeTask) .add("alertTask", alertTask) .add("cleanRoomsNotebookTask", cleanRoomsNotebookTask) .add("compute", compute) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerInfo.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerInfo.java index 68c5c837b..8cfdb07f2 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerInfo.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerInfo.java @@ -14,6 +14,10 @@ public class TriggerInfo { @JsonProperty("run_id") private Long runId; + /** SQL condition evaluation details for this run */ + @JsonProperty("sql_condition") + private SqlConditionRunInfoDetails sqlCondition; + public TriggerInfo setRunId(Long runId) { this.runId = runId; return this; @@ -23,21 +27,33 @@ public Long getRunId() { return runId; } + public TriggerInfo setSqlCondition(SqlConditionRunInfoDetails sqlCondition) { + this.sqlCondition = sqlCondition; + return this; + } + + public SqlConditionRunInfoDetails getSqlCondition() { + return sqlCondition; + } + @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; TriggerInfo that = (TriggerInfo) o; - return Objects.equals(runId, that.runId); + return Objects.equals(runId, that.runId) && Objects.equals(sqlCondition, that.sqlCondition); } @Override public int hashCode() { - return Objects.hash(runId); + return Objects.hash(runId, sqlCondition); } @Override public String toString() { - return new ToStringer(TriggerInfo.class).add("runId", runId).toString(); + return new ToStringer(TriggerInfo.class) + .add("runId", runId) + .add("sqlCondition", sqlCondition) + .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerSettings.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerSettings.java index c77cfda4c..8992031a2 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerSettings.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerSettings.java @@ -25,6 +25,13 @@ public class TriggerSettings { @JsonProperty("periodic") private PeriodicTriggerConfiguration periodic; + /** + * SQL condition that must be satisfied for the trigger to fire. Can be used in combination with + * other trigger types and runs *after* other trigger types conditions are evaluated. + */ + @JsonProperty("sql_condition") + private SqlConditionConfiguration sqlCondition; + /** */ @JsonProperty("table_update") private TableUpdateTriggerConfiguration tableUpdate; @@ -65,6 +72,15 @@ public PeriodicTriggerConfiguration getPeriodic() { return periodic; } + public TriggerSettings setSqlCondition(SqlConditionConfiguration sqlCondition) { + this.sqlCondition = sqlCondition; + return this; + } + + public SqlConditionConfiguration getSqlCondition() { + return sqlCondition; + } + public TriggerSettings setTableUpdate(TableUpdateTriggerConfiguration tableUpdate) { this.tableUpdate = tableUpdate; return this; @@ -83,12 +99,13 @@ public boolean equals(Object o) { && Objects.equals(model, that.model) && Objects.equals(pauseStatus, that.pauseStatus) && Objects.equals(periodic, that.periodic) + && Objects.equals(sqlCondition, that.sqlCondition) && Objects.equals(tableUpdate, that.tableUpdate); } @Override public int hashCode() { - return Objects.hash(fileArrival, model, pauseStatus, periodic, tableUpdate); + return Objects.hash(fileArrival, model, pauseStatus, periodic, sqlCondition, tableUpdate); } @Override @@ -98,6 +115,7 @@ public String toString() { .add("model", model) .add("pauseStatus", pauseStatus) .add("periodic", periodic) + .add("sqlCondition", sqlCondition) .add("tableUpdate", tableUpdate) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerStateProto.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerStateProto.java index bd9d24f5b..c3bb82b66 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerStateProto.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/jobs/TriggerStateProto.java @@ -13,6 +13,10 @@ public class TriggerStateProto { @JsonProperty("file_arrival") private FileArrivalTriggerState fileArrival; + /** State for SQL condition evaluation, can coexist with other trigger states. */ + @JsonProperty("sql_condition") + private SqlConditionState sqlCondition; + /** */ @JsonProperty("table") private TableTriggerState table; @@ -26,6 +30,15 @@ public FileArrivalTriggerState getFileArrival() { return fileArrival; } + public TriggerStateProto setSqlCondition(SqlConditionState sqlCondition) { + this.sqlCondition = sqlCondition; + return this; + } + + public SqlConditionState getSqlCondition() { + return sqlCondition; + } + public TriggerStateProto setTable(TableTriggerState table) { this.table = table; return this; @@ -40,18 +53,21 @@ public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; TriggerStateProto that = (TriggerStateProto) o; - return Objects.equals(fileArrival, that.fileArrival) && Objects.equals(table, that.table); + return Objects.equals(fileArrival, that.fileArrival) + && Objects.equals(sqlCondition, that.sqlCondition) + && Objects.equals(table, that.table); } @Override public int hashCode() { - return Objects.hash(fileArrival, table); + return Objects.hash(fileArrival, sqlCondition, table); } @Override public String toString() { return new ToStringer(TriggerStateProto.class) .add("fileArrival", fileArrival) + .add("sqlCondition", sqlCondition) .add("table", table) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/AggregationFunction.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/AggregationFunction.java index e0103faff..1c26f6bdd 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/AggregationFunction.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/AggregationFunction.java @@ -30,10 +30,26 @@ public class AggregationFunction { @JsonProperty("first") private FirstFunction first; + /** */ + @JsonProperty("first_distinct_n") + private FirstDistinctNFunction firstDistinctN; + + /** */ + @JsonProperty("first_n") + private FirstNFunction firstN; + /** */ @JsonProperty("last") private LastFunction last; + /** */ + @JsonProperty("last_distinct_n") + private LastDistinctNFunction lastDistinctN; + + /** */ + @JsonProperty("last_n") + private LastNFunction lastN; + /** */ @JsonProperty("max") private MaxFunction max; @@ -112,6 +128,24 @@ public FirstFunction getFirst() { return first; } + public AggregationFunction setFirstDistinctN(FirstDistinctNFunction firstDistinctN) { + this.firstDistinctN = firstDistinctN; + return this; + } + + public FirstDistinctNFunction getFirstDistinctN() { + return firstDistinctN; + } + + public AggregationFunction setFirstN(FirstNFunction firstN) { + this.firstN = firstN; + return this; + } + + public FirstNFunction getFirstN() { + return firstN; + } + public AggregationFunction setLast(LastFunction last) { this.last = last; return this; @@ -121,6 +155,24 @@ public LastFunction getLast() { return last; } + public AggregationFunction setLastDistinctN(LastDistinctNFunction lastDistinctN) { + this.lastDistinctN = lastDistinctN; + return this; + } + + public LastDistinctNFunction getLastDistinctN() { + return lastDistinctN; + } + + public AggregationFunction setLastN(LastNFunction lastN) { + this.lastN = lastN; + return this; + } + + public LastNFunction getLastN() { + return lastN; + } + public AggregationFunction setMax(MaxFunction max) { this.max = max; return this; @@ -203,7 +255,11 @@ public boolean equals(Object o) { && Objects.equals(avg, that.avg) && Objects.equals(countFunction, that.countFunction) && Objects.equals(first, that.first) + && Objects.equals(firstDistinctN, that.firstDistinctN) + && Objects.equals(firstN, that.firstN) && Objects.equals(last, that.last) + && Objects.equals(lastDistinctN, that.lastDistinctN) + && Objects.equals(lastN, that.lastN) && Objects.equals(max, that.max) && Objects.equals(min, that.min) && Objects.equals(stddevPop, that.stddevPop) @@ -222,7 +278,11 @@ public int hashCode() { avg, countFunction, first, + firstDistinctN, + firstN, last, + lastDistinctN, + lastN, max, min, stddevPop, @@ -241,7 +301,11 @@ public String toString() { .add("avg", avg) .add("countFunction", countFunction) .add("first", first) + .add("firstDistinctN", firstDistinctN) + .add("firstN", firstN) .add("last", last) + .add("lastDistinctN", lastDistinctN) + .add("lastN", lastN) .add("max", max) .add("min", min) .add("stddevPop", stddevPop) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstDistinctNFunction.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstDistinctNFunction.java new file mode 100644 index 000000000..c2a7c81ea --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstDistinctNFunction.java @@ -0,0 +1,56 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.ml; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Returns the first N distinct values, ordered by the feature's timeseries column. */ +@Generated +public class FirstDistinctNFunction { + /** The input column from which the first N distinct values are returned. */ + @JsonProperty("input") + private String input; + + /** The number of distinct values to return. */ + @JsonProperty("n") + private Long n; + + public FirstDistinctNFunction setInput(String input) { + this.input = input; + return this; + } + + public String getInput() { + return input; + } + + public FirstDistinctNFunction setN(Long n) { + this.n = n; + return this; + } + + public Long getN() { + return n; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + FirstDistinctNFunction that = (FirstDistinctNFunction) o; + return Objects.equals(input, that.input) && Objects.equals(n, that.n); + } + + @Override + public int hashCode() { + return Objects.hash(input, n); + } + + @Override + public String toString() { + return new ToStringer(FirstDistinctNFunction.class).add("input", input).add("n", n).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstNFunction.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstNFunction.java new file mode 100644 index 000000000..771764cac --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/FirstNFunction.java @@ -0,0 +1,56 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.ml; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Returns the first N values, ordered by the feature's timeseries column. */ +@Generated +public class FirstNFunction { + /** The input column from which the first N values are returned. */ + @JsonProperty("input") + private String input; + + /** The number of values to return. */ + @JsonProperty("n") + private Long n; + + public FirstNFunction setInput(String input) { + this.input = input; + return this; + } + + public String getInput() { + return input; + } + + public FirstNFunction setN(Long n) { + this.n = n; + return this; + } + + public Long getN() { + return n; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + FirstNFunction that = (FirstNFunction) o; + return Objects.equals(input, that.input) && Objects.equals(n, that.n); + } + + @Override + public int hashCode() { + return Objects.hash(input, n); + } + + @Override + public String toString() { + return new ToStringer(FirstNFunction.class).add("input", input).add("n", n).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastDistinctNFunction.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastDistinctNFunction.java new file mode 100644 index 000000000..45242979a --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastDistinctNFunction.java @@ -0,0 +1,56 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.ml; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Returns the last N distinct values, ordered by the feature's timeseries column. */ +@Generated +public class LastDistinctNFunction { + /** The input column from which the last N distinct values are returned. */ + @JsonProperty("input") + private String input; + + /** The number of distinct values to return. */ + @JsonProperty("n") + private Long n; + + public LastDistinctNFunction setInput(String input) { + this.input = input; + return this; + } + + public String getInput() { + return input; + } + + public LastDistinctNFunction setN(Long n) { + this.n = n; + return this; + } + + public Long getN() { + return n; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + LastDistinctNFunction that = (LastDistinctNFunction) o; + return Objects.equals(input, that.input) && Objects.equals(n, that.n); + } + + @Override + public int hashCode() { + return Objects.hash(input, n); + } + + @Override + public String toString() { + return new ToStringer(LastDistinctNFunction.class).add("input", input).add("n", n).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastNFunction.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastNFunction.java new file mode 100644 index 000000000..715457468 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/ml/LastNFunction.java @@ -0,0 +1,56 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.ml; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Returns the last N values, ordered by the feature's timeseries column. */ +@Generated +public class LastNFunction { + /** The input column from which the last N values are returned. */ + @JsonProperty("input") + private String input; + + /** The number of values to return. */ + @JsonProperty("n") + private Long n; + + public LastNFunction setInput(String input) { + this.input = input; + return this; + } + + public String getInput() { + return input; + } + + public LastNFunction setN(Long n) { + this.n = n; + return this; + } + + public Long getN() { + return n; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + LastNFunction that = (LastNFunction) o; + return Objects.equals(input, that.input) && Objects.equals(n, that.n); + } + + @Override + public int hashCode() { + return Objects.hash(input, n); + } + + @Override + public String toString() { + return new ToStringer(LastNFunction.class).add("input", input).add("n", n).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationAPI.java index ecdba7ce3..57cd17c5b 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationAPI.java @@ -30,7 +30,9 @@ public CustomAppIntegrationAPI(CustomAppIntegrationService mock) { /** * Create Custom OAuth App Integration. * - *

You can retrieve the custom OAuth app integration via :method:CustomAppIntegration/get. + *

You can retrieve the custom OAuth app integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ public CreateCustomAppIntegrationOutput create(CreateCustomAppIntegration request) { return impl.create(request); @@ -42,7 +44,9 @@ public void delete(String integrationId) { /** * Delete an existing Custom OAuth App Integration. You can retrieve the custom OAuth app - * integration via :method:CustomAppIntegration/get. + * integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ public void delete(DeleteCustomAppIntegrationRequest request) { impl.delete(request); @@ -74,7 +78,9 @@ public Iterable list(ListCustomAppIntegrationsReq /** * Updates an existing custom OAuth App Integration. You can retrieve the custom OAuth app - * integration via :method:CustomAppIntegration/get. + * integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ public void update(UpdateCustomAppIntegration request) { impl.update(request); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationService.java index b28d086e6..6f738f533 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/CustomAppIntegrationService.java @@ -16,13 +16,17 @@ public interface CustomAppIntegrationService { /** * Create Custom OAuth App Integration. * - *

You can retrieve the custom OAuth app integration via :method:CustomAppIntegration/get. + *

You can retrieve the custom OAuth app integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ CreateCustomAppIntegrationOutput create(CreateCustomAppIntegration createCustomAppIntegration); /** * Delete an existing Custom OAuth App Integration. You can retrieve the custom OAuth app - * integration via :method:CustomAppIntegration/get. + * integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ void delete(DeleteCustomAppIntegrationRequest deleteCustomAppIntegrationRequest); @@ -35,7 +39,9 @@ GetCustomAppIntegrationsOutput list( /** * Updates an existing custom OAuth App Integration. You can retrieve the custom OAuth app - * integration via :method:CustomAppIntegration/get. + * integration via [CustomAppIntegration/get]. + * + *

[CustomAppIntegration/get]: https://docs.databricks.com/api/account/customappintegration/get */ void update(UpdateCustomAppIntegration updateCustomAppIntegration); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationAPI.java index 88514bdfc..330aa2a0d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationAPI.java @@ -31,8 +31,10 @@ public PublishedAppIntegrationAPI(PublishedAppIntegrationService mock) { /** * Create Published OAuth App Integration. * - *

You can retrieve the published OAuth app integration via - * :method:PublishedAppIntegration/get. + *

You can retrieve the published OAuth app integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ public CreatePublishedAppIntegrationOutput create(CreatePublishedAppIntegration request) { return impl.create(request); @@ -44,7 +46,10 @@ public void delete(String integrationId) { /** * Delete an existing Published OAuth App Integration. You can retrieve the published OAuth app - * integration via :method:PublishedAppIntegration/get. + * integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ public void delete(DeletePublishedAppIntegrationRequest request) { impl.delete(request); @@ -77,7 +82,10 @@ public Iterable list( /** * Updates an existing published OAuth App Integration. You can retrieve the published OAuth app - * integration via :method:PublishedAppIntegration/get. + * integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ public void update(UpdatePublishedAppIntegration request) { impl.update(request); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationService.java index bc9200a5e..12d182707 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/oauth2/PublishedAppIntegrationService.java @@ -17,15 +17,20 @@ public interface PublishedAppIntegrationService { /** * Create Published OAuth App Integration. * - *

You can retrieve the published OAuth app integration via - * :method:PublishedAppIntegration/get. + *

You can retrieve the published OAuth app integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ CreatePublishedAppIntegrationOutput create( CreatePublishedAppIntegration createPublishedAppIntegration); /** * Delete an existing Published OAuth App Integration. You can retrieve the published OAuth app - * integration via :method:PublishedAppIntegration/get. + * integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ void delete(DeletePublishedAppIntegrationRequest deletePublishedAppIntegrationRequest); @@ -39,7 +44,10 @@ GetPublishedAppIntegrationsOutput list( /** * Updates an existing published OAuth App Integration. You can retrieve the published OAuth app - * integration via :method:PublishedAppIntegration/get. + * integration via [PublishedAppIntegration/get]. + * + *

[PublishedAppIntegration/get]: + * https://docs.databricks.com/api/account/publishedappintegration/get */ void update(UpdatePublishedAppIntegration updatePublishedAppIntegration); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateDatabaseRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateDatabaseRequest.java index d8d655ff9..9161e83d0 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateDatabaseRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateDatabaseRequest.java @@ -34,6 +34,11 @@ public class CreateDatabaseRequest { */ @JsonIgnore private String parent; + /** If true, update the database if it already exists instead of returning an error. */ + @JsonIgnore + @QueryParam("replace_existing") + private Boolean replaceExisting; + public CreateDatabaseRequest setDatabase(Database database) { this.database = database; return this; @@ -61,6 +66,15 @@ public String getParent() { return parent; } + public CreateDatabaseRequest setReplaceExisting(Boolean replaceExisting) { + this.replaceExisting = replaceExisting; + return this; + } + + public Boolean getReplaceExisting() { + return replaceExisting; + } + @Override public boolean equals(Object o) { if (this == o) return true; @@ -68,12 +82,13 @@ public boolean equals(Object o) { CreateDatabaseRequest that = (CreateDatabaseRequest) o; return Objects.equals(database, that.database) && Objects.equals(databaseId, that.databaseId) - && Objects.equals(parent, that.parent); + && Objects.equals(parent, that.parent) + && Objects.equals(replaceExisting, that.replaceExisting); } @Override public int hashCode() { - return Objects.hash(database, databaseId, parent); + return Objects.hash(database, databaseId, parent, replaceExisting); } @Override @@ -82,6 +97,7 @@ public String toString() { .add("database", database) .add("databaseId", databaseId) .add("parent", parent) + .add("replaceExisting", replaceExisting) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateRoleRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateRoleRequest.java index e2d623d72..f2839914f 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateRoleRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/CreateRoleRequest.java @@ -14,6 +14,18 @@ public class CreateRoleRequest { /** The Branch where this Role is created. Format: projects/{project_id}/branches/{branch_id} */ @JsonIgnore private String parent; + /** + * If true, update the role if it already exists instead of returning an error. + * + *

When the role already exists, the provided `role` spec fully replaces the existing one: + * `membership_roles` is overwritten, not merged. Leaving `membership_roles` empty clears all of + * the role's existing memberships, including `DATABRICKS_SUPERUSER`. Always send the complete + * desired list of memberships when using this field. + */ + @JsonIgnore + @QueryParam("replace_existing") + private Boolean replaceExisting; + /** The desired specification of a Role. */ @JsonProperty("role") private Role role; @@ -40,6 +52,15 @@ public String getParent() { return parent; } + public CreateRoleRequest setReplaceExisting(Boolean replaceExisting) { + this.replaceExisting = replaceExisting; + return this; + } + + public Boolean getReplaceExisting() { + return replaceExisting; + } + public CreateRoleRequest setRole(Role role) { this.role = role; return this; @@ -64,19 +85,21 @@ public boolean equals(Object o) { if (o == null || getClass() != o.getClass()) return false; CreateRoleRequest that = (CreateRoleRequest) o; return Objects.equals(parent, that.parent) + && Objects.equals(replaceExisting, that.replaceExisting) && Objects.equals(role, that.role) && Objects.equals(roleId, that.roleId); } @Override public int hashCode() { - return Objects.hash(parent, role, roleId); + return Objects.hash(parent, replaceExisting, role, roleId); } @Override public String toString() { return new ToStringer(CreateRoleRequest.class) .add("parent", parent) + .add("replaceExisting", replaceExisting) .add("role", role) .add("roleId", roleId) .toString(); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointHosts.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointHosts.java index 98dbbe5f7..d73f8e047 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointHosts.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointHosts.java @@ -27,6 +27,21 @@ public class EndpointHosts { @JsonProperty("read_only_host") private String readOnlyHost; + /** + * The read-only hostname of the compute endpoint, with pooling. This attribute is always defined + * for read-only endpoints, and may be defined for read-write endpoints if configured with read + * replicas and allow read-only connections. + */ + @JsonProperty("read_only_pooled_host") + private String readOnlyPooledHost; + + /** + * The read-write hostname of the compute endpoint, with pooling. This attribute is only defined + * for read-write endpoints. + */ + @JsonProperty("read_write_pooled_host") + private String readWritePooledHost; + public EndpointHosts setHost(String host) { this.host = host; return this; @@ -45,17 +60,38 @@ public String getReadOnlyHost() { return readOnlyHost; } + public EndpointHosts setReadOnlyPooledHost(String readOnlyPooledHost) { + this.readOnlyPooledHost = readOnlyPooledHost; + return this; + } + + public String getReadOnlyPooledHost() { + return readOnlyPooledHost; + } + + public EndpointHosts setReadWritePooledHost(String readWritePooledHost) { + this.readWritePooledHost = readWritePooledHost; + return this; + } + + public String getReadWritePooledHost() { + return readWritePooledHost; + } + @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; EndpointHosts that = (EndpointHosts) o; - return Objects.equals(host, that.host) && Objects.equals(readOnlyHost, that.readOnlyHost); + return Objects.equals(host, that.host) + && Objects.equals(readOnlyHost, that.readOnlyHost) + && Objects.equals(readOnlyPooledHost, that.readOnlyPooledHost) + && Objects.equals(readWritePooledHost, that.readWritePooledHost); } @Override public int hashCode() { - return Objects.hash(host, readOnlyHost); + return Objects.hash(host, readOnlyHost, readOnlyPooledHost, readWritePooledHost); } @Override @@ -63,6 +99,8 @@ public String toString() { return new ToStringer(EndpointHosts.class) .add("host", host) .add("readOnlyHost", readOnlyHost) + .add("readOnlyPooledHost", readOnlyPooledHost) + .add("readWritePooledHost", readWritePooledHost) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointStatus.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointStatus.java index c17c16a5f..a7e59bfbf 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointStatus.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/EndpointStatus.java @@ -6,6 +6,7 @@ import com.databricks.sdk.support.ToStringer; import com.fasterxml.jackson.annotation.JsonProperty; import com.google.protobuf.Duration; +import com.google.protobuf.Timestamp; import java.util.Objects; @Generated @@ -49,6 +50,10 @@ public class EndpointStatus { @JsonProperty("hosts") private EndpointHosts hosts; + /** A timestamp indicating when the compute endpoint was last active. */ + @JsonProperty("last_active_time") + private Timestamp lastActiveTime; + /** */ @JsonProperty("pending_state") private EndpointStatusState pendingState; @@ -133,6 +138,15 @@ public EndpointHosts getHosts() { return hosts; } + public EndpointStatus setLastActiveTime(Timestamp lastActiveTime) { + this.lastActiveTime = lastActiveTime; + return this; + } + + public Timestamp getLastActiveTime() { + return lastActiveTime; + } + public EndpointStatus setPendingState(EndpointStatusState pendingState) { this.pendingState = pendingState; return this; @@ -173,6 +187,7 @@ public boolean equals(Object o) { && Objects.equals(endpointType, that.endpointType) && Objects.equals(group, that.group) && Objects.equals(hosts, that.hosts) + && Objects.equals(lastActiveTime, that.lastActiveTime) && Objects.equals(pendingState, that.pendingState) && Objects.equals(settings, that.settings) && Objects.equals(suspendTimeoutDuration, that.suspendTimeoutDuration); @@ -189,6 +204,7 @@ public int hashCode() { endpointType, group, hosts, + lastActiveTime, pendingState, settings, suspendTimeoutDuration); @@ -205,6 +221,7 @@ public String toString() { .add("endpointType", endpointType) .add("group", group) .add("hosts", hosts) + .add("lastActiveTime", lastActiveTime) .add("pendingState", pendingState) .add("settings", settings) .add("suspendTimeoutDuration", suspendTimeoutDuration) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GenerateDatabaseCredentialRequest.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GenerateDatabaseCredentialRequest.java index ee18d684e..efe588578 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GenerateDatabaseCredentialRequest.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/GenerateDatabaseCredentialRequest.java @@ -5,6 +5,8 @@ import com.databricks.sdk.support.Generated; import com.databricks.sdk.support.ToStringer; import com.fasterxml.jackson.annotation.JsonProperty; +import com.google.protobuf.Duration; +import com.google.protobuf.Timestamp; import java.util.Collection; import java.util.Objects; @@ -21,6 +23,27 @@ public class GenerateDatabaseCredentialRequest { @JsonProperty("endpoint") private String endpoint; + /** + * Timestamp in UTC of when this credential should expire. Must be at least 300 seconds (5 + * minutes) and at most 1 hour from the current time. + */ + @JsonProperty("expire_time") + private Timestamp expireTime; + + /** + * Databricks workspace group name. When provided, credentials are generated with permissions + * scoped to this group. + */ + @JsonProperty("group_name") + private String groupName; + + /** + * The requested time-to-live for the generated credential token. Must be at least 300 seconds (5 + * minutes) and at most 3600 seconds (1 hour). + */ + @JsonProperty("ttl") + private Duration ttl; + public GenerateDatabaseCredentialRequest setClaims(Collection claims) { this.claims = claims; return this; @@ -39,17 +62,48 @@ public String getEndpoint() { return endpoint; } + public GenerateDatabaseCredentialRequest setExpireTime(Timestamp expireTime) { + this.expireTime = expireTime; + return this; + } + + public Timestamp getExpireTime() { + return expireTime; + } + + public GenerateDatabaseCredentialRequest setGroupName(String groupName) { + this.groupName = groupName; + return this; + } + + public String getGroupName() { + return groupName; + } + + public GenerateDatabaseCredentialRequest setTtl(Duration ttl) { + this.ttl = ttl; + return this; + } + + public Duration getTtl() { + return ttl; + } + @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; GenerateDatabaseCredentialRequest that = (GenerateDatabaseCredentialRequest) o; - return Objects.equals(claims, that.claims) && Objects.equals(endpoint, that.endpoint); + return Objects.equals(claims, that.claims) + && Objects.equals(endpoint, that.endpoint) + && Objects.equals(expireTime, that.expireTime) + && Objects.equals(groupName, that.groupName) + && Objects.equals(ttl, that.ttl); } @Override public int hashCode() { - return Objects.hash(claims, endpoint); + return Objects.hash(claims, endpoint, expireTime, groupName, ttl); } @Override @@ -57,6 +111,9 @@ public String toString() { return new ToStringer(GenerateDatabaseCredentialRequest.class) .add("claims", claims) .add("endpoint", endpoint) + .add("expireTime", expireTime) + .add("groupName", groupName) + .add("ttl", ttl) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialBranchSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialBranchSpec.java new file mode 100644 index 000000000..ed5813cfa --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialBranchSpec.java @@ -0,0 +1,43 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.postgres; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Configuration for the initial default branch created during project creation. */ +@Generated +public class InitialBranchSpec { + /** Whether the initial default branch should be protected from deletion. */ + @JsonProperty("is_protected") + private Boolean isProtected; + + public InitialBranchSpec setIsProtected(Boolean isProtected) { + this.isProtected = isProtected; + return this; + } + + public Boolean getIsProtected() { + return isProtected; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + InitialBranchSpec that = (InitialBranchSpec) o; + return Objects.equals(isProtected, that.isProtected); + } + + @Override + public int hashCode() { + return Objects.hash(isProtected); + } + + @Override + public String toString() { + return new ToStringer(InitialBranchSpec.class).add("isProtected", isProtected).toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialEndpointSpec.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialEndpointSpec.java index e33fa9e5f..bb34e2b06 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialEndpointSpec.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/InitialEndpointSpec.java @@ -5,15 +5,57 @@ import com.databricks.sdk.support.Generated; import com.databricks.sdk.support.ToStringer; import com.fasterxml.jackson.annotation.JsonProperty; +import com.google.protobuf.Duration; import java.util.Objects; /** Configuration for the initial Read/Write endpoint created during project creation. */ @Generated public class InitialEndpointSpec { + /** The maximum number of Compute Units for the initial endpoint. */ + @JsonProperty("autoscaling_limit_max_cu") + private Double autoscalingLimitMaxCu; + + /** The minimum number of Compute Units for the initial endpoint. */ + @JsonProperty("autoscaling_limit_min_cu") + private Double autoscalingLimitMinCu; + /** Settings for HA configuration of the endpoint. */ @JsonProperty("group") private EndpointGroupSpec group; + /** + * When set to true, explicitly disables automatic suspension (never suspend). Should be set to + * true when provided. Mutually exclusive with `suspend_timeout_duration`. + */ + @JsonProperty("no_suspension") + private Boolean noSuspension; + + /** + * Duration of inactivity after which the initial endpoint is automatically suspended. If + * specified, should be between 60s and 604800s (1 minute to 1 week). Mutually exclusive with + * `no_suspension`. + */ + @JsonProperty("suspend_timeout_duration") + private Duration suspendTimeoutDuration; + + public InitialEndpointSpec setAutoscalingLimitMaxCu(Double autoscalingLimitMaxCu) { + this.autoscalingLimitMaxCu = autoscalingLimitMaxCu; + return this; + } + + public Double getAutoscalingLimitMaxCu() { + return autoscalingLimitMaxCu; + } + + public InitialEndpointSpec setAutoscalingLimitMinCu(Double autoscalingLimitMinCu) { + this.autoscalingLimitMinCu = autoscalingLimitMinCu; + return this; + } + + public Double getAutoscalingLimitMinCu() { + return autoscalingLimitMinCu; + } + public InitialEndpointSpec setGroup(EndpointGroupSpec group) { this.group = group; return this; @@ -23,21 +65,50 @@ public EndpointGroupSpec getGroup() { return group; } + public InitialEndpointSpec setNoSuspension(Boolean noSuspension) { + this.noSuspension = noSuspension; + return this; + } + + public Boolean getNoSuspension() { + return noSuspension; + } + + public InitialEndpointSpec setSuspendTimeoutDuration(Duration suspendTimeoutDuration) { + this.suspendTimeoutDuration = suspendTimeoutDuration; + return this; + } + + public Duration getSuspendTimeoutDuration() { + return suspendTimeoutDuration; + } + @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; InitialEndpointSpec that = (InitialEndpointSpec) o; - return Objects.equals(group, that.group); + return Objects.equals(autoscalingLimitMaxCu, that.autoscalingLimitMaxCu) + && Objects.equals(autoscalingLimitMinCu, that.autoscalingLimitMinCu) + && Objects.equals(group, that.group) + && Objects.equals(noSuspension, that.noSuspension) + && Objects.equals(suspendTimeoutDuration, that.suspendTimeoutDuration); } @Override public int hashCode() { - return Objects.hash(group); + return Objects.hash( + autoscalingLimitMaxCu, autoscalingLimitMinCu, group, noSuspension, suspendTimeoutDuration); } @Override public String toString() { - return new ToStringer(InitialEndpointSpec.class).add("group", group).toString(); + return new ToStringer(InitialEndpointSpec.class) + .add("autoscalingLimitMaxCu", autoscalingLimitMaxCu) + .add("autoscalingLimitMinCu", autoscalingLimitMinCu) + .add("group", group) + .add("noSuspension", noSuspension) + .add("suspendTimeoutDuration", suspendTimeoutDuration) + .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/Project.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/Project.java index 23f38968c..4eb3fea4f 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/Project.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/Project.java @@ -21,6 +21,14 @@ public class Project { @JsonProperty("delete_time") private Timestamp deleteTime; + /** + * Configuration for the initial default branch created as part of project creation. Allows + * overriding branch protection. These settings only apply at creation time and do not affect + * resources created after project creation. + */ + @JsonProperty("initial_branch_spec") + private InitialBranchSpec initialBranchSpec; + /** * Configuration settings for the initial Read/Write endpoint created inside the initial branch * for a newly created project. If omitted, the initial endpoint created will have default @@ -83,6 +91,15 @@ public Timestamp getDeleteTime() { return deleteTime; } + public Project setInitialBranchSpec(InitialBranchSpec initialBranchSpec) { + this.initialBranchSpec = initialBranchSpec; + return this; + } + + public InitialBranchSpec getInitialBranchSpec() { + return initialBranchSpec; + } + public Project setInitialEndpointSpec(InitialEndpointSpec initialEndpointSpec) { this.initialEndpointSpec = initialEndpointSpec; return this; @@ -162,6 +179,7 @@ public boolean equals(Object o) { Project that = (Project) o; return Objects.equals(createTime, that.createTime) && Objects.equals(deleteTime, that.deleteTime) + && Objects.equals(initialBranchSpec, that.initialBranchSpec) && Objects.equals(initialEndpointSpec, that.initialEndpointSpec) && Objects.equals(name, that.name) && Objects.equals(projectId, that.projectId) @@ -177,6 +195,7 @@ public int hashCode() { return Objects.hash( createTime, deleteTime, + initialBranchSpec, initialEndpointSpec, name, projectId, @@ -192,6 +211,7 @@ public String toString() { return new ToStringer(Project.class) .add("createTime", createTime) .add("deleteTime", deleteTime) + .add("initialBranchSpec", initialBranchSpec) .add("initialEndpointSpec", initialEndpointSpec) .add("name", name) .add("projectId", projectId) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ProjectStatus.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ProjectStatus.java index 8c22dae72..533987582 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ProjectStatus.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/postgres/ProjectStatus.java @@ -6,6 +6,7 @@ import com.databricks.sdk.support.ToStringer; import com.fasterxml.jackson.annotation.JsonProperty; import com.google.protobuf.Duration; +import com.google.protobuf.Timestamp; import java.util.Collection; import java.util.Objects; @@ -19,6 +20,10 @@ public class ProjectStatus { @JsonProperty("budget_policy_id") private String budgetPolicyId; + /** The most recent time when any endpoint of this project was active. */ + @JsonProperty("compute_last_active_time") + private Timestamp computeLastActiveTime; + /** The effective custom tags associated with the project. */ @JsonProperty("custom_tags") private Collection customTags; @@ -77,6 +82,15 @@ public String getBudgetPolicyId() { return budgetPolicyId; } + public ProjectStatus setComputeLastActiveTime(Timestamp computeLastActiveTime) { + this.computeLastActiveTime = computeLastActiveTime; + return this; + } + + public Timestamp getComputeLastActiveTime() { + return computeLastActiveTime; + } + public ProjectStatus setCustomTags(Collection customTags) { this.customTags = customTags; return this; @@ -175,6 +189,7 @@ public boolean equals(Object o) { ProjectStatus that = (ProjectStatus) o; return Objects.equals(branchLogicalSizeLimitBytes, that.branchLogicalSizeLimitBytes) && Objects.equals(budgetPolicyId, that.budgetPolicyId) + && Objects.equals(computeLastActiveTime, that.computeLastActiveTime) && Objects.equals(customTags, that.customTags) && Objects.equals(defaultBranch, that.defaultBranch) && Objects.equals(defaultEndpointSettings, that.defaultEndpointSettings) @@ -192,6 +207,7 @@ public int hashCode() { return Objects.hash( branchLogicalSizeLimitBytes, budgetPolicyId, + computeLastActiveTime, customTags, defaultBranch, defaultEndpointSettings, @@ -209,6 +225,7 @@ public String toString() { return new ToStringer(ProjectStatus.class) .add("branchLogicalSizeLimitBytes", branchLogicalSizeLimitBytes) .add("budgetPolicyId", budgetPolicyId) + .add("computeLastActiveTime", computeLastActiveTime) .add("customTags", customTags) .add("defaultBranch", defaultBranch) .add("defaultEndpointSettings", defaultEndpointSettings) diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/CreateServingEndpoint.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/CreateServingEndpoint.java index 0d684fb49..669bfd45e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/CreateServingEndpoint.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/CreateServingEndpoint.java @@ -56,6 +56,13 @@ public class CreateServingEndpoint { @JsonProperty("tags") private Collection tags; + /** + * Configuration for persisting endpoint telemetry (logs, traces, and metrics) to Unity Catalog + * tables. + */ + @JsonProperty("telemetry_config") + private TelemetryConfig telemetryConfig; + public CreateServingEndpoint setAiGateway(AiGatewayConfig aiGateway) { this.aiGateway = aiGateway; return this; @@ -137,6 +144,15 @@ public Collection getTags() { return tags; } + public CreateServingEndpoint setTelemetryConfig(TelemetryConfig telemetryConfig) { + this.telemetryConfig = telemetryConfig; + return this; + } + + public TelemetryConfig getTelemetryConfig() { + return telemetryConfig; + } + @Override public boolean equals(Object o) { if (this == o) return true; @@ -150,7 +166,8 @@ public boolean equals(Object o) { && Objects.equals(name, that.name) && Objects.equals(rateLimits, that.rateLimits) && Objects.equals(routeOptimized, that.routeOptimized) - && Objects.equals(tags, that.tags); + && Objects.equals(tags, that.tags) + && Objects.equals(telemetryConfig, that.telemetryConfig); } @Override @@ -164,7 +181,8 @@ public int hashCode() { name, rateLimits, routeOptimized, - tags); + tags, + telemetryConfig); } @Override @@ -179,6 +197,7 @@ public String toString() { .add("rateLimits", rateLimits) .add("routeOptimized", routeOptimized) .add("tags", tags) + .add("telemetryConfig", telemetryConfig) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpoint.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpoint.java index 81434ae44..37e12e87e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpoint.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpoint.java @@ -62,6 +62,10 @@ public class ServingEndpoint { @JsonProperty("task") private String task; + /** Telemetry configuration for the endpoint, including inference-table payload logging. */ + @JsonProperty("telemetry_config") + private TelemetryConfig telemetryConfig; + /** The usage policy associated with serving endpoint. */ @JsonProperty("usage_policy_id") private String usagePolicyId; @@ -174,6 +178,15 @@ public String getTask() { return task; } + public ServingEndpoint setTelemetryConfig(TelemetryConfig telemetryConfig) { + this.telemetryConfig = telemetryConfig; + return this; + } + + public TelemetryConfig getTelemetryConfig() { + return telemetryConfig; + } + public ServingEndpoint setUsagePolicyId(String usagePolicyId) { this.usagePolicyId = usagePolicyId; return this; @@ -200,6 +213,7 @@ public boolean equals(Object o) { && Objects.equals(state, that.state) && Objects.equals(tags, that.tags) && Objects.equals(task, that.task) + && Objects.equals(telemetryConfig, that.telemetryConfig) && Objects.equals(usagePolicyId, that.usagePolicyId); } @@ -218,6 +232,7 @@ public int hashCode() { state, tags, task, + telemetryConfig, usagePolicyId); } @@ -236,6 +251,7 @@ public String toString() { .add("state", state) .add("tags", tags) .add("task", task) + .add("telemetryConfig", telemetryConfig) .add("usagePolicyId", usagePolicyId) .toString(); } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointDetailed.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointDetailed.java index e9629fd93..11490868e 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointDetailed.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/ServingEndpointDetailed.java @@ -89,6 +89,10 @@ public class ServingEndpointDetailed { @JsonProperty("task") private String task; + /** Telemetry configuration for the endpoint, including inference-table payload logging. */ + @JsonProperty("telemetry_config") + private TelemetryConfig telemetryConfig; + public ServingEndpointDetailed setAiGateway(AiGatewayConfig aiGateway) { this.aiGateway = aiGateway; return this; @@ -252,6 +256,15 @@ public String getTask() { return task; } + public ServingEndpointDetailed setTelemetryConfig(TelemetryConfig telemetryConfig) { + this.telemetryConfig = telemetryConfig; + return this; + } + + public TelemetryConfig getTelemetryConfig() { + return telemetryConfig; + } + @Override public boolean equals(Object o) { if (this == o) return true; @@ -274,7 +287,8 @@ public boolean equals(Object o) { && Objects.equals(routeOptimized, that.routeOptimized) && Objects.equals(state, that.state) && Objects.equals(tags, that.tags) - && Objects.equals(task, that.task); + && Objects.equals(task, that.task) + && Objects.equals(telemetryConfig, that.telemetryConfig); } @Override @@ -297,7 +311,8 @@ public int hashCode() { routeOptimized, state, tags, - task); + task, + telemetryConfig); } @Override @@ -321,6 +336,7 @@ public String toString() { .add("state", state) .add("tags", tags) .add("task", task) + .add("telemetryConfig", telemetryConfig) .toString(); } } diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryConfig.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryConfig.java new file mode 100644 index 000000000..bc3288bbd --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryConfig.java @@ -0,0 +1,45 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.serving; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +@Generated +public class TelemetryConfig { + /** Configuration for inference table payload logging, including sampling. */ + @JsonProperty("inference_table_config") + private TelemetryInferenceTableConfig inferenceTableConfig; + + public TelemetryConfig setInferenceTableConfig( + TelemetryInferenceTableConfig inferenceTableConfig) { + this.inferenceTableConfig = inferenceTableConfig; + return this; + } + + public TelemetryInferenceTableConfig getInferenceTableConfig() { + return inferenceTableConfig; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + TelemetryConfig that = (TelemetryConfig) o; + return Objects.equals(inferenceTableConfig, that.inferenceTableConfig); + } + + @Override + public int hashCode() { + return Objects.hash(inferenceTableConfig); + } + + @Override + public String toString() { + return new ToStringer(TelemetryConfig.class) + .add("inferenceTableConfig", inferenceTableConfig) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryInferenceTableConfig.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryInferenceTableConfig.java new file mode 100644 index 000000000..c5edc1320 --- /dev/null +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/serving/TelemetryInferenceTableConfig.java @@ -0,0 +1,63 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.serving; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Objects; + +/** Inference table payload logging configuration */ +@Generated +public class TelemetryInferenceTableConfig { + /** The full name of the inference table created for this endpoint. */ + @JsonProperty("name") + private String name; + + /** + * Fraction of requests sampled for payload logging, in the range [0.0, 1.0], where 1.0 logs all + * requests. + */ + @JsonProperty("sampling_fraction") + private Double samplingFraction; + + public TelemetryInferenceTableConfig setName(String name) { + this.name = name; + return this; + } + + public String getName() { + return name; + } + + public TelemetryInferenceTableConfig setSamplingFraction(Double samplingFraction) { + this.samplingFraction = samplingFraction; + return this; + } + + public Double getSamplingFraction() { + return samplingFraction; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + TelemetryInferenceTableConfig that = (TelemetryInferenceTableConfig) o; + return Objects.equals(name, that.name) + && Objects.equals(samplingFraction, that.samplingFraction); + } + + @Override + public int hashCode() { + return Objects.hash(name, samplingFraction); + } + + @Override + public String toString() { + return new ToStringer(TelemetryInferenceTableConfig.class) + .add("name", name) + .add("samplingFraction", samplingFraction) + .toString(); + } +} diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsAPI.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsAPI.java index 38601cfbc..cefe9a89d 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsAPI.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsAPI.java @@ -58,7 +58,9 @@ public IpAccessListsAPI(IpAccessListsService mock) { * current IP, error 400 is returned with `error_code` value `INVALID_STATE`. * *

It can take a few minutes for the changes to take effect. **Note**: Your new IP access list - * has no effect until you enable the feature. See :method:workspaceconf/setStatus + * has no effect until you enable the feature. See [workspaceconf/setStatus] + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ public CreateIpAccessListResponse create(CreateIpAccessList request) { return impl.create(request); @@ -101,7 +103,9 @@ public Iterable list() { * error 400 with `error_code` value `QUOTA_EXCEEDED`. * If the resulting list would block the * calling user's current IP, error 400 is returned with `error_code` value `INVALID_STATE`. It * can take a few minutes for the changes to take effect. Note that your resulting IP access list - * has no effect until you enable the feature. See :method:workspaceconf/setStatus. + * has no effect until you enable the feature. See [workspaceconf/setStatus]. + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ public void replace(ReplaceIpAccessList request) { impl.replace(request); @@ -121,7 +125,9 @@ public void replace(ReplaceIpAccessList request) { * user's current IP, error 400 is returned with `error_code` value `INVALID_STATE`. * *

It can take a few minutes for the changes to take effect. Note that your resulting IP access - * list has no effect until you enable the feature. See :method:workspaceconf/setStatus. + * list has no effect until you enable the feature. See [workspaceconf/setStatus]. + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ public void update(UpdateIpAccessList request) { impl.update(request); diff --git a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsService.java b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsService.java index 4f74e0aa9..2def752a5 100644 --- a/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsService.java +++ b/databricks-sdk-java/src/main/java/com/databricks/sdk/service/settings/IpAccessListsService.java @@ -44,7 +44,9 @@ public interface IpAccessListsService { * current IP, error 400 is returned with `error_code` value `INVALID_STATE`. * *

It can take a few minutes for the changes to take effect. **Note**: Your new IP access list - * has no effect until you enable the feature. See :method:workspaceconf/setStatus + * has no effect until you enable the feature. See [workspaceconf/setStatus] + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ CreateIpAccessListResponse create(CreateIpAccessList createIpAccessList); @@ -67,7 +69,9 @@ public interface IpAccessListsService { * error 400 with `error_code` value `QUOTA_EXCEEDED`. * If the resulting list would block the * calling user's current IP, error 400 is returned with `error_code` value `INVALID_STATE`. It * can take a few minutes for the changes to take effect. Note that your resulting IP access list - * has no effect until you enable the feature. See :method:workspaceconf/setStatus. + * has no effect until you enable the feature. See [workspaceconf/setStatus]. + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ void replace(ReplaceIpAccessList replaceIpAccessList); @@ -85,7 +89,9 @@ public interface IpAccessListsService { * user's current IP, error 400 is returned with `error_code` value `INVALID_STATE`. * *

It can take a few minutes for the changes to take effect. Note that your resulting IP access - * list has no effect until you enable the feature. See :method:workspaceconf/setStatus. + * list has no effect until you enable the feature. See [workspaceconf/setStatus]. + * + *

[workspaceconf/setStatus]: https://docs.databricks.com/api/workspace/workspaceconf/setstatus */ void update(UpdateIpAccessList updateIpAccessList); } diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/gentesting/unittests/HttpPathTest.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/gentesting/unittests/HttpPathTest.java index 13c70c688..eb7715cab 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/gentesting/unittests/HttpPathTest.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/gentesting/unittests/HttpPathTest.java @@ -442,7 +442,28 @@ static List testCases() throws JsonProcessingException, JsonMappingExc } }, "/api/2.0/http-call/get_string/303/false?repeated_complex_query_param=ComplexQueryParam%5BnestedRepeatedQueryParam%3D%5Bitem1%2C+item2%2C+item3%5D%5D&repeated_complex_query_param=ComplexQueryParam%5BnestedRepeatedQueryParam%3D%5Bitem4%2C+item5%2C+item6%5D%5D", - null)); + null), + new TestCase( + "SyncResourceNoBody", + client -> { + try { + client.syncResource( + new SyncResourceRequest() + .setPathParamString("sync_string") + .setPathParamInt(123L) + .setPathParamBool(true)); + } catch (Exception e) { + throw new RuntimeException(e); + } + }, + "/api/2.0/http-call/sync_string/123/true/state:sync", + () -> { + try { + return objectMapper.writeValueAsString(new SyncResourceRequest()); + } catch (JsonProcessingException e) { + throw new RuntimeException(e); + } + })); } @ParameterizedTest(name = "{0}") diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2API.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2API.java index beae0c6dc..34ce547be 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2API.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2API.java @@ -23,7 +23,23 @@ public HttpCallV2API(HttpCallV2Service mock) { impl = mock; } - /** This mimics "old" style post requests which have the resource inlined. */ + /** + * This mimics "old" style post requests which have the resource inlined. + * + *

Set the `path_param_string` value before calling. The _resource_ is sent as the request + * **body**. See the [API overview] for details. + * + *

Supported body styles: + * + *

- [inline] - referenced + * + *

Resolution order: + * + *

1. inline body 2. referenced resource + * + *

[API overview]: https://docs.databricks.com/api [inline]: + * https://docs.databricks.com/api/inline + */ public Resource createResource(CreateResourceRequest request) { return impl.createResource(request); } @@ -40,7 +56,22 @@ public Resource getResource(GetResourceRequest request) { return impl.getResource(request); } - /** This mimics "new" style post requests which have a body field. */ + /** + * This mimics a parameterless custom method: a body:"*" request whose fields are all path-bound, + * so the request carries Content-Type: application/json but has no JSON body fields to serialize. + * The canonical body for such a request is the empty object {}. The :sync verb sits after a + * literal path segment because Databricks rejects a custom verb placed directly after a path + * variable as ambiguous. + */ + public Resource syncResource(SyncResourceRequest request) { + return impl.syncResource(request); + } + + /** + * This mimics "new" style post requests which have a body field. + * + *

> Prefer this over the inline form. + */ public Resource updateResource(UpdateResourceRequest request) { return impl.updateResource(request); } diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Impl.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Impl.java index 96c4fdd8b..631c69891 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Impl.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Impl.java @@ -57,6 +57,27 @@ public Resource getResource(GetResourceRequest request) { } } + @Override + public Resource syncResource(SyncResourceRequest request) { + String path = + String.format( + "/api/2.0/http-call/%s/%s/%s/state:sync", + request.getPathParamString(), request.getPathParamInt(), request.getPathParamBool()); + try { + Request req = new Request("POST", path, apiClient.serialize(request)); + + ApiClient.setQuery(req, request); + req.withHeader("Accept", "application/json"); + req.withHeader("Content-Type", "application/json"); + if (apiClient.workspaceId() != null) { + req.withHeader("X-Databricks-Workspace-Id", apiClient.workspaceId()); + } + return apiClient.execute(req, Resource.class); + } catch (IOException e) { + throw new DatabricksException("IO error: " + e.getMessage(), e); + } + } + @Override public Resource updateResource(UpdateResourceRequest request) { String path = diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Service.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Service.java index 9ae378e4b..ee0239435 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Service.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/HttpCallV2Service.java @@ -12,11 +12,40 @@ */ @Generated public interface HttpCallV2Service { - /** This mimics "old" style post requests which have the resource inlined. */ + /** + * This mimics "old" style post requests which have the resource inlined. + * + *

Set the `path_param_string` value before calling. The _resource_ is sent as the request + * **body**. See the [API overview] for details. + * + *

Supported body styles: + * + *

- [inline] - referenced + * + *

Resolution order: + * + *

1. inline body 2. referenced resource + * + *

[API overview]: https://docs.databricks.com/api [inline]: + * https://docs.databricks.com/api/inline + */ Resource createResource(CreateResourceRequest createResourceRequest); Resource getResource(GetResourceRequest getResourceRequest); - /** This mimics "new" style post requests which have a body field. */ + /** + * This mimics a parameterless custom method: a body:"*" request whose fields are all path-bound, + * so the request carries Content-Type: application/json but has no JSON body fields to serialize. + * The canonical body for such a request is the empty object {}. The :sync verb sits after a + * literal path segment because Databricks rejects a custom verb placed directly after a path + * variable as ambiguous. + */ + Resource syncResource(SyncResourceRequest syncResourceRequest); + + /** + * This mimics "new" style post requests which have a body field. + * + *

> Prefer this over the inline form. + */ Resource updateResource(UpdateResourceRequest updateResourceRequest); } diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/SyncResourceRequest.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/SyncResourceRequest.java new file mode 100644 index 000000000..d0c6f1972 --- /dev/null +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/httpcallv2/SyncResourceRequest.java @@ -0,0 +1,75 @@ +// Code generated from OpenAPI specs by Databricks SDK Generator. DO NOT EDIT. + +package com.databricks.sdk.service.httpcallv2; + +import com.databricks.sdk.support.Generated; +import com.databricks.sdk.support.ToStringer; +import com.fasterxml.jackson.annotation.JsonIgnore; +import java.util.Objects; + +/** + * This mimics a parameterless custom method's request: all fields are path-bound, so the serialized + * JSON body is the empty object {}. + */ +@Generated +public class SyncResourceRequest { + /** Boolean path segment identifying the resource to sync. */ + @JsonIgnore private Boolean pathParamBool; + + /** Integer path segment identifying the resource to sync. */ + @JsonIgnore private Long pathParamInt; + + /** String path segment identifying the resource to sync. */ + @JsonIgnore private String pathParamString; + + public SyncResourceRequest setPathParamBool(Boolean pathParamBool) { + this.pathParamBool = pathParamBool; + return this; + } + + public Boolean getPathParamBool() { + return pathParamBool; + } + + public SyncResourceRequest setPathParamInt(Long pathParamInt) { + this.pathParamInt = pathParamInt; + return this; + } + + public Long getPathParamInt() { + return pathParamInt; + } + + public SyncResourceRequest setPathParamString(String pathParamString) { + this.pathParamString = pathParamString; + return this; + } + + public String getPathParamString() { + return pathParamString; + } + + @Override + public boolean equals(Object o) { + if (this == o) return true; + if (o == null || getClass() != o.getClass()) return false; + SyncResourceRequest that = (SyncResourceRequest) o; + return Objects.equals(pathParamBool, that.pathParamBool) + && Objects.equals(pathParamInt, that.pathParamInt) + && Objects.equals(pathParamString, that.pathParamString); + } + + @Override + public int hashCode() { + return Objects.hash(pathParamBool, pathParamInt, pathParamString); + } + + @Override + public String toString() { + return new ToStringer(SyncResourceRequest.class) + .add("pathParamBool", pathParamBool) + .add("pathParamInt", pathParamInt) + .add("pathParamString", pathParamString) + .toString(); + } +} diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingAPI.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingAPI.java index e71c92e9c..1c05501a2 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingAPI.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingAPI.java @@ -27,7 +27,13 @@ public void cancelOperation(CancelOperationRequest request) { impl.cancelOperation(request); } - /** Simple method to create test resource for LRO testing */ + /** + * Simple method to create test resource for LRO testing. + * + *

Example: + * + *

```python op = w.lro_testing.create_test_resource(resource=resource) ``` + */ public CreateTestResourceOperation createTestResource(CreateTestResourceRequest request) { Operation operation = impl.createTestResource(request); return new CreateTestResourceOperation(impl, operation); diff --git a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingService.java b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingService.java index 82e7e5209..fb2f87cfe 100644 --- a/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingService.java +++ b/databricks-sdk-java/src/test/java/com/databricks/sdk/service/lrotesting/LroTestingService.java @@ -15,7 +15,13 @@ public interface LroTestingService { void cancelOperation(CancelOperationRequest cancelOperationRequest); - /** Simple method to create test resource for LRO testing */ + /** + * Simple method to create test resource for LRO testing. + * + *

Example: + * + *

```python op = w.lro_testing.create_test_resource(resource=resource) ``` + */ Operation createTestResource(CreateTestResourceRequest createTestResourceRequest); Operation deleteTestResource(DeleteTestResourceRequest deleteTestResourceRequest); diff --git a/tagging.py b/tagging.py old mode 100755 new mode 100644 index a3897bbee..0c8cd5822 --- a/tagging.py +++ b/tagging.py @@ -1,4 +1,3 @@ -#!/usr/bin/env python3 # /// script # dependencies = ["PyGithub>=2,<3", "pyjwt<2.12.0", "charset-normalizer<3.4.6"] # ///