[SPARK-44977][SPARK-46257][BUILD][CORE][SQL] Upgrade Derby to 10.16.1.1#44174
[SPARK-44977][SPARK-46257][BUILD][CORE][SQL] Upgrade Derby to 10.16.1.1#44174LuciferYang wants to merge 4 commits intoapache:masterfrom
Conversation
|
Test first. We can't upgrade to use 10.17.1.0 because its minimum supported Java 19. |
There was a problem hiding this comment.
Thank you for making an effort for this, @LuciferYang .
Although I filed SPARK-44977 Upgrade Derby to 10.15.1.3+, I didn't start.
|
Many test cases have failed. Let me investigate |
| </dependency> | ||
| <dependency> | ||
| <groupId>org.apache.derby</groupId> | ||
| <artifactId>derbytools</artifactId> |
There was a problem hiding this comment.
org.apache.derby.jdbc.EmbeddedDriver has been moved to derbytools in derby 10.16.11
| s"spark.sql.catalog.$catalogName.url=jdbc:derby:memory:$catalogName;create=true" | ||
| val catalogDriver = | ||
| s"spark.sql.catalog.$catalogName.driver=org.apache.derby.jdbc.AutoloadedDriver" | ||
| s"spark.sql.catalog.$catalogName.driver=org.apache.derby.iapi.jdbc.AutoloadedDriver" |
There was a problem hiding this comment.
AutoloadedDriver has been moved to a new package : org.apache.derby.iapi.jdbc.
| datasketches-memory/2.1.0//datasketches-memory-2.1.0.jar | ||
| derby/10.14.2.0//derby-10.14.2.0.jar | ||
| derby/10.16.1.1//derby-10.16.1.1.jar | ||
| derbyshared/10.16.1.1//derbyshared-10.16.1.1.jar |
There was a problem hiding this comment.
derbyshared is a transitive dependency of derby.
|
All test passed, I will update the PR description later. |
dongjoon-hyun
left a comment
There was a problem hiding this comment.
It's really nice to see the success. Thank you so much, @LuciferYang !
|
Merged into master for Spark 4.0. Thanks @dongjoon-hyun ~ |
|
Thank you so much, @LuciferYang . This was a headache for me really. |
|
Great work.. I hope that there soon will be a 10.16.2 that have a backport of https://issues.apache.org/jira/browse/DERBY-7147 This is a fix for CVE-2022-46337 witch have a score of 9.8 |
|
Go ahead, @bjornjorgensen . :) |
### What changes were proposed in this pull request? This PR aims to upgrade Derby from 10.14.2.0 to 10.16.1.1: 1. The version in `pom.xml` and related comments were updated. After the update, Spark added a dependency on the `org.apache.derby:derbyshared` module because it is a cascading dependency of `derby`. 2. Since `org.apache.derby.jdbc.EmbeddedDriver` has been moved to the `org.apache.derby:derbytools` module, the corresponding dependency was added to the project. 3. Since `org.apache.derby.jdbc.AutoloadedDriver` has been moved to `org.apache.derby.iapi.jdbc.AutoloadedDriver`, the corresponding test configuration in `o.a.spark.sql.hive.thriftserver.CliSuite` was modified. ### Why are the changes needed? Derby 10.16 release family [supports Java 17](https://issues.apache.org/jira/browse/DERBY-7137) and higher with JDBC 4.2, and this version [no longer supports the Java SecurityManager](https://issues.apache.org/jira/browse/DERBY-7138). The full release notes as follows: - https://db.apache.org/derby/releases/release-10_16_1_1.cgi ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? Pass GitHub Actions ### Was this patch authored or co-authored using generative AI tooling? No Closes apache#44174 from LuciferYang/SPARK-46257. Lead-authored-by: yangjie01 <yangjie01@baidu.com> Co-authored-by: YangJie <yangjie01@baidu.com> Signed-off-by: yangjie01 <yangjie01@baidu.com>
…park-3.5 Updated the advisory note to explain why Spark-3.5 cannot upgrade Derby from version 10.14.2.0 to 10.17.1.0 due to Java bytecode version incompatibility. The upstream project has updated to version 10.16.1.1, which does not resolve the vulnerability. The fix is planned with Derby version 10.16.2.x if it gets backported in Spark-4 or later. For more details, see: apache/spark#44174 Signed-off-by: debasishbsws <debasishbsws.dev@gmail.com>
…48hv (#8202) * Feat(adv): Fix not planed for GHSA-rcjc-c4pj-xxrp Derby component inspark-3.5 Updated the advisory note to explain why Spark-3.5 cannot upgrade Derby from version 10.14.2.0 to 10.17.1.0 due to Java bytecode version incompatibility. The upstream project has updated to version 10.16.1.1, which does not resolve the vulnerability. The fix is planned with Derby version 10.16.2.x if it gets backported in Spark-4 or later. For more details, see: apache/spark#44174 Signed-off-by: debasishbsws <debasishbsws.dev@gmail.com> * Feat(adv): Fix not planed for GHSA-c27h-mcmw-48hv because of dependency on hive 2.3 Spark has a transitive dependency on the unmaintained codehaus jackson-mapper-asl library due to Hive 2.3, which is required for initializing the FunctionRegistry. Hive 3.x, planned for Spark 4.x, should remove this dependency. However, any fix in Spark 4.x cannot be backported to Spark 3.5.x due to its reliance on Hive 2.3. Signed-off-by: debasishbsws <debasishbsws.dev@gmail.com> --------- Signed-off-by: debasishbsws <debasishbsws.dev@gmail.com>
…o 10.16.1.1 ### What changes were proposed in this pull request? This PR aims to upgrade Derby from 10.14.2.0 to 10.16.1.1: 1. The version in `pom.xml` and related comments were updated. After the update, Spark added a dependency on the `org.apache.derby:derbyshared` module because it is a cascading dependency of `derby`. 2. Since `org.apache.derby.jdbc.EmbeddedDriver` has been moved to the `org.apache.derby:derbytools` module, the corresponding dependency was added to the project. 3. Since `org.apache.derby.jdbc.AutoloadedDriver` has been moved to `org.apache.derby.iapi.jdbc.AutoloadedDriver`, the corresponding test configuration in `o.a.spark.sql.hive.thriftserver.CliSuite` was modified. ### Why are the changes needed? Derby 10.16 release family [supports Java 17](https://issues.apache.org/jira/browse/DERBY-7137) and higher with JDBC 4.2, and this version [no longer supports the Java SecurityManager](https://issues.apache.org/jira/browse/DERBY-7138). The full release notes as follows: - https://db.apache.org/derby/releases/release-10_16_1_1.cgi ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? Pass GitHub Actions ### Was this patch authored or co-authored using generative AI tooling? No Closes apache#44174 from LuciferYang/SPARK-46257. Lead-authored-by: yangjie01 <yangjie01@baidu.com> Co-authored-by: YangJie <yangjie01@baidu.com> Signed-off-by: yangjie01 <yangjie01@baidu.com>
…o 10.16.1.1 ### What changes were proposed in this pull request? This PR aims to upgrade Derby from 10.14.2.0 to 10.16.1.1: 1. The version in `pom.xml` and related comments were updated. After the update, Spark added a dependency on the `org.apache.derby:derbyshared` module because it is a cascading dependency of `derby`. 2. Since `org.apache.derby.jdbc.EmbeddedDriver` has been moved to the `org.apache.derby:derbytools` module, the corresponding dependency was added to the project. 3. Since `org.apache.derby.jdbc.AutoloadedDriver` has been moved to `org.apache.derby.iapi.jdbc.AutoloadedDriver`, the corresponding test configuration in `o.a.spark.sql.hive.thriftserver.CliSuite` was modified. ### Why are the changes needed? Derby 10.16 release family [supports Java 17](https://issues.apache.org/jira/browse/DERBY-7137) and higher with JDBC 4.2, and this version [no longer supports the Java SecurityManager](https://issues.apache.org/jira/browse/DERBY-7138). The full release notes as follows: - https://db.apache.org/derby/releases/release-10_16_1_1.cgi ### Does this PR introduce _any_ user-facing change? No ### How was this patch tested? Pass GitHub Actions ### Was this patch authored or co-authored using generative AI tooling? No Closes apache#44174 from LuciferYang/SPARK-46257. Lead-authored-by: yangjie01 <yangjie01@baidu.com> Co-authored-by: YangJie <yangjie01@baidu.com> Signed-off-by: yangjie01 <yangjie01@baidu.com>
What changes were proposed in this pull request?
This PR aims to upgrade Derby from 10.14.2.0 to 10.16.1.1:
pom.xmland related comments were updated. After the update, Spark added a dependency on theorg.apache.derby:derbysharedmodule because it is a cascading dependency ofderby.org.apache.derby.jdbc.EmbeddedDriverhas been moved to theorg.apache.derby:derbytoolsmodule, the corresponding dependency was added to the project.org.apache.derby.jdbc.AutoloadedDriverhas been moved toorg.apache.derby.iapi.jdbc.AutoloadedDriver, the corresponding test configuration ino.a.spark.sql.hive.thriftserver.CliSuitewas modified.Why are the changes needed?
Derby 10.16 release family supports Java 17 and higher with JDBC 4.2, and this version no longer supports the Java SecurityManager.
The full release notes as follows:
Does this PR introduce any user-facing change?
No
How was this patch tested?
Pass GitHub Actions
Was this patch authored or co-authored using generative AI tooling?
No