diff --git a/.codegen/_last_sha b/.codegen/_last_sha index bd00da3e..9612b05d 100644 --- a/.codegen/_last_sha +++ b/.codegen/_last_sha @@ -1 +1 @@ -155fbabb3529267ce58c1a37573911f59d90b06c \ No newline at end of file +f299cd084fb644bf7610db475c1da7d9b61f04b8 \ No newline at end of file diff --git a/aigateway/CHANGELOG.md b/aigateway/CHANGELOG.md index 15d20d21..456a55de 100644 --- a/aigateway/CHANGELOG.md +++ b/aigateway/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.12.0 (2026-10-22) + ## Release v0.11.0 (2026-10-21) ## Release v0.10.0 (2026-10-20) diff --git a/aigateway/internal/version.go b/aigateway/internal/version.go index c0a78e9d..ec1abd06 100644 --- a/aigateway/internal/version.go +++ b/aigateway/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-aigateway" -const Version = "0.11.0" +const Version = "0.12.0" diff --git a/aigateway/v1/client.go b/aigateway/v1/client.go index 577e2691..236d27ab 100644 --- a/aigateway/v1/client.go +++ b/aigateway/v1/client.go @@ -1480,7 +1480,7 @@ func (c *internalClient) ListModelProviderServicesIter(ctx context.Context, req // // Requires `USE_CATALOG` on the parent catalog and `USE_SCHEMA` on the parent // schema. Only model services the caller can access (as owner or through -// `EXECUTE`, `READ_METADATA`, or `MANAGE`) are returned. +// `EXECUTE`, `READ_METADATA`, or `MANAGE`) are returned by default. func (c *internalClient) ListModelServices(ctx context.Context, req ListModelServicesRequest, opts ...call.Option) (*ListModelServicesResponse, error) { wireReq, err := listModelServicesRequestToWire(&req) if err != nil { diff --git a/aigateway/v1/model.go b/aigateway/v1/model.go index 4072fdb6..707b3696 100644 --- a/aigateway/v1/model.go +++ b/aigateway/v1/model.go @@ -624,16 +624,18 @@ type ModelProviderServiceConfig struct { // breaking AIP-134 partial-Update. The user-facing javadoc on each field states // which fields are required on Create. --) Provider isModelProviderServiceConfig_Provider - // When true, accepts any model exposed by the upstream provider; `targets` is - // not required and does not restrict routability. When false, only models - // listed in `targets` are routable. Defaults to false. + // When true, allows models from the provider's built-in model catalog in + // addition to explicit `targets`. When false, only models listed in `targets` + // are routable. Defaults to false. CUSTOM providers have no built-in model + // catalog and must leave this false and list their models in `targets`. AllowAllTargets *bool `fieldmask:"allow_all_targets"` // Models and provider-native API types exposed by this provider service. Each // entry must include at least one `native_api_types` value. When // `allow_all_targets` is false, at least one entry is required and model // service destinations can reference only listed models. When - // `allow_all_targets` is true, any upstream model is routable; entries in this - // list provide API-type metadata without restricting other models. + // `allow_all_targets` is true, models from the provider's built-in model + // catalog are also routable. CUSTOM providers must explicitly list their models + // here and cannot enable `allow_all_targets`. Targets []ModelProviderServiceConfig_ModelTargetConfig `fieldmask:"targets"` // Whether to forward incoming HTTP headers to the upstream provider. Defaults // to false and is configured for the entire provider service, not per request. diff --git a/aisearch/CHANGELOG.md b/aisearch/CHANGELOG.md index 065e6dea..8825574f 100644 --- a/aisearch/CHANGELOG.md +++ b/aisearch/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.5.0 (2026-10-22) + ## Release v0.4.0 (2026-10-13) ## Release v0.3.0 (2026-10-09) diff --git a/aisearch/internal/version.go b/aisearch/internal/version.go index b585c372..29168d71 100644 --- a/aisearch/internal/version.go +++ b/aisearch/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-aisearch" -const Version = "0.4.0" +const Version = "0.5.0" diff --git a/aisearch/v1/model.go b/aisearch/v1/model.go index 4d88e9b9..d6f5754e 100644 --- a/aisearch/v1/model.go +++ b/aisearch/v1/model.go @@ -128,6 +128,12 @@ const ( // being cleaned up; once cleanup completes the endpoint will no longer be // retrievable. EndpointStatus_State_Deleted EndpointStatus_State = "DELETED" + // Serving compute is being removed. Indexes and their data are retained. + EndpointStatus_State_Stopping EndpointStatus_State = "STOPPING" + // The endpoint has no serving compute. Start it to serve queries again. + EndpointStatus_State_Stopped EndpointStatus_State = "STOPPED" + // Serving compute is being restored; the endpoint becomes ONLINE when ready. + EndpointStatus_State_Starting EndpointStatus_State = "STARTING" ) // How the `model` field is interpreted. diff --git a/budgets/CHANGELOG.md b/budgets/CHANGELOG.md index c48d9918..2bc0c53a 100644 --- a/budgets/CHANGELOG.md +++ b/budgets/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.5.0 (2026-10-22) + ## Release v0.4.0 (2026-10-20) ## Release v0.3.0 (2026-10-13) diff --git a/budgets/internal/version.go b/budgets/internal/version.go index 9f03153a..7e60a00a 100644 --- a/budgets/internal/version.go +++ b/budgets/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-budgets" -const Version = "0.4.0" +const Version = "0.5.0" diff --git a/budgets/v1/model.go b/budgets/v1/model.go index d73a345c..25af6fbb 100644 --- a/budgets/v1/model.go +++ b/budgets/v1/model.go @@ -126,6 +126,12 @@ type BudgetConfiguration struct { Filter *BudgetConfigurationFilter // Human-readable name of budget configuration. Max Length: 128 DisplayName *string + // Whether this budget tracks external pass-through spend (third-party costs + // billed through a product) in addition to internal + // spend. Only applicable to Unity Gateway budgets, i.e. when `resource_type` is + // `BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY`. This field is immutable after + // create. + IncludeExternalSpend *bool // The resource scope for this budget. Determines whether the budget tracks all // resources or a specific resource. ResourceType BudgetResourceType @@ -176,6 +182,12 @@ type CreateBudgetConfigurationBudget struct { Filter *BudgetConfigurationFilter // Human-readable name of budget configuration. Max Length: 128 DisplayName *string + // Whether this budget tracks external pass-through spend (third-party costs + // billed through a product) in addition to internal + // spend. Only applicable to Unity Gateway budgets, i.e. when `resource_type` is + // `BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY`. This field is immutable after + // create. + IncludeExternalSpend *bool // The resource scope for this budget. Determines whether the budget tracks all // resources or a specific resource. ResourceType BudgetResourceType @@ -293,6 +305,12 @@ type UpdateBudgetConfigurationBudget struct { Filter *BudgetConfigurationFilter // Human-readable name of budget configuration. Max Length: 128 DisplayName *string + // Whether this budget tracks external pass-through spend (third-party costs + // billed through a product) in addition to internal + // spend. Only applicable to Unity Gateway budgets, i.e. when `resource_type` is + // `BUDGET_RESOURCE_TYPE_UNITY_AI_GATEWAY`. This field is immutable after + // create. + IncludeExternalSpend *bool // The resource scope for this budget. Determines whether the budget tracks all // resources or a specific resource. ResourceType BudgetResourceType diff --git a/budgets/v1/wire.go b/budgets/v1/wire.go index 60aa2cf5..97c5e03d 100644 --- a/budgets/v1/wire.go +++ b/budgets/v1/wire.go @@ -147,6 +147,7 @@ type budgetConfigurationWire struct { AlertConfigurations []alertConfigurationWire `json:"alert_configurations,omitempty"` Filter *budgetConfigurationFilterWire `json:"filter,omitempty"` DisplayName *string `json:"display_name,omitempty"` + IncludeExternalSpend *bool `json:"include_external_spend,omitempty"` ResourceType BudgetResourceType `json:"resource_type,omitempty"` } @@ -178,6 +179,7 @@ func budgetConfigurationFromWire(w *budgetConfigurationWire) (*BudgetConfigurati AlertConfigurations: alertConfigurationsPublicValue, Filter: filterPublicValue, DisplayName: w.DisplayName, + IncludeExternalSpend: w.IncludeExternalSpend, ResourceType: w.ResourceType, }, nil } @@ -315,11 +317,12 @@ func budgetConfigurationFilter_WorkspaceIdClauseFromWire(w *budgetConfigurationF } type createBudgetConfigurationBudgetWire struct { - AccountId *string `json:"account_id,omitempty"` - AlertConfigurations []createBudgetConfigurationBudgetAlertConfigurationsWire `json:"alert_configurations,omitempty"` - Filter *budgetConfigurationFilterWire `json:"filter,omitempty"` - DisplayName *string `json:"display_name,omitempty"` - ResourceType BudgetResourceType `json:"resource_type,omitempty"` + AccountId *string `json:"account_id,omitempty"` + AlertConfigurations []createBudgetConfigurationBudgetAlertConfigurationsWire `json:"alert_configurations,omitempty"` + Filter *budgetConfigurationFilterWire `json:"filter,omitempty"` + DisplayName *string `json:"display_name,omitempty"` + IncludeExternalSpend *bool `json:"include_external_spend,omitempty"` + ResourceType BudgetResourceType `json:"resource_type,omitempty"` } func createBudgetConfigurationBudgetToWire(v *CreateBudgetConfigurationBudget) (*createBudgetConfigurationBudgetWire, error) { @@ -335,11 +338,12 @@ func createBudgetConfigurationBudgetToWire(v *CreateBudgetConfigurationBudget) ( return nil, fmt.Errorf("%s: %w", "CreateBudgetConfigurationBudget.Filter", err) } return &createBudgetConfigurationBudgetWire{ - AccountId: v.AccountId, - AlertConfigurations: alertConfigurationsWireValue, - Filter: filterWireValue, - DisplayName: v.DisplayName, - ResourceType: v.ResourceType, + AccountId: v.AccountId, + AlertConfigurations: alertConfigurationsWireValue, + Filter: filterWireValue, + DisplayName: v.DisplayName, + IncludeExternalSpend: v.IncludeExternalSpend, + ResourceType: v.ResourceType, }, nil } @@ -515,6 +519,7 @@ type updateBudgetConfigurationBudgetWire struct { AlertConfigurations []alertConfigurationWire `json:"alert_configurations,omitempty"` Filter *budgetConfigurationFilterWire `json:"filter,omitempty"` DisplayName *string `json:"display_name,omitempty"` + IncludeExternalSpend *bool `json:"include_external_spend,omitempty"` ResourceType BudgetResourceType `json:"resource_type,omitempty"` } @@ -536,6 +541,7 @@ func updateBudgetConfigurationBudgetToWire(v *UpdateBudgetConfigurationBudget) ( AlertConfigurations: alertConfigurationsWireValue, Filter: filterWireValue, DisplayName: v.DisplayName, + IncludeExternalSpend: v.IncludeExternalSpend, ResourceType: v.ResourceType, }, nil } diff --git a/features/CHANGELOG.md b/features/CHANGELOG.md index 00331315..3f476459 100644 --- a/features/CHANGELOG.md +++ b/features/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.11.0 (2026-10-22) + ## Release v0.10.0 (2026-10-21) ## Release v0.9.0 (2026-10-13) diff --git a/features/internal/version.go b/features/internal/version.go index e0c372e6..38031ab2 100644 --- a/features/internal/version.go +++ b/features/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-features" -const Version = "0.10.0" +const Version = "0.11.0" diff --git a/features/v1/model.go b/features/v1/model.go index 3e3d890a..5f965931 100644 --- a/features/v1/model.go +++ b/features/v1/model.go @@ -561,6 +561,17 @@ const ( StreamingMode_StreamingModeType_StreamingModeTypeMbm StreamingMode_StreamingModeType = "STREAMING_MODE_TYPE_MBM" ) +// Which source table updates trigger a materialization run. +type TableTrigger_TableTriggerCondition string + +const ( + TableTrigger_TableTriggerCondition_Unspecified TableTrigger_TableTriggerCondition = "" + // Fire when any source table updates. + TableTrigger_TableTriggerCondition_TableTriggerConditionAnyUpdated TableTrigger_TableTriggerCondition = "TABLE_TRIGGER_CONDITION_ANY_UPDATED" + // Fire only once every source table has updated. + TableTrigger_TableTriggerCondition_TableTriggerConditionAllUpdated TableTrigger_TableTriggerCondition = "TABLE_TRIGGER_CONDITION_ALL_UPDATED" +) + // An aggregation function applied over a time window.. type AggregationFunction struct { // The type of the aggregation function. @@ -727,7 +738,18 @@ type ApproxCountDistinctFunction struct { // computed. Input *string `fieldmask:"input"` // The maximum relative standard deviation allowed (default defined by Spark). + // Deprecated: use relative_error. When relative_error is set, reads return the + // same value here for clients that don't have relative_error, and a request may + // only send that value. RelativeSd *float64 `fieldmask:"relative_sd"` + // The error the user accepts, as a fraction of the count, between 0.02 (by + // default) and 0.3. This is one standard error of the estimate, the same + // meaning as Spark's relativeSD: 0.02 means the result is within ±2% of the + // true count about 68% of the time (one standard deviation covers 68% of the + // region). Feature Store picks the sketch size that gives this relative error. + // If neither relative_error nor relative_sd is set, 0.02 is default chosen at + // feature creation. + RelativeError *float64 `fieldmask:"relative_error"` } // Computes the approximate percentile of values.. @@ -736,8 +758,18 @@ type ApproxPercentileFunction struct { Input *string `fieldmask:"input"` // The percentile value to compute (between 0 and 1). Percentile *float64 `fieldmask:"percentile"` - // The accuracy parameter (higher is more accurate but slower). + // The accuracy parameter (higher is more accurate but slower). Deprecated: use + // relative_error. When relative_error is set, reads return ceil(1 / + // relative_error) here for clients that don't have relative_error, and a + // request may only send that value. Accuracy *int64 `fieldmask:"accuracy"` + // The error the user accepts, as a fraction of rank, between 0.01 (by default) + // and 0.3. The result is within this rank error with 99% confidence: at 0.01, + // the value returned for p95 is between the true p94 and p96 at least 99% of + // the time. Feature Store picks the sketch size that gives this error. If + // neither relative_error nor accuracy is set, 0.01 is default chosen at feature + // creation. + RelativeError *float64 `fieldmask:"relative_error"` } type AuthConfig struct { @@ -2494,8 +2526,22 @@ type SumFunction struct { Input *string `fieldmask:"input"` } -// A trigger that fires when the upstream source table changes.. +// A trigger that fires when the feature's source table changes: a +// DeltaTableSource's table, or an SdpSource's input_tables.. type TableTrigger struct { + // The minimum time between two triggered runs, so a frequently updated source + // table does not trigger runs too often. If not set, a feature with a sliding + // window uses half its slide_duration and a feature with a tumbling window uses + // half its window_duration, clamped to between 5 minutes and 1 hour. Other + // features have no minimum. + MinTimeBetweenTriggers *types.Duration `fieldmask:"min_time_between_triggers"` + // How long the source table must go without updates before a run starts, so a + // series of updates settles before the run. If not set, a run starts as soon as + // the source table updates. + WaitAfterLastChange *types.Duration `fieldmask:"wait_after_last_change"` + // Which source table updates trigger a materialization run. If not set, any + // source table update triggers a run. + Condition TableTrigger_TableTriggerCondition `fieldmask:"condition"` } type TimeWindow struct { diff --git a/features/v1/wire.go b/features/v1/wire.go index 749ac329..9ae4f7f4 100644 --- a/features/v1/wire.go +++ b/features/v1/wire.go @@ -465,8 +465,9 @@ func apiErrorFromWire(w *apiErrorWire) (*ApiError, error) { } type approxCountDistinctFunctionWire struct { - Input *string `json:"input,omitempty"` - RelativeSd *float64 `json:"relative_sd,omitempty"` + Input *string `json:"input,omitempty"` + RelativeSd *float64 `json:"relative_sd,omitempty"` + RelativeError *float64 `json:"relative_error,omitempty"` } func approxCountDistinctFunctionToWire(v *ApproxCountDistinctFunction) (*approxCountDistinctFunctionWire, error) { @@ -474,8 +475,9 @@ func approxCountDistinctFunctionToWire(v *ApproxCountDistinctFunction) (*approxC return nil, nil } return &approxCountDistinctFunctionWire{ - Input: v.Input, - RelativeSd: v.RelativeSd, + Input: v.Input, + RelativeSd: v.RelativeSd, + RelativeError: v.RelativeError, }, nil } @@ -484,15 +486,17 @@ func approxCountDistinctFunctionFromWire(w *approxCountDistinctFunctionWire) (*A return nil, nil } return &ApproxCountDistinctFunction{ - Input: w.Input, - RelativeSd: w.RelativeSd, + Input: w.Input, + RelativeSd: w.RelativeSd, + RelativeError: w.RelativeError, }, nil } type approxPercentileFunctionWire struct { - Input *string `json:"input,omitempty"` - Percentile *float64 `json:"percentile,omitempty"` - Accuracy *wireInt64 `json:"accuracy,omitempty"` + Input *string `json:"input,omitempty"` + Percentile *float64 `json:"percentile,omitempty"` + Accuracy *wireInt64 `json:"accuracy,omitempty"` + RelativeError *float64 `json:"relative_error,omitempty"` } func approxPercentileFunctionToWire(v *ApproxPercentileFunction) (*approxPercentileFunctionWire, error) { @@ -504,9 +508,10 @@ func approxPercentileFunctionToWire(v *ApproxPercentileFunction) (*approxPercent return nil, fmt.Errorf("%s: %w", "ApproxPercentileFunction.Accuracy", err) } return &approxPercentileFunctionWire{ - Input: v.Input, - Percentile: v.Percentile, - Accuracy: accuracyWireValue, + Input: v.Input, + Percentile: v.Percentile, + Accuracy: accuracyWireValue, + RelativeError: v.RelativeError, }, nil } @@ -519,9 +524,10 @@ func approxPercentileFunctionFromWire(w *approxPercentileFunctionWire) (*ApproxP return nil, fmt.Errorf("%s: %w", "ApproxPercentileFunction.Accuracy", err) } return &ApproxPercentileFunction{ - Input: w.Input, - Percentile: w.Percentile, - Accuracy: accuracyPublicValue, + Input: w.Input, + Percentile: w.Percentile, + Accuracy: accuracyPublicValue, + RelativeError: w.RelativeError, }, nil } @@ -4144,20 +4150,31 @@ func sumFunctionFromWire(w *sumFunctionWire) (*SumFunction, error) { } type tableTriggerWire struct { + MinTimeBetweenTriggers *types.Duration `json:"min_time_between_triggers,omitempty"` + WaitAfterLastChange *types.Duration `json:"wait_after_last_change,omitempty"` + Condition TableTrigger_TableTriggerCondition `json:"condition,omitempty"` } func tableTriggerToWire(v *TableTrigger) (*tableTriggerWire, error) { if v == nil { return nil, nil } - return &tableTriggerWire{}, nil + return &tableTriggerWire{ + MinTimeBetweenTriggers: v.MinTimeBetweenTriggers, + WaitAfterLastChange: v.WaitAfterLastChange, + Condition: v.Condition, + }, nil } func tableTriggerFromWire(w *tableTriggerWire) (*TableTrigger, error) { if w == nil { return nil, nil } - return &TableTrigger{}, nil + return &TableTrigger{ + MinTimeBetweenTriggers: w.MinTimeBetweenTriggers, + WaitAfterLastChange: w.WaitAfterLastChange, + Condition: w.Condition, + }, nil } type timeWindowWire struct { diff --git a/go.work b/go.work index 4f5f9f56..3948c94e 100644 --- a/go.work +++ b/go.work @@ -38,7 +38,6 @@ use ( ./instanceprofiles ./jobs ./keyconfigurations - ./knowledge ./knowledgeassistants ./lakeview ./logdelivery diff --git a/knowledge/.package.json b/knowledge/.package.json deleted file mode 100644 index c96a64a2..00000000 --- a/knowledge/.package.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "package": "knowledge" -} diff --git a/knowledge/CHANGELOG.md b/knowledge/CHANGELOG.md deleted file mode 100644 index a475feea..00000000 --- a/knowledge/CHANGELOG.md +++ /dev/null @@ -1,16 +0,0 @@ -# Version changelog - -## Release v0.1.0 (2026-10-13) - -## Release v0.0.1 (2026-10-02) - -### New Features and Improvements -* Beta release. - -## Release v0.0.1-dev.4 (2026-09-30) - -## Release v0.0.1-dev.3 (2026-09-17) - -## Release v0.0.1-dev.2 (2026-09-16) - -## Release v0.0.1-dev.1 (2026-09-15) diff --git a/knowledge/go.mod b/knowledge/go.mod deleted file mode 100644 index 7e1fb42d..00000000 --- a/knowledge/go.mod +++ /dev/null @@ -1,28 +0,0 @@ -module github.com/databricks/sdk-go/knowledge - -go 1.26.0 - -replace github.com/databricks/sdk-go/auth => ../auth - -replace github.com/databricks/sdk-go/core => ../core - -replace github.com/databricks/sdk-go/options => ../options - -require ( - github.com/databricks/sdk-go/auth v0.2.0 - github.com/databricks/sdk-go/core v0.1.0 - github.com/databricks/sdk-go/options v0.0.0-00010101000000-000000000000 -) - -require ( - github.com/databricks/databricks-sdk-go v0.92.0 // indirect - github.com/google/go-querystring v1.1.0 // indirect - github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c // indirect - golang.org/x/exp v0.0.0-20240222234643-814bf88cf225 // indirect - golang.org/x/mod v0.17.0 // indirect - golang.org/x/oauth2 v0.33.0 // indirect - golang.org/x/sys v0.28.0 // indirect - golang.org/x/text v0.21.0 // indirect - golang.org/x/time v0.5.0 // indirect - gopkg.in/ini.v1 v1.67.0 // indirect -) diff --git a/knowledge/internal/version.go b/knowledge/internal/version.go deleted file mode 100644 index 56746386..00000000 --- a/knowledge/internal/version.go +++ /dev/null @@ -1,5 +0,0 @@ -package internal - -const ModuleName = "sdk-go-knowledge" - -const Version = "0.1.0" diff --git a/knowledge/v1/genhelper.go b/knowledge/v1/genhelper.go deleted file mode 100644 index 08bb0727..00000000 --- a/knowledge/v1/genhelper.go +++ /dev/null @@ -1,157 +0,0 @@ -// Code generated by Databricks SDK Generator. DO NOT EDIT. - -package knowledge - -import ( - "context" - "io" - "log/slog" - "net/http" - "time" - - "github.com/databricks/sdk-go/auth" - "github.com/databricks/sdk-go/core/apierr" - "github.com/databricks/sdk-go/core/ops" - "github.com/databricks/sdk-go/options/call" - "github.com/databricks/sdk-go/options/internaloptions" -) - -type httpCallOptions struct { - req *http.Request - client *http.Client - logger *slog.Logger -} - -type httpRequestOptions struct { - Method string - URL string - Credentials auth.Credentials - UserAgent func() (string, error) - Headers http.Header - Body io.Reader -} - -func newHTTPRequest(ctx context.Context, opts httpRequestOptions) (*http.Request, error) { - req, err := http.NewRequestWithContext(ctx, opts.Method, opts.URL, opts.Body) - if err != nil { - closeBody(opts.Body) - return nil, err - } - - req.Header = opts.Headers.Clone() - if opts.Credentials != nil { - headers, err := opts.Credentials.AuthHeaders(ctx) - if err != nil { - closeBody(opts.Body) - return nil, err - } - for _, h := range headers { - req.Header.Add(h.Key, h.Value) - } - } - if opts.UserAgent != nil { - userAgent, err := opts.UserAgent() - if err != nil { - closeBody(opts.Body) - return nil, err - } - if userAgent != "" { - req.Header.Set("User-Agent", userAgent) - } - } - - return req, nil -} - -func closeBody(body io.Reader) { - if body == nil { - return - } - if rc, ok := body.(io.ReadCloser); ok { - _ = rc.Close() - } -} - -// lazyRequest implements slog.LogValuer for lazy evaluation of request -// logging. -type lazyRequest struct{ req *http.Request } - -func (r lazyRequest) LogValue() slog.Value { - return slog.GroupValue( - slog.String("method", r.req.Method), - slog.String("url", r.req.URL.String()), - ) -} - -// lazyResponse implements slog.LogValuer for lazy evaluation of response -// logging. -type lazyResponse struct { - resp *http.Response - body []byte -} - -func (r lazyResponse) LogValue() slog.Value { - return slog.GroupValue( - slog.Int("status", r.resp.StatusCode), - slog.String("body", string(r.body)), - ) -} - -// executeHTTPCall executes an HTTP call and returns the response body and -// headers, or an error. The headers are returned so callers can populate -// header-mapped response fields alongside the JSON body. This function takes -// care of logging the request and response. -func executeHTTPCall(opts httpCallOptions) ([]byte, http.Header, error) { - opts.logger.Debug("HTTP request", "request", lazyRequest{opts.req}) - resp, err := opts.client.Do(opts.req) - if err != nil { - return nil, nil, err - } - defer resp.Body.Close() - body, err := io.ReadAll(resp.Body) - if err != nil { - opts.logger.Debug("HTTP response", "response", lazyResponse{resp, nil}) - return nil, nil, err - } - opts.logger.Debug("HTTP response", "response", lazyResponse{resp, body}) - if err := apierr.FromHTTPError(resp.StatusCode, resp.Header, body); err != nil { - return nil, nil, err - } - return body, resp.Header, nil -} - -func (c *internalClient) resolveCallOptions( - opts []call.Option, - timeout time.Duration, -) (internaloptions.CallOptions, error) { - cfg := internaloptions.CallOptions{Timeout: timeout} - if c.callTimeout != nil { - cfg.Timeout = *c.callTimeout - } - for _, opt := range opts { - if err := opt(&cfg); err != nil { - return internaloptions.CallOptions{}, err - } - } - return cfg, nil -} - -func (c *internalClient) executeCall( - ctx context.Context, - op func(context.Context) error, - opts []call.Option, -) error { - cfg, err := c.resolveCallOptions(opts, 5*time.Minute) - if err != nil { - return err - } - return executeResolvedCall(ctx, op, cfg) -} - -func executeResolvedCall(ctx context.Context, op func(context.Context) error, cfg internaloptions.CallOptions) error { - return ops.Execute(ctx, op, - ops.WithRetrier(cfg.Retrier), - ops.WithLimiter(cfg.RateLimiter), - ops.WithTimeout(cfg.Timeout), - ) -} diff --git a/networking/CHANGELOG.md b/networking/CHANGELOG.md index 14d73701..76979521 100644 --- a/networking/CHANGELOG.md +++ b/networking/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.5.0 (2026-10-22) + ## Release v0.4.0 (2026-10-15) ## Release v0.3.0 (2026-10-13) diff --git a/networking/internal/version.go b/networking/internal/version.go index 29662270..d1d65772 100644 --- a/networking/internal/version.go +++ b/networking/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-networking" -const Version = "0.4.0" +const Version = "0.5.0" diff --git a/networking/v1/model.go b/networking/v1/model.go index c6af477e..4b2f4136 100644 --- a/networking/v1/model.go +++ b/networking/v1/model.go @@ -1012,7 +1012,9 @@ type IngressNetworkPolicy struct { PublicAccess *IngressNetworkPolicy_PublicAccess // The network policy restrictions for private access. Configures how requests // arriving over private connectivity are governed. - PrivateAccess *IngressNetworkPolicy_PrivateAccess + PrivateAccess *IngressNetworkPolicy_PrivateAccess + // The network policy restrictions for cross-workspace access: which other + // workspaces may access this workspace. CrossWorkspaceAccess *IngressNetworkPolicy_CrossWorkspaceAccess } diff --git a/pipelines/CHANGELOG.md b/pipelines/CHANGELOG.md index 79fa15d9..c89f5bcf 100644 --- a/pipelines/CHANGELOG.md +++ b/pipelines/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.8.0 (2026-10-22) + ## Release v0.7.0 (2026-10-20) ## Release v0.6.0 (2026-10-19) diff --git a/pipelines/internal/version.go b/pipelines/internal/version.go index 5c16ec9b..8c9d4db2 100644 --- a/pipelines/internal/version.go +++ b/pipelines/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-pipelines" -const Version = "0.7.0" +const Version = "0.8.0" diff --git a/pipelines/v2/model.go b/pipelines/v2/model.go index 3667ee1c..48d3b855 100644 --- a/pipelines/v2/model.go +++ b/pipelines/v2/model.go @@ -90,6 +90,7 @@ const ( IngestionSourceType_Zendesk IngestionSourceType = "ZENDESK" IngestionSourceType_Smartsheet IngestionSourceType = "SMARTSHEET" IngestionSourceType_Rabbitmq IngestionSourceType = "RABBITMQ" + IngestionSourceType_Onedrive IngestionSourceType = "ONEDRIVE" IngestionSourceType_ForeignCatalog IngestionSourceType = "FOREIGN_CATALOG" ) @@ -341,6 +342,15 @@ const ( LinkedInAdsOptions_LinkedInAdsCustomReportOptions_LinkedInAdsTimeGranularity_Yearly LinkedInAdsOptions_LinkedInAdsCustomReportOptions_LinkedInAdsTimeGranularity = "YEARLY" ) +// The type of OneDrive entity to ingest. +type OneDriveOptions_OneDriveEntityType string + +const ( + OneDriveOptions_OneDriveEntityType_Unspecified OneDriveOptions_OneDriveEntityType = "" + OneDriveOptions_OneDriveEntityType_File OneDriveOptions_OneDriveEntityType = "FILE" + OneDriveOptions_OneDriveEntityType_FileMetadata OneDriveOptions_OneDriveEntityType = "FILE_METADATA" +) + // The pipeline state. type PipelineState_PipelineState string @@ -716,6 +726,13 @@ type ConnectorOptions_ConnectorOptions_ApiSourceConnectorOptions struct { func (*ConnectorOptions_ConnectorOptions_ApiSourceConnectorOptions) isConnectorOptions_ConnectorOptions() { } +// ConnectorOptions_ConnectorOptions_OnedriveOptions selects OnedriveOptions for ConnectorOptions.ConnectorOptions. +type ConnectorOptions_ConnectorOptions_OnedriveOptions struct { + OnedriveOptions OneDriveOptions +} + +func (*ConnectorOptions_ConnectorOptions_OnedriveOptions) isConnectorOptions_ConnectorOptions() {} + type CreatePipelineRequest struct { // If false, deployment will fail if name conflicts with that of another // pipeline. @@ -1776,6 +1793,16 @@ type Notifications struct { Alerts []string } +type OneDriveOptions struct { + // Required. The OneDrive URL. + Url *string + // (Optional) The type of OneDrive entity to ingest. If not specified, defaults + // to FILE. + EntityType OneDriveOptions_OneDriveEntityType + // (Optional) File ingestion options for processing files. + FileIngestionOptions *FileIngestionOptions +} + // Proto representing a window. type OperationTimeWindow struct { // An integer between 0 and 23 denoting the start hour for the window in the diff --git a/pipelines/v2/wire.go b/pipelines/v2/wire.go index 8f31c19a..20bacef9 100644 --- a/pipelines/v2/wire.go +++ b/pipelines/v2/wire.go @@ -396,6 +396,7 @@ type connectorOptionsWire struct { LinkedinAdsOptions *linkedInAdsOptionsWire `json:"linkedin_ads_options,omitempty"` RedditAdsOptions *redditAdsOptionsWire `json:"reddit_ads_options,omitempty"` ApiSourceConnectorOptions *apiSourceConnectorOptionsWire `json:"api_source_connector_options,omitempty"` + OnedriveOptions *oneDriveOptionsWire `json:"onedrive_options,omitempty"` } func connectorOptionsToWire(v *ConnectorOptions) (*connectorOptionsWire, error) { @@ -418,6 +419,7 @@ func connectorOptionsToWire(v *ConnectorOptions) (*connectorOptionsWire, error) var connectorOptionsLinkedinAdsOptionsWire *linkedInAdsOptionsWire var connectorOptionsRedditAdsOptionsWire *redditAdsOptionsWire var connectorOptionsApiSourceConnectorOptionsWire *apiSourceConnectorOptionsWire + var connectorOptionsOnedriveOptionsWire *oneDriveOptionsWire switch value := v.ConnectorOptions.(type) { case nil: case *ConnectorOptions_ConnectorOptions_GoogleAdsOptions: @@ -548,6 +550,14 @@ func connectorOptionsToWire(v *ConnectorOptions) (*connectorOptionsWire, error) } connectorOptionsApiSourceConnectorOptionsWire = connectorOptionsApiSourceConnectorOptionsConverted } + case *ConnectorOptions_ConnectorOptions_OnedriveOptions: + if value != nil { + connectorOptionsOnedriveOptionsConverted, err := oneDriveOptionsToWire(&value.OnedriveOptions) + if err != nil { + return nil, fmt.Errorf("%s: %w", "ConnectorOptions.ConnectorOptions.OnedriveOptions", err) + } + connectorOptionsOnedriveOptionsWire = connectorOptionsOnedriveOptionsConverted + } default: return nil, fmt.Errorf("%s: unsupported oneof implementation %T", "ConnectorOptions.ConnectorOptions", value) } @@ -568,6 +578,7 @@ func connectorOptionsToWire(v *ConnectorOptions) (*connectorOptionsWire, error) LinkedinAdsOptions: connectorOptionsLinkedinAdsOptionsWire, RedditAdsOptions: connectorOptionsRedditAdsOptionsWire, ApiSourceConnectorOptions: connectorOptionsApiSourceConnectorOptionsWire, + OnedriveOptions: connectorOptionsOnedriveOptionsWire, }, nil } @@ -624,6 +635,9 @@ func connectorOptionsFromWire(w *connectorOptionsWire) (*ConnectorOptions, error if w.ApiSourceConnectorOptions != nil { connectorOptionsMembers++ } + if w.OnedriveOptions != nil { + connectorOptionsMembers++ + } if connectorOptionsMembers > 1 { return nil, fmt.Errorf("%s: multiple oneof members set", "ConnectorOptions.ConnectorOptions") } @@ -725,6 +739,12 @@ func connectorOptionsFromWire(w *connectorOptionsWire) (*ConnectorOptions, error return nil, fmt.Errorf("%s: %w", "ConnectorOptions.ConnectorOptions.ApiSourceConnectorOptions", err) } connectorOptionsSelection = &ConnectorOptions_ConnectorOptions_ApiSourceConnectorOptions{ApiSourceConnectorOptions: *connectorOptionsApiSourceConnectorOptionsConverted} + case w.OnedriveOptions != nil: + connectorOptionsOnedriveOptionsConverted, err := oneDriveOptionsFromWire(w.OnedriveOptions) + if err != nil { + return nil, fmt.Errorf("%s: %w", "ConnectorOptions.ConnectorOptions.OnedriveOptions", err) + } + connectorOptionsSelection = &ConnectorOptions_ConnectorOptions_OnedriveOptions{OnedriveOptions: *connectorOptionsOnedriveOptionsConverted} } return &ConnectorOptions{ ConnectorOptions: connectorOptionsSelection, @@ -2636,6 +2656,42 @@ func notificationsFromWire(w *notificationsWire) (*Notifications, error) { }, nil } +type oneDriveOptionsWire struct { + Url *string `json:"url,omitempty"` + EntityType OneDriveOptions_OneDriveEntityType `json:"entity_type,omitempty"` + FileIngestionOptions *fileIngestionOptionsWire `json:"file_ingestion_options,omitempty"` +} + +func oneDriveOptionsToWire(v *OneDriveOptions) (*oneDriveOptionsWire, error) { + if v == nil { + return nil, nil + } + fileIngestionOptionsWireValue, err := fileIngestionOptionsToWire(v.FileIngestionOptions) + if err != nil { + return nil, fmt.Errorf("%s: %w", "OneDriveOptions.FileIngestionOptions", err) + } + return &oneDriveOptionsWire{ + Url: v.Url, + EntityType: v.EntityType, + FileIngestionOptions: fileIngestionOptionsWireValue, + }, nil +} + +func oneDriveOptionsFromWire(w *oneDriveOptionsWire) (*OneDriveOptions, error) { + if w == nil { + return nil, nil + } + fileIngestionOptionsPublicValue, err := fileIngestionOptionsFromWire(w.FileIngestionOptions) + if err != nil { + return nil, fmt.Errorf("%s: %w", "OneDriveOptions.FileIngestionOptions", err) + } + return &OneDriveOptions{ + Url: w.Url, + EntityType: w.EntityType, + FileIngestionOptions: fileIngestionOptionsPublicValue, + }, nil +} + type operationTimeWindowWire struct { StartHour *int `json:"start_hour,omitempty"` DaysOfWeek []DayOfWeek `json:"days_of_week,omitempty"` diff --git a/postgres/CHANGELOG.md b/postgres/CHANGELOG.md index 097c8456..1d486083 100644 --- a/postgres/CHANGELOG.md +++ b/postgres/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.6.0 (2026-10-22) + ## Release v0.5.0 (2026-10-14) ## Release v0.4.0 (2026-10-13) diff --git a/postgres/internal/version.go b/postgres/internal/version.go index 1d5e5682..ed33e142 100644 --- a/postgres/internal/version.go +++ b/postgres/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-postgres" -const Version = "0.5.0" +const Version = "0.6.0" diff --git a/postgres/v1/model.go b/postgres/v1/model.go index 138c28c6..84d18ddc 100644 --- a/postgres/v1/model.go +++ b/postgres/v1/model.go @@ -2339,8 +2339,7 @@ type SyncedTable struct { // The Unity Catalog table ID for this synced table. Uid *string // Configuration details of the synced table, such as the source table, - // scheduling policy, etc. This attribute is specified at creation time and most - // fields are returned as is on subsequent queries. + // scheduling policy, etc. Spec *SyncedTable_SyncedTableSpec // Synced Table data synchronization status. Status *SyncedTable_SyncedTableStatus diff --git a/sandbox/CHANGELOG.md b/sandbox/CHANGELOG.md index f7648057..c38ea0be 100644 --- a/sandbox/CHANGELOG.md +++ b/sandbox/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.5.0 (2026-10-22) + ## Release v0.4.0 (2026-10-19) ## Release v0.3.0 (2026-10-13) diff --git a/sandbox/internal/version.go b/sandbox/internal/version.go index 9d949234..14516cc9 100644 --- a/sandbox/internal/version.go +++ b/sandbox/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-sandbox" -const Version = "0.4.0" +const Version = "0.5.0" diff --git a/sandbox/v1/model.go b/sandbox/v1/model.go index f3508888..266d7258 100644 --- a/sandbox/v1/model.go +++ b/sandbox/v1/model.go @@ -106,9 +106,10 @@ type DeleteSandboxRequest struct { } type EnvironmentSpec struct { - // A Unity Catalog container artifact (e.g. `catalog.schema.folder.image:tag`) - // to run as the sandbox environment. When set, this image is used as the - // environment instead of resolving a managed image from `environment_version`. + // The Unity Catalog container image to use for the sandbox environment (for + // example, `catalog.schema.folder.image:tag`). See [Artifact Registry]. + // + // [Artifact Registry]: https://docs.databricks.com/en/artifact-registry/ ImageUri *string `fieldmask:"image_uri"` } diff --git a/vectorsearch/CHANGELOG.md b/vectorsearch/CHANGELOG.md index a29f9465..391a0fb2 100644 --- a/vectorsearch/CHANGELOG.md +++ b/vectorsearch/CHANGELOG.md @@ -1,5 +1,7 @@ # Version changelog +## Release v0.5.0 (2026-10-22) + ## Release v0.4.0 (2026-10-13) ## Release v0.3.0 (2026-10-09) diff --git a/vectorsearch/internal/version.go b/vectorsearch/internal/version.go index d28ea976..81beb75f 100644 --- a/vectorsearch/internal/version.go +++ b/vectorsearch/internal/version.go @@ -2,4 +2,4 @@ package internal const ModuleName = "sdk-go-vectorsearch" -const Version = "0.4.0" +const Version = "0.5.0" diff --git a/vectorsearch/v1/client.go b/vectorsearch/v1/client.go index 2e2d8e1d..5f6360bd 100644 --- a/vectorsearch/v1/client.go +++ b/vectorsearch/v1/client.go @@ -1273,6 +1273,155 @@ func (c *internalClient) ScanVectorIndex(ctx context.Context, req ScanVectorInde return resp, nil } +// Start a stopped endpoint. The endpoint serves the same indexes it had when it +// stopped. +func (c *internalClient) StartEndpoint(ctx context.Context, req StartEndpointRequest, opts ...call.Option) (*Endpoint, error) { + wireReq, err := startEndpointRequestToWire(&req) + if err != nil { + return nil, err + } + body, err := json.Marshal(wireReq) + if err != nil { + return nil, err + } + + headers := http.Header{} + headers.Set("Content-Type", "application/json") + if c.workspaceID != "" { + headers.Set("X-Databricks-Workspace-Id", c.workspaceID) + } + + baseURL, err := url.Parse(c.host) + if err != nil { + return nil, err + } + pb := pathBuilder{} + pb.literal("/api/2.0/vector-search/endpoints/") + if req.Name == nil { + return nil, fmt.Errorf("path parameter %q is required", "name") + } + pb.singleSegment(*req.Name) + pb.literal("/start") + baseURL.Path, baseURL.RawPath = pb.build() + queryParams := url.Values{} + baseURL.RawQuery = queryParams.Encode() + urlStr := baseURL.String() + + var resp *Endpoint + + call := func(ctx context.Context) error { + httpReq, err := newHTTPRequest(ctx, httpRequestOptions{ + Method: "POST", + URL: urlStr, + Credentials: c.credentials, + UserAgent: c.userAgent, + Headers: headers, + Body: bytes.NewBuffer(body), + }) + if err != nil { + return err + } + + respBody, _, err := executeHTTPCall(httpCallOptions{ + req: httpReq, + client: c.httpClient, + logger: c.logger, + }) + if err != nil { + return err + } + var wireResp endpointWire + if err := json.Unmarshal(respBody, &wireResp); err != nil { + return err + } + resp, err = endpointFromWire(&wireResp) + if err != nil { + return err + } + return nil + } + + if err := c.executeCall(ctx, call, opts); err != nil { + return nil, err + } + return resp, nil +} + +// Stop an endpoint. Stopping removes the endpoint's serving compute and retains +// its indexes. A stopped endpoint can't serve queries or sync indexes until it +// is started. +func (c *internalClient) StopEndpoint(ctx context.Context, req StopEndpointRequest, opts ...call.Option) (*Endpoint, error) { + wireReq, err := stopEndpointRequestToWire(&req) + if err != nil { + return nil, err + } + body, err := json.Marshal(wireReq) + if err != nil { + return nil, err + } + + headers := http.Header{} + headers.Set("Content-Type", "application/json") + if c.workspaceID != "" { + headers.Set("X-Databricks-Workspace-Id", c.workspaceID) + } + + baseURL, err := url.Parse(c.host) + if err != nil { + return nil, err + } + pb := pathBuilder{} + pb.literal("/api/2.0/vector-search/endpoints/") + if req.Name == nil { + return nil, fmt.Errorf("path parameter %q is required", "name") + } + pb.singleSegment(*req.Name) + pb.literal("/stop") + baseURL.Path, baseURL.RawPath = pb.build() + queryParams := url.Values{} + baseURL.RawQuery = queryParams.Encode() + urlStr := baseURL.String() + + var resp *Endpoint + + call := func(ctx context.Context) error { + httpReq, err := newHTTPRequest(ctx, httpRequestOptions{ + Method: "POST", + URL: urlStr, + Credentials: c.credentials, + UserAgent: c.userAgent, + Headers: headers, + Body: bytes.NewBuffer(body), + }) + if err != nil { + return err + } + + respBody, _, err := executeHTTPCall(httpCallOptions{ + req: httpReq, + client: c.httpClient, + logger: c.logger, + }) + if err != nil { + return err + } + var wireResp endpointWire + if err := json.Unmarshal(respBody, &wireResp); err != nil { + return err + } + resp, err = endpointFromWire(&wireResp) + if err != nil { + return err + } + return nil + } + + if err := c.executeCall(ctx, call, opts); err != nil { + return nil, err + } + return resp, nil +} + // Triggers a synchronization process for a specified vector index. func (c *internalClient) SyncVectorIndex(ctx context.Context, req SyncVectorIndexRequest, opts ...call.Option) (*SyncVectorIndexResponse, error) { wireReq, err := syncVectorIndexRequestToWire(&req) diff --git a/vectorsearch/v1/model.go b/vectorsearch/v1/model.go index 68f139fa..bcbce129 100644 --- a/vectorsearch/v1/model.go +++ b/vectorsearch/v1/model.go @@ -88,6 +88,12 @@ const ( // being cleaned up; once cleanup completes the endpoint will no longer be // retrievable. EndpointStatus_State_Deleted EndpointStatus_State = "DELETED" + // Serving compute is being removed. Indexes and their data are retained. + EndpointStatus_State_Stopping EndpointStatus_State = "STOPPING" + // The endpoint has no serving compute. Start it to serve queries again. + EndpointStatus_State_Stopped EndpointStatus_State = "STOPPED" + // Serving compute is being restored; the endpoint becomes ONLINE when ready. + EndpointStatus_State_Starting EndpointStatus_State = "STARTING" ) type ColumnInfo struct { @@ -648,6 +654,16 @@ type ScanVectorIndexResponse struct { LastPrimaryKey *string } +type StartEndpointRequest struct { + // Name of the AI Search endpoint + Name *string +} + +type StopEndpointRequest struct { + // Name of the AI Search endpoint + Name *string +} + type Struct struct { // Data entry, corresponding to a row in a vector index. Fields []MapStringValueEntry diff --git a/vectorsearch/v1/wire.go b/vectorsearch/v1/wire.go index 510e0d16..ab18e97a 100644 --- a/vectorsearch/v1/wire.go +++ b/vectorsearch/v1/wire.go @@ -1069,6 +1069,32 @@ func scanVectorIndexResponseFromWire(w *scanVectorIndexResponseWire) (*ScanVecto }, nil } +type startEndpointRequestWire struct { + Name *string `json:"name,omitempty"` +} + +func startEndpointRequestToWire(v *StartEndpointRequest) (*startEndpointRequestWire, error) { + if v == nil { + return nil, nil + } + return &startEndpointRequestWire{ + Name: v.Name, + }, nil +} + +type stopEndpointRequestWire struct { + Name *string `json:"name,omitempty"` +} + +func stopEndpointRequestToWire(v *StopEndpointRequest) (*stopEndpointRequestWire, error) { + if v == nil { + return nil, nil + } + return &stopEndpointRequestWire{ + Name: v.Name, + }, nil +} + type structWire struct { Fields []mapStringValueEntryWire `json:"fields,omitempty"` }