hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gopal V (JIRA)" <>
Subject [jira] [Commented] (HIVE-13015) Bundle Log4j2 jars with hive-exec
Date Thu, 18 Feb 2016 05:25:18 GMT


Gopal V commented on HIVE-13015:

I thought so too, but transitive dependencies are pulled for compile, but not for shading
- wasn't getting them in the hive-exec shader.

Was getting

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/logging/log4j/spi/LoggerAdapter
	at java.lang.Class.getDeclaredConstructors0(Native Method)
	at java.lang.Class.privateGetDeclaredConstructors(
	at java.lang.Class.getConstructor0(
	at java.lang.Class.newInstance(
	at org.apache.commons.logging.LogFactory.createFactory(
	at org.apache.commons.logging.LogFactory$
	at Method)
	at org.apache.commons.logging.LogFactory.newFactory(
	at org.apache.commons.logging.LogFactory.getFactory(
	at org.apache.commons.logging.LogFactory.getLog(
	at org.apache.hadoop.service.AbstractService.<clinit>(
Caused by: java.lang.ClassNotFoundException: org.apache.logging.log4j.spi.LoggerAdapter
	at java.lang.ClassLoader.loadClass(
	at sun.misc.Launcher$AppClassLoader.loadClass(
	at java.lang.ClassLoader.loadClass(
	... 11 more

> Bundle Log4j2 jars with hive-exec
> ---------------------------------
>                 Key: HIVE-13015
>                 URL:
>             Project: Hive
>          Issue Type: Bug
>    Affects Versions: 2.1.0
>            Reporter: Prasanth Jayachandran
>            Assignee: Gopal V
>         Attachments: HIVE-13015.1.patch, HIVE-13015.1.patch, HIVE-13015.2.patch, HIVE-13015.3.patch
> In some of the recent test runs, we are seeing multiple bindings for SLF4j that causes
issues with LOG4j2 logger. 
> {code}
> SLF4J: Found binding in [jar:file:/grid/0/hadoop/yarn/local/usercache/hrt_qa/appcache/application_1454694331819_0001/container_e06_1454694331819_0001_01_000002/app/install/lib/slf4j-log4j12-1.7.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
> {code}
> We have added explicit exclusions for slf4j-log4j12 but some library is pulling it transitively
and it's getting packaged with hive libs. Also hive currently uses version 1.7.5 for slf4j.
We should add dependency convergence for sl4fj and also remove packaging of slf4j-log4j12.*.jar

This message was sent by Atlassian JIRA

View raw message