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

Ryan Blue commented on PARQUET-380:
-----------------------------------

When I add the dependency for libthrift, I get an error somewhere in cascading 
that there is no StaticLoggerBinder for SLF4J. That's an easy fix: add a binder 
like slf4j-nop or slf4j-simple. But, when I add slf4j-simple:1.7.5, I get:

{code}
SLF4J: The requested version 1.6.99 by your slf4j binding is not compatible 
with [1.5.5, 1.5.6, 1.5.7, 1.5.8]
. . .
java.lang.NoSuchMethodError: 
org.slf4j.helpers.MessageFormatter.format(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;
  at org.slf4j.impl.SimpleLogger.formatAndLog(SimpleLogger.java:414)
  at org.slf4j.impl.SimpleLogger.info(SimpleLogger.java:546)
{code}

The version of SLF4J that is pulled in by libthrift is too old to work with a 
new binding. But, using a slf4j-simple version that works with the older 
version of thrift causes failures in the hadoop-2 profile because Hadoop pulls 
in a version of SLF4J that isn't compatible with the older slf4j-simple. So the 
fix is to pull in the new version of both slf4j-api and slf4j-simple that 
matches the hadoop-2 verison. In the default profile, it overrides the 
transitive SLF4J dependency from libthrift and everything works. This is only 
needed for test dependencies, allowing downstream projects to use whatever 
version of the SLF4J API they need, which will override the old one in 
libthrift.

I've pushed a new version that should work, I'll commit it after CI tests pass.

> Cascading and scrooge builds fail when using thrift 0.9.0
> ---------------------------------------------------------
>
>                 Key: PARQUET-380
>                 URL: https://issues.apache.org/jira/browse/PARQUET-380
>             Project: Parquet
>          Issue Type: Bug
>          Components: parquet-mr
>    Affects Versions: 1.8.0
>            Reporter: Ryan Blue
>            Assignee: Ryan Blue
>             Fix For: 1.9.0
>
>
> This is caused by a transitive dependency on libthrift 0.7.0 from 
> elephantbird. The solution is to add thrift as an explicit (but provided) 
> dependency to those projects.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to