[jira] [Comment Edited] (FLINK-9220) Table program cannot be compiled

2018-06-13 Thread Timo Walther (JIRA)


[ 
https://issues.apache.org/jira/browse/FLINK-9220?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16511014#comment-16511014
 ] 

Timo Walther edited comment on FLINK-9220 at 6/13/18 12:05 PM:
---

I tried different configurations to reproduce this error but all of them could 
not cause an error. I created two UDFs in different packages one in the job jar 
and one in a toolbox jar.

I tried the following classpath configuration in the job jar:
{code}
table  toolbox
provided  provided -> OK
provided  compile -> OK
compile  provided -> FAILS (but might be acceptable, could not find 
{{flink-table}})
compile  compile -> OK
{code}

[~fhueske] you also had this error once right? What was your configuration?


was (Author: twalthr):
I tried different configurations to reproduce this error but all of them could 
not cause an error. I created two UDFs in different packages one in the job jar 
and one in a toolbox jar.

I tried the following classpath configuration in the job jar:
{code}
table  toolbox
provided  provided -> OK
provided  compile -> OK
compile  provided -> FAILS (but might be acceptable, could not find 
{{flink-table}})
compile  compile -> OK
{code}

> Table program cannot be compiled
> 
>
> Key: FLINK-9220
> URL: https://issues.apache.org/jira/browse/FLINK-9220
> Project: Flink
>  Issue Type: Bug
>Reporter: Saurabh Garg
>Assignee: Timo Walther
>Priority: Major
>
> Flink job gets failed with scalar UDF. I am using Flink 1.4. Issue came with 
> Scalar UDF
> Below is the error logs:
>  
> org.apache.flink.api.common.InvalidProgramException: Table program cannot be 
> compiled. This is a bug. Please file an issue. at 
> org.apache.flink.table.codegen.Compiler$class.compile(Compiler.scala:36) at 
> org.apache.flink.table.runtime.CRowProcessRunner.compile(CRowProcessRunner.scala:35)
>  at 
> org.apache.flink.table.runtime.CRowProcessRunner.open(CRowProcessRunner.scala:49)
>  at 
> org.apache.flink.api.common.functions.util.FunctionUtils.openFunction(FunctionUtils.java:36)
>  at 
> org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.open(AbstractUdfStreamOperator.java:102)
>  at 
> org.apache.flink.streaming.api.operators.ProcessOperator.open(ProcessOperator.java:56)
>  at 
> org.apache.flink.streaming.runtime.tasks.StreamTask.openAllOperators(StreamTask.java:393)
>  at 
> org.apache.flink.streaming.runtime.tasks.StreamTask.invoke(StreamTask.java:254)
>  at org.apache.flink.runtime.taskmanager.Task.run(Task.java:718) at 
> java.lang.Thread.run(Thread.java:748) Caused by: 
> org.codehaus.commons.compiler.CompileException: Line 6, Column 18: Cannot 
> determine simple type name "com" at 
> org.codehaus.janino.UnitCompiler.compileError(UnitCompiler.java:11672) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6416) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6177) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6156) at 
> org.codehaus.janino.UnitCompiler.access$13300(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$18$1.visitReferenceType(UnitCompiler.java:6064)
>  at 
> org.codehaus.janino.UnitCompiler$18$1.visitReferenceType(UnitCompiler.java:6059)
>  at org.codehaus.janino.Java$ReferenceType.accept(Java.java:3754) at 
> org.codehaus.janino.UnitCompiler$18.visitType(UnitCompiler.java:6059) at 
> org.codehaus.janino.UnitCompiler$18.visitType(UnitCompiler.java:6052) at 
> org.codehaus.janino.Java$ReferenceType.accept(Java.java:3753) at 
> org.codehaus.janino.UnitCompiler.getType(UnitCompiler.java:6052) at 
> org.codehaus.janino.UnitCompiler.access$1200(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$21.getType(UnitCompiler.java:7844) at 
> org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6456) at 
> org.codehaus.janino.UnitCompiler.access$13800(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$18$2$1.visitFieldAccess(UnitCompiler.java:6082)
>  at 
> org.codehaus.janino.UnitCompiler$18$2$1.visitFieldAccess(UnitCompiler.java:6077)
>  at org.codehaus.janino.Java$FieldAccess.accept(Java.java:4136) at 
> org.codehaus.janino.UnitCompiler$18$2.visitLvalue(UnitCompiler.java:6077) at 
> org.codehaus.janino.UnitCompiler$18$2.visitLvalue(UnitCompiler.java:6073) at 
> org.codehaus.janino.Java$Lvalue.accept(Java.java:3974) at 
> org.codehaus.janino.UnitCompiler$18.visitRvalue(UnitCompiler.java:6073) at 
> 

[jira] [Comment Edited] (FLINK-9220) Table program cannot be compiled

2018-06-12 Thread Rakesh Chalasani (JIRA)


[ 
https://issues.apache.org/jira/browse/FLINK-9220?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16509729#comment-16509729
 ] 

Rakesh Chalasani edited comment on FLINK-9220 at 6/12/18 3:09 PM:
--

Posting from the user mailing list, one possible way to reproduce this issue:
 # Define UDF in module, say in com.udf 
 # Create a topology using the above UDF in another module, say in org.test, 
 and start execution in org.test. 

Only tested in locally, providing udfs as part of the jars on remote execution 
could still work.


was (Author: rakeshchalasani):
Posting from the user mailing list, one possible way to reproduce this issue:

1. Define UDF in module, say in com.udf 
2. Create a topology using the above UDF in another module, say in org.test, 
and start execution in org.test. 

> Table program cannot be compiled
> 
>
> Key: FLINK-9220
> URL: https://issues.apache.org/jira/browse/FLINK-9220
> Project: Flink
>  Issue Type: Bug
>Reporter: Saurabh Garg
>Priority: Major
>
> Flink job gets failed with scalar UDF. I am using Flink 1.4. Issue came with 
> Scalar UDF
> Below is the error logs:
>  
> org.apache.flink.api.common.InvalidProgramException: Table program cannot be 
> compiled. This is a bug. Please file an issue. at 
> org.apache.flink.table.codegen.Compiler$class.compile(Compiler.scala:36) at 
> org.apache.flink.table.runtime.CRowProcessRunner.compile(CRowProcessRunner.scala:35)
>  at 
> org.apache.flink.table.runtime.CRowProcessRunner.open(CRowProcessRunner.scala:49)
>  at 
> org.apache.flink.api.common.functions.util.FunctionUtils.openFunction(FunctionUtils.java:36)
>  at 
> org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.open(AbstractUdfStreamOperator.java:102)
>  at 
> org.apache.flink.streaming.api.operators.ProcessOperator.open(ProcessOperator.java:56)
>  at 
> org.apache.flink.streaming.runtime.tasks.StreamTask.openAllOperators(StreamTask.java:393)
>  at 
> org.apache.flink.streaming.runtime.tasks.StreamTask.invoke(StreamTask.java:254)
>  at org.apache.flink.runtime.taskmanager.Task.run(Task.java:718) at 
> java.lang.Thread.run(Thread.java:748) Caused by: 
> org.codehaus.commons.compiler.CompileException: Line 6, Column 18: Cannot 
> determine simple type name "com" at 
> org.codehaus.janino.UnitCompiler.compileError(UnitCompiler.java:11672) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6416) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6177) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getReferenceType(UnitCompiler.java:6190) at 
> org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6156) at 
> org.codehaus.janino.UnitCompiler.access$13300(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$18$1.visitReferenceType(UnitCompiler.java:6064)
>  at 
> org.codehaus.janino.UnitCompiler$18$1.visitReferenceType(UnitCompiler.java:6059)
>  at org.codehaus.janino.Java$ReferenceType.accept(Java.java:3754) at 
> org.codehaus.janino.UnitCompiler$18.visitType(UnitCompiler.java:6059) at 
> org.codehaus.janino.UnitCompiler$18.visitType(UnitCompiler.java:6052) at 
> org.codehaus.janino.Java$ReferenceType.accept(Java.java:3753) at 
> org.codehaus.janino.UnitCompiler.getType(UnitCompiler.java:6052) at 
> org.codehaus.janino.UnitCompiler.access$1200(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$21.getType(UnitCompiler.java:7844) at 
> org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6456) at 
> org.codehaus.janino.UnitCompiler.access$13800(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$18$2$1.visitFieldAccess(UnitCompiler.java:6082)
>  at 
> org.codehaus.janino.UnitCompiler$18$2$1.visitFieldAccess(UnitCompiler.java:6077)
>  at org.codehaus.janino.Java$FieldAccess.accept(Java.java:4136) at 
> org.codehaus.janino.UnitCompiler$18$2.visitLvalue(UnitCompiler.java:6077) at 
> org.codehaus.janino.UnitCompiler$18$2.visitLvalue(UnitCompiler.java:6073) at 
> org.codehaus.janino.Java$Lvalue.accept(Java.java:3974) at 
> org.codehaus.janino.UnitCompiler$18.visitRvalue(UnitCompiler.java:6073) at 
> org.codehaus.janino.UnitCompiler$18.visitRvalue(UnitCompiler.java:6052) at 
> org.codehaus.janino.Java$Rvalue.accept(Java.java:3942) at 
> org.codehaus.janino.UnitCompiler.getType(UnitCompiler.java:6052) at 
> org.codehaus.janino.UnitCompiler.getType2(UnitCompiler.java:6438) at 
> org.codehaus.janino.UnitCompiler.access$13600(UnitCompiler.java:212) at 
> org.codehaus.janino.UnitCompiler$18$2$1.visitAmbiguousName(UnitCompiler.java:6080)
>  at 
>