logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Benedict <pbened...@apache.org>
Subject Re: lo4j2.xml in EAR
Date Mon, 03 Nov 2014 19:34:49 GMT
I'm using Wildfly 8.1


Cheers,
Paul

On Mon, Nov 3, 2014 at 1:34 PM, Paul Benedict <pbenedict@apache.org> wrote:

> I'm trying but failing. I once created a module for MySQL's connector --
> that's fine. But I am not succeeding creating a module for log4j2. Has
> anyone here tried this?
>
>
>
>
> Cheers,
> Paul
>
> On Sat, Nov 1, 2014 at 7:00 PM, Ralph Goers <ralph.goers@dslextreme.com>
> wrote:
>
>> I am not aware that we have implemented any specific support for EARs.
>> That said, I am not sure we need to. I’ve also looked at the Log4j 1.x code
>> and don’t see anything specific to supporting META-INF or EARs.
>>
>> Log4j will load log4j2.xml from the classpath, so you should be able to
>> do something like what is described at
>> https://developer.jboss.org/wiki/HowToPutAnExternalFileInTheClasspath <
>> https://developer.jboss.org/wiki/HowToPutAnExternalFileInTheClasspath>.
>> I believe you can also place it in the /lib directory or whatever directory
>> is defined in the library-directory element of the deployment descriptor.
>> See
>> http://javahowto.blogspot.com/2006/10/use-library-directory-in-javaee-5-apps.html
>> <
>> http://javahowto.blogspot.com/2006/10/use-library-directory-in-javaee-5-apps.html
>> >.
>>
>> What app server are you using?
>>
>> Ralph
>>
>>
>>
>> > On Nov 1, 2014, at 10:56 AM, Paul Benedict <pbenedict@apache.org>
>> wrote:
>> >
>> > When I used log4j 1.x, I could put my log4j.xml in the
>> <EarRoot>/META-INF
>> > folder and it was found. I did try this with log4j 2.0.2 and the
>> > configuration was not found.
>> >
>> > I read this but it only talks about WARs. I don't have a WAR but an EAR
>> > with EJB modules.
>> > http://logging.apache.org/log4j/2.x/manual/webapp.html
>> >
>> > So is this feature missing in 2.x? Or did I do something wrong?
>> >
>> > Cheers,
>> > Paul
>>
>>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message