I am trying to submit job to the hazelcast cluster and facing NoClassDefFoundError exception for the dependencies even though I have kept the dependencies in custom-lib directory and adding the jar file to job config using JobConfig.addCustomClasspath("Jar file name").
Is it right expectation to use JobConfig.addCustomClassPath() for loading classes for a particular pipeline from custom path or it has some different purpose?
I am able to submit the Job using UBER jar but was trying to figure out alternative to have dependent jars loaded from cluster instead of serializing them to hazelcast every time I create a new job.
I tried to copy the dependent jars to the custom-lib directory and add the jar file to the JobConfig.addCustomClasspath() and when the Jet job is submitted NoClassDefFoundError is raised on the cluster.
I have checked the class loaders used for deserializing the classes is JetClassLoader and for the custom-lib jar it uses ChildFirstClassLoader(extends URLClassLoader).
I am using same stage name for source and addCustomClasspath.