[CT-3527] [implementation] extend access and groups to exposures & source
- Dominant language
- Rust
- Stars
- 13.8k
- Forks
- 2.6k
- Avg merge
- 21h 31m
- Merged PRs (30d)
- 56
Description
### Housekeeping
- [X] I am a maintainer of dbt-core
### Short description
From the discussion [here](https://github.com/dbt-labs/dbt-core/issues/7750)...
We should extend `group` configurations to all resource types. The current outstanding ones are `sources` and `exposures`:
- exposures should be able to reference models within the same group
- sources should be able to be private to a given group
We should also enable `sources` to configure `access` to `private` or `protected` (default). We **should not** allow folks to set `access` to `public` for `sources`.
### Acceptance criteria
- [ ] you can set `group` config for an exposure
- [ ] you can set `group` config for a source
- [ ] you can set `access` to `private` or `protected` (default) for a source
- [ ] you can **not** set `access` for an exposure (they are inherently public)
As described [here](https://docs.getdbt.com/reference/resource-configs/access#definition), referencing a resource outside of its supported access should raise an error (but otherwise should not).
### Impact to Other Teams
none
### Will backports be required?
none
### Context
Notes from technical refinement:
- would allow folks to set this for the source, and also for a specific table within a source
- it's a config (enabled is the only one right now https://docs.getdbt.com/reference/source-configs), may be more complicated
- alt approach discussed [here](https://github.com/dbt-labs/dbt-core/issues/12212) and [here](https://github.com/dbt-labs/dbt-core/issues/10132#issuecomment-2107432551)
Contributor guide
Assessment
This issue has not been assessed yet.