Skip to content

Commit

Permalink
fix(ingest/glue): add try catch (#12449)
Browse files Browse the repository at this point in the history
  • Loading branch information
anshbansal authored Jan 23, 2025
1 parent c4cc514 commit f4c0927
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions metadata-ingestion/src/datahub/ingestion/source/aws/glue.py
Original file line number Diff line number Diff line change
Expand Up @@ -738,11 +738,17 @@ def get_all_databases_and_tables(
self,
) -> Tuple[List[Mapping[str, Any]], List[Dict]]:
all_databases = [*self.get_all_databases()]
all_tables = [
tables
for database in all_databases
for tables in self.get_tables_from_database(database)
]
all_tables = []
for database in all_databases:
try:
for tables in self.get_tables_from_database(database):
all_tables.append(tables)
except Exception as e:
self.report.failure(
message="Failed to get tables from database",
context=database["Name"],
exc=e,
)
return all_databases, all_tables

def get_lineage_if_enabled(
Expand Down

0 comments on commit f4c0927

Please sign in to comment.