Skip to content

Databricks: add SQL endpoint operators #21377

Closed

Description

@dinowernli

Description

Operators to manipulate Databricks SQL endpoints.

Use case/motivation

Support conveniently managing the lifecycle of Databricks SQL endpoints. This likely entails building one or more operators which talk to the endpoints API and support:

  • Creating endpoints
  • Deleting endpoints
  • Starting endpoints
  • Stopping endpoints

These operations map cleanly to individual API calls.

Related issues

No response

Are you willing to submit a PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Activity

  1. changed the title [-]Databricks: add endpoint CRUD operators[/-] [+]Databricks: add SQL endpoint operators[/+] on Feb 7, 2022
  2. besenthil commented on Feb 8, 2022

    @besenthil

    @dinowernli

    Would the function _handle_databricks_operator_execution be applicable for API endpoints which are not ASYNC like the creation of sql endpoint?

  3. dinowernli commented on Feb 8, 2022

    @dinowernli
    Author

    Right now, the logic in that function is specific to the kind of operators defined in the same file, i.e., to operators which create runs. I think something similar would be useful for other operators, but it would likely have to operate on the status of a query execution or similar (rather than the state of a job run).

  4. besenthil commented on Feb 8, 2022

    @besenthil

    Thanks @dinowernli I will take a look at it.

  5. besenthil commented on Feb 13, 2022

    @besenthil

    @dinowernli

    Is there a test stub that I can use for testing the API call?

  6. alexott commented on Feb 14, 2022

    @alexott
    Contributor

    @besenthil we don't have stubs for testing, so you need to have access to a workspace with Dataricks SQL, plus corresponding permissions to create SQL Endpoints.

    From implementation perspective, you need to use _do_api_call function - first POST definition of SQL Endpoint, and then check for it's status. Please note that request will fail if you submit an endpoint with the same name, so you will need to check it (I have a code for that in PR for Databricks SQL Operator)

  7. besenthil commented on Feb 19, 2022

    @besenthil

    Thanks @alexott

  8. alexott commented on Feb 27, 2022

    @alexott
    Contributor

    @besenthil is implementation in progress, or you need an additional help with it?

  9. besenthil commented on Feb 28, 2022

    @besenthil
  10. adam133 commented on Aug 22, 2023

    @adam133

    Found this as part of debugging another issue... Databricks renamed the sql/endpoints API to sql/warehouses: https://docs.databricks.com/api/workspace/warehouses/list
    The "list endpoints" endpoint no longer exists that's referenced here:

    LIST_SQL_ENDPOINTS_ENDPOINT = ("GET", "api/2.0/sql/endpoints")

  11. wojkam73159 commented on Nov 26, 2023

    @wojkam73159

    Hi, is this issue is still open?

  12. potiuk commented on Nov 29, 2023

    @potiuk
    Member

    Hi, is this issue is still open?

    Nothing says otherwise

  13. Vamsi-klu commented on Jul 19, 2026

    @Vamsi-klu
  14. eladkal commented on Sep 25, 2026

    @eladkal
    Contributor

    cc @moomindani can you please check this feature request and let us know if still relevant from Databricks point of view?

  15. moomindani commented on Sep 30, 2026

    @moomindani
    Contributor

    Start/stop is already covered: DatabricksStartWarehouseOperator and DatabricksStopWarehouseOperator (#70088), with deferrable mode (#71752). That is the part of this request that belongs inside a Dag run.

    I would leave create/delete/edit out of scope. A SQL warehouse is long-lived shared infrastructure that is usually managed declaratively (Terraform or bundles), and auto-stop already covers the cost concern that creating and deleting one per run would address. My suggestion is to close this as completed by #70088 and #71752, and to open a new, narrower issue if someone has a concrete use case for create/delete or looking a warehouse up by name.


    Drafted-by: Claude Code (Opus 5.5); reviewed by @moomindani before posting

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions