You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@parquet.apache.org by "Gabor Szadovszky (Jira)" <ji...@apache.org> on 2021/07/16 09:02:00 UTC

[jira] [Commented] (PARQUET-2065) parquet-cli not working in release 1.12.0

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

Gabor Szadovszky commented on PARQUET-2065:
-------------------------------------------

I've checked this with 1.11.0 and is reproducible so not a regression in 1.12.0.

The problem is that in target there are multiple parquet-cli jars are generated. One is a slim jar (parquet-cli-1.12.0.jar) and another one is a fat jar (parquet-cli-1.12.0-runtime.jar) that contains the avro dependency shaded. If all of these jars put on the classpath (target/*) it can mix up things. So, I would suggest using one specific jar file from the listed ones instead of putting all jars on the classpath from target. The other dependency jars are required.
For example:
{code}
java -cp target/parquet-cli-1.12.0.jar:target/dependency/* org.apache.parquet.cli.Main head <parquet file>
{code}

> parquet-cli not working in release 1.12.0
> -----------------------------------------
>
>                 Key: PARQUET-2065
>                 URL: https://issues.apache.org/jira/browse/PARQUET-2065
>             Project: Parquet
>          Issue Type: Bug
>          Components: parquet-cli
>    Affects Versions: 1.12.0
>            Reporter: Akshay Sundarraj
>            Priority: Major
>
> When I run parquet-cli getting  java.lang.NoSuchMethodError
> Steps to repdouce:
>  # Download parquet-mr 1.12.0 from [https://github.com/apache/parquet-mr/archive/refs/tags/apache-parquet-1.12.0.tar.gz]
>  # Build and install using mvn clean install
>  # cd parquet-cli
>  # {{mvn dependency:copy-dependencies}}
>  # {{java -cp 'target/*:target/dependency/*' org.apache.parquet.cli.Main head <parquet file>}}
>  # Got below exception
> WARNING: An illegal reflective access operation has occurred
>  WARNING: Illegal reflective access by org.apache.hadoop.security.authentication.util.KerberosUtil ([file:/home/amsundar/hgroot/parquet-mr-apache-parquet-1.12.0/parquet-cli/target/dependency/hadoop-auth-2.10.1.jar|file://home/amsundar/hgroot/parquet-mr-apache-parquet-1.12.0/parquet-cli/target/dependency/hadoop-auth-2.10.1.jar]) to method sun.security.krb5.Config.getInstance()
>  WARNING: Please consider reporting this to the maintainers of org.apache.hadoop.security.authentication.util.KerberosUtil
>  WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
>  WARNING: All illegal access operations will be denied in a future release
>  Exception in thread "main" java.lang.NoSuchMethodError: org.apache.parquet.avro.AvroSchemaConverter.convert(Lorg/apache/parquet/schema/MessageType;)Lorg/apache/avro/Schema;
>  at org.apache.parquet.cli.util.Schemas.fromParquet(Schemas.java:89)
>  at org.apache.parquet.cli.BaseCommand.getAvroSchema(BaseCommand.java:405)
>  at org.apache.parquet.cli.commands.CatCommand.run(CatCommand.java:66)
>  at org.apache.parquet.cli.Main.run(Main.java:155)
>  at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:76)
>  at org.apache.parquet.cli.Main.main(Main.java:185)
>  
>  



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