Skip to content

Commit

Permalink
Fix UI for when cross-account tables are setup manually (#390)
Browse files Browse the repository at this point in the history
* Fix UI

* Update dependencies and create release

* Fix main template
  • Loading branch information
matteofigus authored Nov 13, 2023
1 parent 0fde843 commit fb907d3
Show file tree
Hide file tree
Showing 5 changed files with 2,658 additions and 5,251 deletions.
7 changes: 6 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
# Change Log

## v0.64 (unreleased)
## v0.64

- [#390](https://github.com/awslabs/amazon-s3-find-and-forget/issues/390):
Upgrade frontend dependencies and fix bug affecting Create Data Mapper UI with
manually created Glue Tables
- [#389](https://github.com/awslabs/amazon-s3-find-and-forget/issues/389):
Upgrade backend dependencies
- [#387](https://github.com/awslabs/amazon-s3-find-and-forget/issues/387):
Upgrade frontend dependencies
- [#386](https://github.com/awslabs/amazon-s3-find-and-forget/issues/386):
Expand Down
22 changes: 21 additions & 1 deletion frontend/src/__tests__/glueSerializer.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,25 @@ const jsonTable = tableMaker({
}
});

const crossAccountTable = {
Name: "cross-account-table",
DatabaseName: "cross-account-db",
Description: "",
Owner: "",
Retention: 0,
ViewOriginalText: "",
ViewExpandedText: "",
TableType: "",
CreatedBy: "",
IsRegisteredWithLakeFormation: false,
TargetTable: {
CatalogId: "1234567890",
DatabaseName: "linkedDB",
Name: "linkedTable"
},
CatalogId: "9876543210"
};

const complexColumnsTable = tableMaker({
dbname: "db4",
tablename: "complex",
Expand Down Expand Up @@ -123,7 +142,8 @@ test("it should serialize dbs and tables", () => {
{ TableList: [] },
{ TableList: [table1, table2] },
{ TableList: [table3, jsonTable] },
{ TableList: [complexColumnsTable] }
{ TableList: [complexColumnsTable] },
{ TableList: [crossAccountTable] }
])
).toMatchSnapshot();
});
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/utils/glueSerializer.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ export const glueSerializer = tables => {
tables.forEach(table => {
const supportedTables = table.TableList.filter(x =>
[JSON_HIVE_SERDE, JSON_OPENX_SERDE, PARQUET_SERDE].includes(
x.StorageDescriptor.SerdeInfo.SerializationLibrary
x.StorageDescriptor?.SerdeInfo.SerializationLibrary
)
);

Expand Down
Loading

0 comments on commit fb907d3

Please sign in to comment.