-
Notifications
You must be signed in to change notification settings - Fork 134
Added support for UC catalogs (only in direct mode) #4342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
denik
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want auto-dependency injected between catalogs and schemas like we do for volumes-schemas?
Can you take a look at acceptance/bundle/resources/grants, should we have a test here?
|
|
||
| func (m *validateCatalogsOnlyWithDirect) Apply(ctx context.Context, b *bundle.Bundle) diag.Diagnostics { | ||
| // Catalogs are only supported in direct deployment mode | ||
| if !m.engine.IsDirect() && len(b.Config.Resources.Catalogs) > 0 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need this check? What happens without it?
We have TerraformToGroupName map, we should have a general handling of the case when you try to work with resource that is not registered there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but the error we get is not really user friendly and does not make it clear what;s going on
Error: no converter for resource type catalogs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we improve this error message? Then we don't need custom validators for each new direct-only resource.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make sense to make it generic but I'd rather keep it in a separate mutator which runs at plan step rather than failing way later at terraform.Write which is when plan is already running
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, early check makes sense.
|
Commit: ce3a055
17 interesting tests: 7 KNOWN, 5 SKIP, 4 RECOVERED, 1 FAIL
Top 50 slowest tests (at least 2 minutes):
|
Changes
Added support for UC catalogs (only in direct mode)
Why
Supporting UC catalogs is a natural conrinuation of DABs support for UC schemas.
Tests
Added acceptance test