1996fanrui commented on code in PR #1738:
URL:
https://github.com/apache/incubator-streampark/pull/1738#discussion_r988954912
##########
streampark-flink/streampark-flink-proxy/src/main/scala/org/apache/streampark/flink/proxy/FlinkShimsProxy.scala:
##########
@@ -88,10 +88,17 @@ object FlinkShimsProxy extends Logger {
SHIMS_CLASS_LOADER_CACHE.getOrElseUpdate(s"${flinkVersion.fullVersion}", {
// 1) flink/lib
- val libURL = getFlinkHomeLib(flinkVersion.flinkHome)
- val shimsUrls = ListBuffer[URL](libURL: _*)
+ def filterLib(filterLib: File): Boolean = {
+ !(filterLib.getName.startsWith("log4j") ||
filterLib.getName.startsWith("flink-table-planner-loader"))
Review Comment:
Why add the `filterLib.getName.startsWith("flink-table-planner-loader"))`?
##########
streampark-flink/streampark-flink-proxy/src/main/scala/org/apache/streampark/flink/proxy/FlinkShimsProxy.scala:
##########
@@ -88,10 +88,17 @@ object FlinkShimsProxy extends Logger {
SHIMS_CLASS_LOADER_CACHE.getOrElseUpdate(s"${flinkVersion.fullVersion}", {
// 1) flink/lib
- val libURL = getFlinkHomeLib(flinkVersion.flinkHome)
- val shimsUrls = ListBuffer[URL](libURL: _*)
+ def filterLib(filterLib: File): Boolean = {
+ !(filterLib.getName.startsWith("log4j") ||
filterLib.getName.startsWith("flink-table-planner-loader"))
+ }
- // 2) shims jar
+ val libURL = getFlinkHomeLib(flinkVersion.flinkHome, "lib", filterLib)
+ // 2) After version 1.15 need add flink/opt/flink-table-planner*
+ val getFlinkTablePlanner: File => Boolean =
_.getName.startsWith("flink-table-planner")
+ val optURL = getFlinkHomeLib(flinkVersion.flinkHome, "opt",
getFlinkTablePlanner)
Review Comment:
The optURL just includes `opt/flink-table-planner*`, so the name should be
changed to `tablePlannerURL`?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]