-
Notifications
You must be signed in to change notification settings - Fork 354
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
Exporter: track removed objects during the Emit
phase
#3554
Merged
+39
−24
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In the current implementation when TF resource data has `.id` set to empty string this means the following: * object doesn't exist on backend - common situation for jobs and DLT pipelines when dependencies are deleted. * Grants or Permissions are empty, so we don't need to generate a code for that. Right now, all such objects are tracked and reported individually via `Ignore` function, but not all objects have it. Also, for big exports, not necessary objects are polluting the internal state without any useful effect. The current PR checks if `.id` is empty during the `Emit` phase, adds them to the list of ignored objects (except permissions & grants), and don't propagate them to the internal state.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3554 +/- ##
=======================================
Coverage 82.66% 82.66%
=======================================
Files 184 184
Lines 18857 18856 -1
=======================================
Hits 15588 15588
- Misses 2351 2352 +1
+ Partials 918 916 -2
|
hectorcast-db
approved these changes
May 8, 2024
tanmay-db
added a commit
that referenced
this pull request
May 13, 2024
### New Features and Improvements * fix ([#3542](#3542)). * Update data_aws_crossaccount_policy to format resource string with account and region ([#3544](#3544)). * Robust retries for workspace get-status ([#3550](#3550)). * Fix error message typo in mounts.go ([#3552](#3552)). * State the options for run_if ([#3548](#3548)). * Exporter: don't emit all UC objects when handling dependencies ([#3556](#3556)). * Added state upgrader to remove `max_clusters_per_user` and ebs volume attributes set to zero ([#3551](#3551)). * Exporter: track removed objects during the `Emit` phase ([#3554](#3554)). * Jobs GoSDK schema migration ([#3532](#3532)). * Exporter: optimize generation of `databricks_group_member` resource ([#3559](#3559)). ### Documentation Changes ### Exporter ### Internal Changes
Merged
github-merge-queue bot
pushed a commit
that referenced
this pull request
May 14, 2024
* Release v1.43.0 ### New Features and Improvements * fix ([#3542](#3542)). * Update data_aws_crossaccount_policy to format resource string with account and region ([#3544](#3544)). * Robust retries for workspace get-status ([#3550](#3550)). * Fix error message typo in mounts.go ([#3552](#3552)). * State the options for run_if ([#3548](#3548)). * Exporter: don't emit all UC objects when handling dependencies ([#3556](#3556)). * Added state upgrader to remove `max_clusters_per_user` and ebs volume attributes set to zero ([#3551](#3551)). * Exporter: track removed objects during the `Emit` phase ([#3554](#3554)). * Jobs GoSDK schema migration ([#3532](#3532)). * Exporter: optimize generation of `databricks_group_member` resource ([#3559](#3559)). ### Documentation Changes ### Exporter ### Internal Changes * - * - * -
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
In the current implementation when TF resource data has
.id
set to an empty string this means the following:Right now, all such objects are tracked and reported individually via the
Ignore
function, but not all objects have it. Also, for big exports, unnecessary objects pollute the internal state without any useful effect.The current PR checks if
.id
is empty during theEmit
phase, adds them to the list of ignored objects (except permissions & grants), and doesn't propagate them to the internal state.Tests
make test
run locallydocs/
folderinternal/acceptance