-
Notifications
You must be signed in to change notification settings - Fork 368
[AMORO-3973] Support spark3.4 for mixed format #4013
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: master
Are you sure you want to change the base?
[AMORO-3973] Support spark3.4 for mixed format #4013
Conversation
| val schema = createSchema(transformClause.colTypeList) | ||
| val replacedSchema = CharVarcharUtils.replaceCharVarcharWithStringInSchema(schema) | ||
| (DataTypeUtils.toAttributes(replacedSchema), false) | ||
| (schema.toAttributes, false) |
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.
should be replacedSchema.toAttributes?
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.
I fix the code by deleting 'replacedSchema'
| } | ||
|
|
||
| def visitCommonSelectQueryClausePlan( | ||
| private def visitCommonSelectQueryClausePlan( |
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: necessary?
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.
fix up
| <include>org.apache.iceberg:iceberg-orc</include> | ||
| <include>org.apache.iceberg:iceberg-parquet</include> | ||
| <include>org.apache.iceberg:iceberg-aws</include> | ||
| <include>org.apache.iceberg:iceberg-aliyun</include> |
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 necessary for spark-3.5 as well?
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.
fix up
e2d8b8a to
c9082d4
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4013 +/- ##
============================================
+ Coverage 22.12% 22.85% +0.72%
- Complexity 2461 2531 +70
============================================
Files 445 449 +4
Lines 40897 41048 +151
Branches 5767 5784 +17
============================================
+ Hits 9050 9382 +332
+ Misses 31089 30857 -232
- Partials 758 809 +51
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
c9082d4 to
c549de1
Compare
| <artifactId>scala-compiler</artifactId> | ||
| <version>${scala.version}</version> | ||
| <scope>provided</scope> | ||
| </dependency> |
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.
why remove it?
If needed, you can remove it in separate PR for all spark-3.5, spark-3.4, spark-3.3
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.
do not remove the <scope>provided</scope> for spark-3.4, please keep it consistent for spark-3.5, spark-3.4, spark-3.3, and change it in separate PR if necessary.
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.
e5fcedd to
ffdaeb7
Compare
turboFei
left a comment
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.
LGTM
� Please enter the commit message for your changes. Lines starting � with '�' will be ignored, and an empty message aborts the commit. � � interactive rebase in progress; onto dd42830 � Last commands done (2 commands done): � pick 699f315 # Copy the code form spark3.5 � pick 701d7d5 # Optimize code � Next commands to do (2 remaining commands): � pick e2d8b8a # Optimize code � pick e5fcedd # Maintain consistency in the references to scala-compiler and scala-library across Spark 3.5, Spark 3.4, and Spark 3.3 � You are currently rebasing branch 'AMORO-add-Spark3.4-for-mixedFormat-dev' on 'dd428301a'. � � Changes to be committed: � renamed: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.5/pom.xml -> amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/pom.xml � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/gen-antlr/org/apache/amoro/spark/sql/parser/MixedFormatSqlExtendLexer.java � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/gen-antlr/org/apache/amoro/spark/sql/parser/MixedFormatSqlExtendParser.java � renamed: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.5/src/main/java/org/apache/amoro/spark/Spark35Adapter.java -> amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/java/org/apache/amoro/spark/Spark34Adapter.java � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/java/org/apache/amoro/spark/util/ExpressionHelper.java � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/analysis/QueryWithConstraintCheck.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/analysis/RewriteMixedFormatMergeIntoTable.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/optimize/RewriteAppendMixedFormatTable.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/optimize/RewriteDeleteFromMixedFormatTable.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/optimize/RewriteUpdateMixedFormatTable.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/amoro/spark/sql/catalyst/plans/UnresolvedMergeIntoMixedFormatTable.scala � renamed: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/spark/sql/amoro/catalyst/MixedFormatSpark35Helper.scala -> amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/spark/sql/amoro/catalyst/MixedFormatSpark34Helper.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/spark/sql/amoro/parser/MixedFormatSqlExtendAstBuilder.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/main/scala/org/apache/spark/sql/catalyst/analysis/MixedFormatAssignmentAlignmentSupport.scala � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/test/java/org/apache/amoro/spark/test/suites/sql/TestMergeIntoSQL.java � modified: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-3.4/src/test/java/org/apache/amoro/spark/test/suites/ut/sql/parser/TestSqlExtendParser.java � renamed: amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-runtime-3.5/pom.xml -> amoro-format-mixed/amoro-mixed-spark/v3.4/amoro-mixed-spark-runtime-3.4/pom.xml � modified: pom.xml �
…brary across Spark 3.5, Spark 3.4, and Spark 3.3
8b19bc4 to
9dffec2
Compare
|
@xxubai Would you be able to review this pr when you have a moment? I'd be most grateful. |

Why are the changes needed?
Close #3973.
Brief change log
How was this patch tested?
Add some test cases that check the changes thoroughly including negative and positive cases if possible
Add screenshots for manual tests if appropriate
Run test locally before making a pull request
Documentation