-
Notifications
You must be signed in to change notification settings - Fork 14
Adding AWS Glue connector code #33
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
| for job in page['Jobs']: | ||
| job_name = job['Name'] | ||
| # Optimization: Limit to latest run to reduce API calls | ||
| job_runs = self.__glue_client.get_job_runs(JobName=job_name, MaxResults=1) |
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.
Is it guaranteed to return the latest run?
| job_runs = self.__glue_client.get_job_runs(JobName=job_name, MaxResults=1) | ||
|
|
||
| for job_run in job_runs.get('JobRuns', []): | ||
| if job_run.get('JobRunState') == 'SUCCEEDED': |
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.
Is it possible to filter the jobs fetched in get_job_runs to only return jobs which 'SUCCEEDED'?
| graph = self.__glue_client.get_dataflow_graph(PythonScript=script_location) | ||
| if graph: | ||
| sources = [edge['Source'] for edge in graph.get('Edges', [])] |
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.
It's assumed that the i-th element in sources corresponds to the i-th element in targets, representing a directed edge from source to target. Is this assumption reasonable? Please add a comment for the same.
| return "OTHER" | ||
|
|
||
| def build_database_entry(config, db_name): | ||
| """Builds a database entry, mimicking the successful Oracle format.""" |
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.
nit: Remove such comments.
| @@ -0,0 +1,93 @@ | |||
| # AWS Glue to Google Cloud Dataplex Connector | |||
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.
Please include following info:
- Metadata extracted: example https://github.com/GoogleCloudPlatform/cloud-dataplex/tree/main/managed-connectivity/community-contributed-connectors/oracle-connector#target-objects-and-schemas
- How to fetch AWS credentials if non-trivial
- What resources need to be created in the project for import: example https://github.com/GoogleCloudPlatform/cloud-dataplex/tree/main/managed-connectivity/community-contributed-connectors/oracle-connector#target-objects-and-schemas
- Docker setup: https://github.com/GoogleCloudPlatform/cloud-dataplex/tree/main/managed-connectivity/community-contributed-connectors/oracle-connector#target-objects-and-schemas
Added code for AWS Glue to Dataplex connector code