[jacorb-developer] JacORB and SLF dependency (was Re: JacORb in maven repository)

Nick Cross jacorb at goots.org
Thu Jun 7 15:30:59 CEST 2012


Hi,

Thanks for the reply. So, its not specifically to do with the version of 
Java (5/6/7) versus the slf4j-binding adapter.

I presume you must also be supplying slf4j-api version 1.5 as well? From 
the explanation at http://www.slf4j.org/codes.html#version_mismatch
  it would appear that there is an underlying conflict. Have you tried 
simply replacing all slf4j libraries with the 1.5 versions?

I think SLF4J would emit a warning multiple bindings on the classpath? 
e.g. slf4j-log4j12-1.5.10.jar and slf4j-jdk14-1.6.4.jar ?

As the -api and -jdk14 libs need to be paired, while it might be 
possible to support a range of 1.6.x I don't think SLF4J would allow 
much leeway here. Also, I am not convinced the provided scope is quite 
correct for this - normally SLF4J is required and is not provided hence 
the dependency.

Thanks

Nick



On 07/06/12 14:08, Timothy Astle wrote:
> Sure. SLF has various logger bindings from how I understand it. As the
> application developer, they must choose what logging implementation that
> SLF will use and provide that connector. Options include: JULI, log4j,
> logback, etc. The reason is because if someone wrote an application
> based on log4j, they'd want the 3rd party component to use the same
> logging configuration.
>
> We already have a binding provided in our application. What's trickier
> is that we also have an older version of SLF. Then we updated to JacORB
> 3 and it provided the JULI binding. Below you can see what happens when
> I launch the web application with both bindings in place and using an
> older SLF.
>
> [WARNING] [talledLocalContainer] Jun 07, 2012 9:51:04 AM
> org.apache.catalina.startup.HostConfig deployWAR
> [WARNING] [talledLocalContainer] INFO: Deploying web application archive
> D:\Work\myapp\target\cargo\configurations\tomcat7x\webapps\myapp.war
> [WARNING] [talledLocalContainer] SLF4J: The requested version 1.6 by
> your slf4j binding is not compatible with [1.5.5, 1.5.6, 1.5.7, 1.5.8,
> 1.5.9, 1.5.10]
> [WARNING] [talledLocalContainer] SLF4J: See
> http://www.slf4j.org/codes.html#version_mismatch for further details.
> [WARNING] [talledLocalContainer] SLF4J: Class path contains multiple
> SLF4J bindings.
> [WARNING] [talledLocalContainer] SLF4J: Found binding in
> [jar:file:/D:/Work/myapp/target/cargo/configurations/tomcat7x/webapps/spatialfusionviewer/WEB-INF/lib/slf4j-jdk14-1.6.4.jar!/org/slf4j/impl/StaticLoggerBind
> [WARNING] [talledLocalContainer] SLF4J: Found binding in
> [jar:file:/D:/Work/myapp/target/cargo/configurations/tomcat7x/webapps/spatialfusionviewer/WEB-INF/lib/slf4j-log4j12-1.5.10.jar!/org/slf4j/impl/StaticLoggerB
> [WARNING] [talledLocalContainer] SLF4J: See
> http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
> [WARNING] [talledLocalContainer] Jun 07, 2012 9:51:17 AM
> org.apache.catalina.core.StandardContext listenerStart
> [WARNING] [talledLocalContainer] SEVERE: Exception sending context
> initialized event to listener instance of class
> org.apache.struts2.tiles.StrutsTilesListener
> [WARNING] [talledLocalContainer] java.lang.AbstractMethodError:
> org.slf4j.impl.JDK14LoggerAdapter.log(Lorg/slf4j/Marker;Ljava/lang/String;ILjava/lang/String;Ljava/lang/Throwable;)V
> [WARNING] [talledLocalContainer] at
> org.apache.commons.logging.impl.SLF4JLocationAwareLog.info(SLF4JLocationAwareLog.java:120)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.impl.BasicTilesContainer.init(BasicTilesContainer.java:125)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.factory.TilesContainerFactory.initializeContainer(TilesContainerFactory.java:232)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.factory.TilesContainerFactory.createTilesContainer(TilesContainerFactory.java:198)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.factory.TilesContainerFactory.createContainer(TilesContainerFactory.java:163)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.web.startup.TilesListener.createContainer(TilesListener.java:90)
> [WARNING] [talledLocalContainer] at
> org.apache.struts2.tiles.StrutsTilesListener.createContainer(StrutsTilesListener.java:68)
> [WARNING] [talledLocalContainer] at
> org.apache.tiles.web.startup.TilesListener.contextInitialized(TilesListener.java:57)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4779)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5273)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:962)
> [WARNING] [talledLocalContainer] at
> org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1603)
> [WARNING] [talledLocalContainer] at
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
> [WARNING] [talledLocalContainer] at
> java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
> [WARNING] [talledLocalContainer] at
> java.util.concurrent.FutureTask.run(FutureTask.java:166)
> [WARNING] [talledLocalContainer] at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> [WARNING] [talledLocalContainer] at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> [WARNING] [talledLocalContainer] at java.lang.Thread.run(Thread.java:722)
>
> I didn't spend much time on thinking of the best way to go forward, but
> maybe it could involve:
> 1. Consider supporting a range of revisions of SLF?
> 2. Consider changing the scope of the slf4j-jdk14 to provided?
>
> Cheers!
>
>
> Tim
>
> On 07/06/2012 9:19 AM, Nick Cross wrote:
>>
>> Hi,
>>
>> Thanks for letting us know it works :-)
>>
>> Can you clarify your statement about slf4j please? According to
>> http://www.slf4j.org/manual.html, slf4j-jdk14-1.6.5.jar (the most
>> recent release) is the binding for java.util.logging.
>>
>> Regards
>>
>> Nick
>>
>>
>>
>> On 07/06/12 12:45, Timothy Astle wrote:
>>> In case there is any doubt, it works fine for me. You just have to
>>> declare the following if you need the IDL compiler and JacORB itself.
>>>
>>> <!-- JACORB and related dependencies. -->
>>> <dependency>
>>> <groupId>org.jacorb</groupId>
>>> <artifactId>jacorb</artifactId>
>>> <version>3.0</version>
>>> </dependency>
>>> <dependency>
>>> <groupId>org.jacorb</groupId>
>>> <artifactId>idl-compiler</artifactId>
>>> <version>3.0</version>
>>> </dependency>
>>>
>>> btw, kudos to the JacORB team for the dependency clean-up in version
>>> 3.0. Nice to get rid of avalon logging :)
>>>
>>> The only warning I would give to people is that if they've already
>>> brought in SLF4J for a more recent version of Java (5,6,7), the
>>> jacorb-parent POM has a dependency on slf4j-jdk14. You must override
>>> this transitive dependency to avoid class loader issues (i.e., Java or
>>> your servlet container may load wrong class.) Don't worry though, you
>>> should get a pretty clear error.
>>>
>>> I hope this helps,
>>>
>>> Tim
>>>
>>> On 07/06/2012 7:52 AM, Nick Cross wrote:
>>>>
>>>> Try using maven central e.g.
>>>>
>>>> "http://search.maven.org/#browse|-1539331823" or a mirror e.g.
>>>> http://mirrors.ibiblio.org/pub/mirrors/maven2/org/jacorb/
>>>>
>>>> I am not familiar with mvnrepository.com - is it an official mirror?
>>>>
>>>>
>>>> Regards
>>>>
>>>> Nick
>>>>
>>>> On 07/06/12 11:43, Lulseged Zerfu wrote:
>>>>> Hi
>>>>>
>>>>> I am looking jacORB from the www.mvnrepository.com. I don't know it
>>>>> it is where I should look jacORB from.
>>>>>
>>>>> http://mvnrepository.com/search.html?query=jacorb
>>>>>
>>>>> This query shows me that the core is there but not the idl-compiler.
>>>>>
>>>>> Or do you have another repository?
>>>>>
>>>>> Lulseged
>>>>>
>>>>> -----Original Message-----
>>>>> From: Nick Cross [mailto:jacorb at goots.org]
>>>>> Sent: den 7 juni 2012 12:39
>>>>> To: Discussions concerning CORBA development with JacORB
>>>>> Cc: Lulseged Zerfu
>>>>> Subject: Re: [jacorb-developer] JacORb in maven repository
>>>>>
>>>>>
>>>>> What have you tried looking at ? i.e. show me the central repository
>>>>> path / poms you have used?
>>>>>
>>>>> I have just checked and parent/idl-compiler/core and services are all
>>>>> there.
>>>>>
>>>>> Core is all you need for the core orb.
>>>>>
>>>>> Regards
>>>>>
>>>>> Nick
>>>>>
>>>>> On 07/06/12 08:36, Lulseged Zerfu wrote:
>>>>>> Hi
>>>>>>
>>>>>> On the 23:rd of May, jacORB was announced to be available in maven
>>>>>> repositories.
>>>>>>
>>>>>> I can only see jacORB::Core but is this all we need to run jacORB?
>>>>>>
>>>>>> Where is the jacORB::idl and other dependencies?
>>>>>>
>>>>>> Lulseged
>>>>>> _______________________________________________
>>>>>> jacorb-developer maillist -
>>>>>> jacorb-developer at lists.spline.inf.fu-berlin.de
>>>>>> https://lists.spline.inf.fu-berlin.de/mailman/listinfo/jacorb-develope
>>>>>>
>>>>>> r
>>>>>
>>>>
>>>> _______________________________________________
>>>> jacorb-developer maillist -
>>>> jacorb-developer at lists.spline.inf.fu-berlin.de
>>>> https://lists.spline.inf.fu-berlin.de/mailman/listinfo/jacorb-developer
>>>
>>
>
> --
> Timothy Astle, BCS
> Web Development Manager
>
> *CARIS* <http://www.caris.com>
> 115 Waggoners Lane
> Fredericton, New Brunswick
> Canada E3B 2L4
> Tel: +1.506.458.8533 Fax: +1.506.459.3849
> www.caris.com <http://www.caris.com>
>
> *Join us for CARIS 2012 — Exploration and Discovery*
> June 25–28, 2012, Vancouver, British Columbia, Canada
> Visit www.caris.com/caris2012 <http://www.caris.com/caris2012> for
> details today
>
> *Connect with CARIS*
> Twitter <http://www.twitter.com/CARIS_GIS> | LinkedIn
> <http://www.linkedin.com/groups?mostPopular=&gid=3217878> | Facebook
> <http://www.facebook.com/pages/CARIS-The-Marine-GIS-Experts/123907500987669?v=app_4949752878>
> | YouTube <http://www.youtube.com/user/CARISGIS>
>
> Download your free copy of CARIS Easy View today!
> www.caris.com/easyview <http://www.caris.com/easyview>
>
> _________________________________________________________________________
> This email and any files transmitted with it are confidential and
> intended only for the addressee(s). If you are not the intended
> recipient(s) please notify us by email reply. You should not use,
> disclose, distribute or copy this communication if received in error.
>
> Any views or opinions expressed in this email are solely those of the
> author and do not necessarily represent those of the company. No binding
> contract will result from this email until such time as a written
> document is signed on behalf of the company.
>



More information about the jacorb-developer mailing list