LiJie20190102 commented on code in PR #10431:
URL: https://github.com/apache/seatunnel/pull/10431#discussion_r2757150725


##########
seatunnel-engine/seatunnel-engine-core/src/main/java/org/apache/seatunnel/engine/core/classloader/DefaultClassLoaderService.java:
##########
@@ -91,8 +97,8 @@ public synchronized ClassLoader getClassLoader(long jobId, 
Collection<URL> jars)
             } else {
                 log.debug("Run the test class without file checking");
             }
-            ClassLoader classLoader = new SeaTunnelChildFirstClassLoader(jars);
-            log.info("Create classloader for job {} with jars {}", jobId, 
jars);
+            ClassLoader classLoader = new 
SeaTunnelChildFirstClassLoader(resolvedJars);
+            log.info("Create classloader for job {} with resolvedJars {}", 
jobId, resolvedJars);

Review Comment:
   Thanks for the question. In my implementation I intentionally work on a copy 
and keep the original collection unchanged, to avoid side effects if the 
original set is shared or reused elsewhere. resolvedJars is only used in this 
local flow and is not written back to the original jars , so the copy is still 
useful for isolation. If we can guarantee the collection is not shared, we 
could resolve in-place, but I prefer minimizing side effects.



-- 
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]

Reply via email to