-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Add MetadataFeed support to Dataplex #16631
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
Open
MingyanZhao
wants to merge
1
commit into
GoogleCloudPlatform:main
Choose a base branch
from
MingyanZhao:feature/metadatafeed
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,135 @@ | ||
| --- | ||
| name: 'MetadataFeed' | ||
| description: | | ||
| A Metadata Feed represents a metadata feed in Dataplex. | ||
| docs: | ||
| base_url: 'projects/{{project}}/locations/{{location}}/metadataFeeds/{{metadata_feed_id}}' | ||
| self_link: 'projects/{{project}}/locations/{{location}}/metadataFeeds/{{metadata_feed_id}}' | ||
| create_url: 'projects/{{project}}/locations/{{location}}/metadataFeeds?metadataFeedId={{metadata_feed_id}}' | ||
| update_verb: 'PATCH' | ||
| update_mask: true | ||
| import_format: | ||
| - 'projects/{{project}}/locations/{{location}}/metadataFeeds/{{metadata_feed_id}}' | ||
| timeouts: | ||
| insert_minutes: 5 | ||
| update_minutes: 5 | ||
| delete_minutes: 5 | ||
| autogen_async: true | ||
| async: | ||
| actions: ['create', 'delete', 'update'] | ||
| type: 'OpAsync' | ||
| operation: | ||
| base_url: '{{op_id}}' | ||
| timeouts: | ||
| insert_minutes: 5 | ||
| update_minutes: 5 | ||
| delete_minutes: 5 | ||
| result: | ||
| resource_inside_response: false | ||
| iam_policy: | ||
| exclude_import_test: true | ||
| method_name_separator: ':' | ||
| parent_resource_attribute: 'metadata_feed_id' | ||
| import_format: | ||
| - 'projects/{{project}}/locations/{{location}}/metadataFeeds/{{metadata_feed_id}}' | ||
| - '{{metadata_feed_id}}' | ||
| custom_code: | ||
| examples: | ||
| - name: 'dataplex_metadata_feed_basic' | ||
| primary_resource_id: 'test_metadata_feed' | ||
| vars: | ||
| metadata_feed_id: 'metadata-feed-basic' | ||
| test_env_vars: | ||
| project_name: 'PROJECT_NAME' | ||
| parameters: | ||
| - name: 'location' | ||
| type: String | ||
| description: | | ||
| The location where metadata feed will be created in. | ||
| url_param_only: true | ||
| immutable: true | ||
| - name: 'metadataFeedId' | ||
| type: String | ||
| description: | | ||
| The metadata feed id of the metadata feed. | ||
| url_param_only: true | ||
| immutable: true | ||
| properties: | ||
| - name: 'name' | ||
| type: String | ||
| description: | | ||
| The relative resource name of the MetadataFeed, of the form: projects/{project_number}/locations/{location_id}/metadataFeeds/{metadata_feed_id} | ||
| output: true | ||
| - name: 'uid' | ||
| type: String | ||
| description: | | ||
| System generated globally unique ID for the MetadataFeed. This ID will be different if the MetadataFeed is deleted and re-created with the same name. | ||
| output: true | ||
| - name: 'createTime' | ||
| type: Time | ||
| description: | | ||
| The time when the MetadataFeed was created. | ||
| output: true | ||
| - name: 'updateTime' | ||
| type: Time | ||
| description: | | ||
| The time when the MetadataFeed was last updated. | ||
| output: true | ||
| - name: 'labels' | ||
| type: KeyValueLabels | ||
| description: | | ||
| User-defined labels for the MetadataFeed. | ||
| - name: 'scope' | ||
| type: NestedObject | ||
| description: | | ||
| Scope defines the scope of the metadata feed. | ||
| required: true | ||
| properties: | ||
| - name: 'organizationLevel' | ||
| type: Boolean | ||
| description: | | ||
| Whether the metadata feed is at the organization-level. | ||
| - name: 'projects' | ||
| type: Array | ||
| item_type: | ||
| type: String | ||
| description: | | ||
| The projects whose entries you want to listen to. Must be in the same organization as the feed. Must be in the format: projects/{project_id_or_number}. | ||
| - name: 'entryGroups' | ||
| type: Array | ||
| item_type: | ||
| type: String | ||
| description: | | ||
| The entry groups whose entries you want to listen to. Must be in the format: projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}. | ||
| - name: 'filters' | ||
| type: NestedObject | ||
| description: | | ||
| Filters defines the type of changes that you want to listen to. | ||
| properties: | ||
| - name: 'entryTypes' | ||
| type: Array | ||
| item_type: | ||
| type: String | ||
| description: | | ||
| The entry types that you want to listen to. | ||
| - name: 'aspectTypes' | ||
| type: Array | ||
| item_type: | ||
| type: String | ||
| description: | | ||
| The aspect types that you want to listen to. | ||
| - name: 'changeTypes' | ||
| type: Array | ||
| item_type: | ||
| type: Enum | ||
| enum_values: | ||
| - 'CHANGE_TYPE_UNSPECIFIED' | ||
| - 'CREATE' | ||
| - 'UPDATE' | ||
| - 'DELETE' | ||
| description: | | ||
| The type of change that you want to listen to. | ||
| - name: 'pubsubTopic' | ||
| type: String | ||
| description: | | ||
| The pubsub topic that you want the metadata feed messages to publish to. | ||
9 changes: 9 additions & 0 deletions
9
mmv1/templates/terraform/examples/dataplex_metadata_feed_basic.tf.tmpl
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| resource "google_dataplex_metadata_feed" "{{$.PrimaryResourceId}}" { | ||
| metadata_feed_id = "{{index $.Vars "metadata_feed_id"}}" | ||
| project = "{{index $.TestEnvVars "project_name"}}" | ||
| location = "us-central1" | ||
| description = "Example metadata feed" | ||
| scope { | ||
| organization_level = true | ||
| } | ||
| } |
Oops, something went wrong.
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.
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.
I see this is updatable, can we add an update test?