flink客户端提交任务报错

1. 通过flink 客户端提交任务 出现一下错误

2. 需要在flink 配置文件flink-conf.yaml中加入 参数就不会报错了

classloader.resolve-order: parent-first

{
“errors”: [
“org.apache.flink.runtime.rest.handler.RestHandlerException: Could not execute application.\n\tat org.apache.flink.runtime.webmonitor.handlers.JarRunHandler.lambda$handleRequestKaTeX parse error: Undefined control sequence: \n at position 26: …ndler.java:110)\̲n̲\tat java.util.…UniHandle.tryFire(CompletableFuture.java:797)\n\tat java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474)\n\tat java.util.concurrent.CompletableFutureKaTeX parse error: Undefined control sequence: \n at position 45: …ture.java:1595)\̲n̲\tat java.lang.…AsyncSupply.run(CompletableFuture.java:1592)\n\t… 1 more\nCaused by: org.apache.flink.util.FlinkRuntimeException: Could not execute application.\n\tat org.apache.flink.client.deployment.application.DetachedApplicationRunner.tryExecuteJobs(DetachedApplicationRunner.java:88)\n\tat org.apache.flink.client.deployment.application.DetachedApplicationRunner.run(DetachedApplicationRunner.java:70)\n\tat org.apache.flink.runtime.webmonitor.handlers.JarRunHandler.lambda$handleRequestKaTeX parse error: Undefined control sequence: \n at position 26: …ndler.java:104)\̲n̲\tat java.util.…AsyncSupply.run(CompletableFuture.java:1590)\n\t… 1 more\nCaused by: org.apache.flink.client.program.ProgramInvocationException: The main method caused an error: Unable to instantiate java compiler\n\tat org.apache.flink.client.program.PackagedProgram.callMainMethod(PackagedProgram.java:372)\n\tat org.apache.flink.client.program.PackagedProgram.invokeInteractiveModeForExecution(PackagedProgram.java:222)\n\tat org.apache.flink.client.ClientUtils.executeProgram(ClientUtils.java:114)\n\tat org.apache.flink.client.deployment.application.DetachedApplicationRunner.tryExecuteJobs(DetachedApplicationRunner.java:84)\n\t… 4 more\nCaused by: java.lang.IllegalStateException: Unable to instantiate java compiler\n\tat org.apache.calcite.rel.metadata.JaninoRelMetadataProvider.compile(JaninoRelMetadataProvider.java:428)\n\tat org.apache.calcite.rel.metadata.JaninoRelMetadataProvider.load3(JaninoRelMetadataProvider.java:374)\n\tat org.apache.calcite.rel.metadata.JaninoRelMetadataProvider.lambda$staticKaTeX parse error: Undefined control sequence: \n at position 38: …vider.java:109)\̲n̲\tat org.apache…FunctionToCacheLoader.load(CacheLoader.java:165)\n\tat org.apache.flink.calcite.shaded.com.google.common.cache.LocalCacheKaTeX parse error: Undefined control sequence: \n at position 55: …ache.java:3529)\̲n̲\tat org.apache…Segment.loadSync(LocalCache.java:2278)\n\tat org.apache.flink.calcite.shaded.com.google.common.cache.LocalCacheKaTeX parse error: Undefined control sequence: \n at position 46: …ache.java:2155)\̲n̲\tat org.apache…Segment.get(LocalCache.java:2045)\n\tat org.apache.flink.calcite.shaded.com.google.common.cache.LocalCache.get(LocalCache.java:3951)\n\tat org.apache.flink.calcite.shaded.com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:3974)\n\tat org.apache.flink.calcite.shaded.com.google.common.cache.LocalCacheKaTeX parse error: Undefined control sequence: \n at position 44: …ache.java:4958)\̲n̲\tat org.apache…ProjectReduceExpressionsRule.onMatch(ReduceExpressionsRule.java:303)\n\tat org.apache.calcite.plan.AbstractRelOptPlanner.fireRule(AbstractRelOptPlanner.java:333)\n\tat org.apache.calcite.plan.hep.HepPlanner.applyRule(HepPlanner.java:542)\n\tat org.apache.calcite.plan.hep.HepPlanner.applyRules(HepPlanner.java:407)\n\tat org.apache.calcite.plan.hep.HepPlanner.executeInstruction(HepPlanner.java:243)\n\tat org.apache.calcite.plan.hep.HepInstructionKaTeX parse error: Undefined control sequence: \n at position 46: …ction.java:127)\̲n̲\tat org.apache…anonfun$optimizeKaTeX parse error: Undefined control sequence: \n at position 32: …ogram.scala:62)\̲n̲\tat scala.coll…anonfun$foldLeftKaTeX parse error: Undefined control sequence: \n at position 29: …Once.scala:156)\̲n̲\tat scala.coll…anonfun$foldLeft 1 1 1adapted(TraversableOnce.scala:156)\n\tat scala.collection.Iterator.foreach(Iterator.scala:937)\n\tat scala.collection.Iterator.foreachKaTeX parse error: Undefined control sequence: \n at position 21: …ator.scala:937)\̲n̲\tat scala.coll…(IterableLike.scala:69)\n\tat scala.collection.AbstractIterable.foreach(Iterable.scala:54)\n\tat scala.collection.TraversableOnce.foldLeft(TraversableOnce.scala:156)\n\tat scala.collection.TraversableOnce.foldLeft$(TraversableOnce.scala:154)\n\tat scala.collection.AbstractTraversable.foldLeft(Traversable.scala:104)\n\tat org.apache.flink.table.planner.plan.optimize.program.FlinkChainedProgram.optimize(FlinkChainedProgram.scala:58)\n\tat org.apache.flink.table.planner.plan.optimize.StreamCommonSubGraphBasedOptimizer.optimizeTree(StreamCommonSubGraphBasedOptimizer.scala:161)\n\tat org.apache.flink.table.planner.plan.optimize.StreamCommonSubGraphBasedOptimizer.doOptimize(StreamCommonSubGraphBasedOptimizer.scala:79)\n\tat org.apache.flink.table.planner.plan.optimize.CommonSubGraphBasedOptimizer.optimize(CommonSubGraphBasedOptimizer.scala:77)\n\tat org.apache.flink.table.planner.delegation.PlannerBase.optimize(PlannerBase.scala:300)\n\tat org.apache.flink.table.planner.delegation.PlannerBase.translate(PlannerBase.scala:183)\n\tat org.apache.flink.table.api.bridge.java.internal.StreamTableEnvironmentImpl.toStreamInternal(StreamTableEnvironmentImpl.java:437)\n\tat org.apache.flink.table.api.bridge.java.internal.StreamTableEnvironmentImpl.toRetractStream(StreamTableEnvironmentImpl.java:539)\n\tat org.apache.flink.table.api.bridge.java.internal.StreamTableEnvironmentImpl.toRetractStream(StreamTableEnvironmentImpl.java:528)\n\tat com.wudl.flink.job.FlinkSqlMysqlToMySql.main(FlinkSqlMysqlToMySql.java:68)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)\n\tat sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)\n\tat sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)\n\tat java.lang.reflect.Method.invoke(Method.java:498)\n\tat org.apache.flink.client.program.PackagedProgram.callMainMethod(PackagedProgram.java:355)\n\t… 7 more\nCaused by: java.lang.ClassCastException: org.codehaus.janino.CompilerFactory cannot be cast to org.codehaus.commons.compiler.ICompilerFactory\n\tat org.codehaus.commons.compiler.CompilerFactoryFactory.getCompilerFactory(CompilerFactoryFactory.java:129)\n\tat org.codehaus.commons.compiler.CompilerFactoryFactory.getDefaultCompilerFactory(CompilerFactoryFactory.java:79)\n\tat org.apache.calcite.rel.metadata.JaninoRelMetadataProvider.compile(JaninoRelMetadataProvider.java:426)\n\t… 58 more\n”
]
}

你可能感兴趣的:(Flink,flink,apache,java)