Yeah, that's the general point of pax-logging. It provides all the various
logger APIs to export to other packages, and internally they all route to a
common pax-logging log4j 1.x or 2.x config. Other bundles don't need to do
anything different than using Loggers as they would normally.

On 10 August 2016 at 08:58, <[email protected]> wrote:

> Resending: The message apparently didn't reach the list the first time
> around.
>
> Hello!
>
> I've recently stumbled across the pax-logging project and am curious if
> it is able to support the following slightly convoluted deployment
> configuration.
>
> The relevant points are:
>
> * The OSGi container is embedded within an application that already
>   has its own SLF4J logging. I don't care which backend is used (it's
>   currently logback-classic, but I don't mind switching to log4j if
>   necessary).
>
> * The OSGi container contains a mix of code that is both OSGi-aware
>   and OSGI-unaware. That is, some of the code uses the standard OSGi log
>   service, and the rest of it uses SLF4J.
>
> I would like to do the following, if possible:
>
> 1. The main application controls the SLF4J/logback/log4j configuration,
>    logging all messages to a rolling log appender. The main application
>    (the "host") doesn't do much before starting the OSGi container, but
>    I would still like it to be the host that's in control of logging.
>
> 2. Any messages generated by the OSGi framework (Felix in this case,
>    but I don't think it matters which I use) should go to the host's
>    SLF4J logging configuration.
>
> 3. Any messages logged by code running inside the OSGi container that's
>    using the OSGi log service should go to the host's SLF4J logging
>    configuration.
>
> 4. Any messages logged by code inside the OSGi container that's using
>    SLF4J should to the host's SLF4J logging configuration.
>
> Basically, I want to guarantee that every single log message is
> captured and that all of the the messages end up at the same
> destination so that I'm configuring logging in one place instead of
> multiple.
>
> Is this doable with pax-logging? Am I likely to suffer greatly trying
> to achieve it?
>
> Thanks,
> Mark
>
> --
> --
> ------------------
> OPS4J - http://www.ops4j.org - [email protected]
>
> ---
> You received this message because you are subscribed to the Google Groups
> "OPS4J" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Matt Sicker <[email protected]>

-- 
-- 
------------------
OPS4J - http://www.ops4j.org - [email protected]

--- 
You received this message because you are subscribed to the Google Groups 
"OPS4J" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to