Commit Graph

13 Commits

Author SHA1 Message Date
Pieter Noordhuis 41539f97f3
Support lookup by name of notification destinations 2024-11-20 23:57:33 +01:00
Pieter Noordhuis e8e89b0cbf
Move and comment 2024-11-20 23:24:03 +01:00
Pieter Noordhuis 354d765833
Rename types and add tests 2024-11-20 23:12:16 +01:00
Pieter Noordhuis ed62d0821c
Remove from codegen 2024-11-20 22:54:52 +01:00
Pieter Noordhuis 488a1fbb67
Finalize 2024-11-20 22:53:24 +01:00
Pieter Noordhuis 7a99df58ec
No need for pointers to the lookup structs 2024-11-20 22:46:07 +01:00
Pieter Noordhuis 16cd2de149
WIP 2024-11-20 22:40:43 +01:00
Pieter Noordhuis 1f8f85982d
WIP 2024-11-20 22:40:33 +01:00
Andrew Nester 02e83877f4
Added listing cluster filtering for cluster lookups (#1754)
## Changes
We added a custom resolver for the cluster to add filtering for the
cluster source when we list all clusters.

Without the filtering listing could take a very long time (5-10 mins)
which leads to lookup timeouts.

## Tests
Existing unit tests passing
2024-09-06 11:34:57 +00:00
Andrew Nester 54799a1918
Upgrade Go SDK to 0.44.0 (#1679)
## Changes
Upgrade Go SDK to 0.44.0

---------

Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
2024-08-15 13:23:07 +00:00
Andrew Nester 09d1846e13
Return `application_id` for service principal lookups (#1245)
## Changes
Return ApplicationId for service principals lookups

Fixes #1234 

## Tests
Added (regression) tests
2024-03-04 16:12:10 +00:00
Andrew Nester 4b01fff03d
Fixed instance pool resolving by name (#1102)
## Changes
Fixed instance pool resolving by name

## Tests
Added regression test
2024-01-05 10:50:53 +00:00
Andrew Nester 5fb40f9d07
Allow referencing bundle resources by name (#872)
## Changes
Now we can define variables with values which reference different
Databricks resources by name.
When references like this, DABs automatically looks up the resource by
this name and replaces the reference with ID of the resource referenced.
Thus when the variable is used in the configuration it will contain the
correct resolved ID of resource.

The resolvers are code generated and thus DABs support referencing all
resources which has `GetByName`-like methods in Go SDK.

### Example

```
variables:
  my_cluster_id:
    description: An existing cluster.
    lookup: 
      cluster: "12.2 shared"

resources:
  jobs:
    my_job:
      name: "My Job"
      tasks:
        - task_key: TestTask
          existing_cluster_id: ${var.my_cluster_id}

targets:
  dev:
    variables:
      my_cluster_id:
        lookup: 
           cluster: "dev-cluster"
```

## Tests
Added unit test + manual testing

---------

Co-authored-by: shreyas-goenka <88374338+shreyas-goenka@users.noreply.github.com>
2024-01-04 21:04:42 +00:00