Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
fix(hive): fix table metadata and ignore partition table errs (#13306)
Azusain8a5985e7cfb6
diff --git a/backend/plugin/db/hive/sync.go b/backend/plugin/db/hive/sync.goindex a47057144d..d16d8bbeb8 100644--- a/backend/plugin/db/hive/sync.go+++ b/backend/plugin/db/hive/sync.go@@ -168,7 +168,9 @@ func (d *Driver) getTables(ctx context.Context, databaseName string) (case "MANAGED_TABLE":partitions, err := d.getPartitions(ctx, databaseName, tableName)if err != nil {- return nil, nil, nil, nil, err+ // Ignore partitions error as some tables aren't partitioned.+ slog.Debug("failed to get partitions", log.BBError(err))+ continue}tableMetadatas = append(tableMetadatas, &storepb.TableMetadata{Engine: "HDFS",@@ -271,6 +273,8 @@ func (d *Driver) getTableInfo(ctx context.Context, tableName string, databaseNam// The first rows are column metadata, followed by "# Detailed Table Information" and "# Storage Information"switch {+ case strings.HasPrefix(colName, "# col_name"):+ continuecase strings.HasPrefix(colName, "# Detailed Table Information"):section = tableInfoSectioncase strings.HasPrefix(colName, "# Storage Information"):