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

Jiayi Liao commented on FLINK-14849:
------------------------------------

I've come across the same issue and it took me really a lot of time to deal 
with the dependency conflicts between hive-metastore/exec repo and flink repo, 
which ends successfully like this (using hive 1.2.3):

{code:java}
<!-- Hive Metastore -->
<dependency>
        <groupId>org.apache.hive</groupId>
        <artifactId>hive-metastore</artifactId>
        <version>1.2.3</version>
        <exclusions>
                <exclusion>
                        <groupId>org.apache.hadoop</groupId>
                        <artifactId>*</artifactId>
                </exclusion>
                <exclusion>
                        <groupId>commons-cli</groupId>
                        <artifactId>*</artifactId>
                </exclusion>
        </exclusions>
</dependency>

<dependency>
        <groupId>org.apache.hive</groupId>
        <artifactId>hive-exec</artifactId>
        <version>1.2.3</version>
        <exclusions>
                <exclusion>
                        <groupId>commons-cli</groupId>
                        <artifactId>*</artifactId>
                </exclusion>
                <exclusion>
                        <groupId>com.google</groupId>
                        <artifactId>*</artifactId>
                </exclusion>
                <exclusion>
                        <groupId>org.apache.calcite</groupId>
                        <artifactId>*</artifactId>
                </exclusion>
        </exclusions>
</dependency>
{code}

Moreover, I have to deal with a special dependency called {{datanucleus}} when 
using a single fat jar for my job.


> Can not submit job when use hive connector
> ------------------------------------------
>
>                 Key: FLINK-14849
>                 URL: https://issues.apache.org/jira/browse/FLINK-14849
>             Project: Flink
>          Issue Type: Bug
>          Components: Connectors / Hive
>            Reporter: Jingsong Lee
>            Priority: Major
>
> {code:java}
> With:
> <dependency>
>     <groupId>org.apache.hive</groupId>
>     <artifactId>hive-exec</artifactId>
>     <version>3.1.1</version>
> </dependency>
> Caused by: java.lang.ClassCastException: org.codehaus.janino.CompilerFactory 
> cannot be cast to org.codehaus.commons.compiler.ICompilerFactory
>       at 
> org.codehaus.commons.compiler.CompilerFactoryFactory.getCompilerFactory(CompilerFactoryFactory.java:129)
>       at 
> org.codehaus.commons.compiler.CompilerFactoryFactory.getDefaultCompilerFactory(CompilerFactoryFactory.java:79)
>       at 
> org.apache.calcite.rel.metadata.JaninoRelMetadataProvider.compile(JaninoRelMetadataProvider.java:432)
>       ... 68 more
> {code}
> After https://issues.apache.org/jira/browse/FLINK-13749 , flink-client will 
> use default child-first resolve-order.
> If user jar has some conflict dependents, there will be some problem.
> Maybe we should update document to add some exclusions to hive dependents.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to