-
Notifications
You must be signed in to change notification settings - Fork 420
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
fix: snowpipe error integration #2227
Conversation
Hey @sonya. Thanks for the contribution! We will review it in the upcoming days. cc: @sfc-gh-jcieslak @scottwinkler |
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.
Thanks for contributing, looks good to me 👍
@@ -56,6 +56,7 @@ type PipeSet struct { | |||
} | |||
|
|||
type PipeUnset struct { | |||
ErrorIntegration *bool `ddl:"keyword" sql:"ERROR_INTEGRATION"` |
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.
Quick question: documentation does not list ErrorIntegration as a possible value for UNSET https://docs.snowflake.com/en/sql-reference/sql/alter-pipe#parameters. I guess that this is an error in the docs, right?
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.
Yeah, I checked it and it works
/ok-to-test sha=3c8f11d1fb023894a04dd4e696fe61f446d0db3b |
Integration tests failure for 3c8f11d1fb023894a04dd4e696fe61f446d0db3b |
This PR fixes a bug where setting
error_integration
on asnowflake_pipe
resource would cause the name of the integration to be written to the comment field on the pipe instead of the error integration. A separate bug prevented theerror_integration
diffs from being detected if an SNS topic was set.Test Plan
I tested this using an existing stack where I have many pipes. I made an earnest attempt to update
pipes_integration_test.go
, but I reached the point where I needed a real SNS topic and decided that was beyond the timebox I set for this.Using version 0.76.0:
comment
but noerror_integration
error_integration
to the terraform config.describe pipe
on the updated pipes in Snowflake. The comments now contained the name of the notification integration, whereaserror_integration
was null.describe pipe
on the updated pipes in Snowflake. The comments were back to their previous value, buterror_integration
was still null.error_integration
from the terraform config.describe pipe
on the updated pipes in Snowflake. The comments were now blank.Using the modified provider
comment
but noerror_integration
error_integration
to the terraform config.describe pipe
on the updated pipes in Snowflake. The comments were unchanged and error integrations were set to the expected value.error_integration
from the terraform configdescribe pipe
on the updated pipes in Snowflake. The comments were unchanged, and error integrations were null.References
I initially started to file a bug report, but during investigation I figured out how to fix it so I'm opening a PR instead. Let me know if this isn't the right process