-
Notifications
You must be signed in to change notification settings - Fork 1k
Refactor template to avoid using session file for type info #2529
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
Conversation
49e10db
to
78e6291
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2529 +/- ##
============================================
- Coverage 49.73% 49.71% -0.03%
- Complexity 4822 5179 +357
============================================
Files 948 948
Lines 57938 58038 +100
Branches 6259 6275 +16
============================================
+ Hits 28818 28853 +35
- Misses 27070 27123 +53
- Partials 2050 2062 +12
🚀 New features to boost your workflow:
|
7ce8030
to
6cd4f20
Compare
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.
This changes are very spread out and hard to quantify or review because of the fan out. It would be cleaner to introduce an interface and swap between session file and alternates. It will keep the implementation and testing clean
...-common/src/main/java/com/google/cloud/teleport/v2/spanner/migrations/utils/SchemaUtils.java
Outdated
Show resolved
Hide resolved
...-common/src/main/java/com/google/cloud/teleport/v2/spanner/migrations/utils/SchemaUtils.java
Outdated
Show resolved
Hide resolved
...nner-to-sourcedb/src/main/java/com/google/cloud/teleport/v2/templates/SpannerToSourceDb.java
Outdated
Show resolved
Hide resolved
...-common/src/main/java/com/google/cloud/teleport/v2/spanner/migrations/utils/SchemaUtils.java
Outdated
Show resolved
Hide resolved
...-common/src/main/java/com/google/cloud/teleport/v2/spanner/migrations/utils/SchemaUtils.java
Outdated
Show resolved
Hide resolved
...-common/src/main/java/com/google/cloud/teleport/v2/spanner/migrations/utils/SchemaUtils.java
Outdated
Show resolved
Hide resolved
...nner-to-sourcedb/src/main/java/com/google/cloud/teleport/v2/templates/SpannerToSourceDb.java
Outdated
Show resolved
Hide resolved
.../src/main/java/com/google/cloud/teleport/v2/templates/dbutils/dml/CassandraDMLGenerator.java
Outdated
Show resolved
Hide resolved
.../src/main/java/com/google/cloud/teleport/v2/templates/dbutils/dml/CassandraDMLGenerator.java
Show resolved
Hide resolved
...cedb/src/main/java/com/google/cloud/teleport/v2/templates/dbutils/dml/MySQLDMLGenerator.java
Show resolved
Hide resolved
...cedb/src/main/java/com/google/cloud/teleport/v2/templates/dbutils/dml/MySQLDMLGenerator.java
Show resolved
Hide resolved
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.
Approving as an intermediate PR before the interface changes are merged to simplify this code.
This PR refactors the reverse template to avoid using session file for anything other than table/column name-mappings. It instead relies of the Ddl and SourceDdl object for schema specific info. This refactoring is necessary to introduce the schemamapper and henceforth, overrides.