Testing flink class loading

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Testing flink class loading

James Isaac
I am trying to run the ClassLoaderTestProgram on flink.

1. I have started Flink in local mode with the following command:
      bin/jobmanager.sh start local

2. I ran the  ClassLoaderTestProgram  jar:
       bin/flink run ClassLoaderTestProgram.jar --resolve-first child --output out.txt

I get a  java.lang.NoSuchMethodError: org.apache.flink.runtime.taskmanager.TaskManager.getMessage when I run with child-first, and I get the output when I run it in parent-first mode.

The documentation states that "we get a {@link NoSuchMethodError} if we're running with {@code parent-first} class loading
  and that we get the correct result from the method when we're running with {@code child-first} class loading."

Am I doing something wrong here?

Regards,
James
Reply | Threaded
Open this post in threaded view
|

Re: Testing flink class loading

Aljoscha Krettek
Hi,

You can take a look at test-infra/end-to-end-test/test_streaming_classloader.sh to see how that testing job is used in the actual test.

Best,
Aljoscha

On 6. Feb 2018, at 07:55, Data Engineer <[hidden email]> wrote:

I am trying to run the ClassLoaderTestProgram on flink.

1. I have started Flink in local mode with the following command:
      bin/jobmanager.sh start local

2. I ran the  ClassLoaderTestProgram  jar:
       bin/flink run ClassLoaderTestProgram.jar --resolve-first child --output out.txt

I get a  java.lang.NoSuchMethodError: org.apache.flink.runtime.taskmanager.TaskManager.getMessage when I run with child-first, and I get the output when I run it in parent-first mode.

The documentation states that "we get a {@link NoSuchMethodError} if we're running with {@code parent-first} class loading
  and that we get the correct result from the method when we're running with {@code child-first} class loading."

Am I doing something wrong here?

Regards,
James