kill warning:Class path contains multiple SLF4J bindings.

Description

When run idempiere server, has warning:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [bundleresource://170.fwk1519877292:1/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [bundleresource://170.fwk1519877292:2/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.JDK14LoggerFactory]

reason:
current slf4j-jdk14-1.7.2.jar and slf4j.api has difference version (slf4j.api is 1.7.2.xxxxx)
it make issue relate symbolic name of slf4j.api
current work-around make fragment project org.slf4j.jdk14 for wrapper.

update: above reason is incorrect, true reason is has jcl and jdk14 in class path.
just remove jcl for resolve this issue.
but I still change to achieve slf4j* from maven for always get latest version and sync together

this solution let slf4j-jdk14 load multiple time.
long time before i debug and see:
+ jetty load this api with build-in (of jetty) default properties and
+ a other plug-in load with default properties of slf4j framework

solution:
materialize slf4j.api and org.slf4j.jdk14 at same place (maven) to always get same version.

note: because rmap is update, to test must re-materialize

Environment

None

Activity

Show:
Hiep Lq
May 7, 2015, 8:15 AM

with feedback from orbit contributor, i can understand root cause.

"We have a naming policy that we follow for Orbit bundles. That's why it's different."

so get all slf* library from maven is correct solution.
also, keep all slf* same version is advice from slf.

Hiep Lq
May 7, 2015, 8:19 AM

hi , resolution again switch to fixed, i do nothing, just edit ticket, don't touch resolution field.

i resolution field is invisible in quick edit dialog, so i sure i can't touch it.
but when i make it visible i see default value is fixed maybe it's reason.
(hope idempiere hasn't same issue )

Carlos Ruiz
May 7, 2015, 4:46 PM
Carlos Ruiz
September 2, 2018, 10:44 AM

Hi , I see this is still happening in default branch - but I was not able to apply the proposed patch there.

Can you please check for a patch for actual default branch?

Hiep Lq
October 12, 2018, 1:15 PM

fixed by commit 03331a7f43f4

Assignee

Unassigned

Reporter

Hiep Lq

Labels

Tested By

None

Components

Affects versions

Priority

Minor
Configure