[
https://issues.apache.org/jira/browse/BEAM-5495?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16778165#comment-16778165
]
Maximilian Michels commented on BEAM-5495:
------------------------------------------
Just came across this. I agree, it's broken and doesn't work for Java 9 at all:
{noformat}
[grpc-default-executor-0] ERROR
org.apache.beam.runners.fnexecution.jobsubmission.InMemoryJobService -
Encountered Unexpected Exception for Preparation
job_5546448a-04ae-4d94-8e68-1b692b1e35eb
java.lang.IllegalArgumentException: Unable to use ClassLoader to detect
classpath elements. Current ClassLoader is
jdk.internal.loader.ClassLoaders$AppClassLoader@4f8e5cde, only URLClassLoaders
are supported.
at
org.apache.beam.runners.core.construction.PipelineResources.detectClassPathResourcesToStage(PipelineResources.java:57)
at
org.apache.beam.runners.flink.FlinkJobInvoker.invoke(FlinkJobInvoker.java:95)
at
org.apache.beam.runners.fnexecution.jobsubmission.InMemoryJobService.run(InMemoryJobService.java:179)
at
org.apache.beam.model.jobmanagement.v1.JobServiceGrpc$MethodHandlers.invoke(JobServiceGrpc.java:681)
at
...
{noformat}
> PipelineResources algorithm is not working in most environments
> ---------------------------------------------------------------
>
> Key: BEAM-5495
> URL: https://issues.apache.org/jira/browse/BEAM-5495
> Project: Beam
> Issue Type: Bug
> Components: runner-spark
> Reporter: Romain Manni-Bucau
> Assignee: Amit Sela
> Priority: Major
> Labels: triaged
>
> Issue are:
> 1. it assumes the classloader is an URLClassLoader (not always true and java
> >= 9 breaks that as well for the app loader)
> 2. it uses loader.getURLs() which leads to including the JRE itself in the
> staged file
> Looks like this detect resource algorithm can't work and should be replaced
> by a SPI rather than a built-in and not extensible algorithm. Another valid
> alternative is to just drop that "guess" logic and force the user to set
> staged files.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)