Hello

I agree with +Niclas Hedhman <[email protected]> and I'm the one who
noticed this mistake. The original message was here[1].
The problem I had is that "impl" was not supposed to be exported. But it is
exported from original log4j-core-2.12.0.jar "bundle". I'm not sure how
Log4j2 authors deal with OSGi, but pax-logging does it differently - it was
supposed to hide the internals, so you can't actually call
org.apache.logging.log4j.core.LoggerContext#getContext() (there were emails
about this, e.g., here[2]) to get access to log4j2 internals.

I wrote about all the new changes in new documentation[3].

But summarizing, please tell me what is your goal and I believe it can be
achieved with proper fragment attached to pax-logging-log4j2 bundle. I
added integration test that adds new plugins here[4] - it uses "List"
appender implemented in fragment bundle[5].

regards
Grzegorz Grzybek

[1]: https://groups.google.com/forum/#!topic/ops4j/4jY2a0lLdpE
[2]: https://groups.google.com/forum/#!topic/ops4j/yjqOzvrKRkc
[3]:
https://ops4j1.jira.com/wiki/spaces/paxlogging/pages/499351646/Documentation
[4]:
https://github.com/ops4j/org.ops4j.pax.logging/blob/logging-1.11.0/pax-logging-it/src/test/java/org/ops4j/pax/logging/it/Log4J2BuiltinAppendersIntegrationTest.java#L183-L198
[5]:
https://github.com/ops4j/org.ops4j.pax.logging/blob/logging-1.11.0/pax-logging-samples/fragment-log4j2/src/main/java/org/ops4j/pax/logging/log4j2/extra/ListAppender.java

wt., 30 lip 2019 o 03:16 Niclas Hedhman <[email protected]> napisaƂ(a):

>
> Implementation details are not expected to be Exported, and I assume that
> someone noticed this mistake.
>
> Perhaps you could explain what you are accessing in there, and we'll work
> out a solution for the usecase, rather than blanket expose the inner guts.
>
> Cheers
> Niclas
>
> On Tue, Jul 30, 2019 at 2:16 AM 'Tharindu Dharmarathna' via OPS4J <
> [email protected]> wrote:
>
>> Hi All,
>>
>> We are using pax-logging 1.10.1 version currently. When we going to
>> update into the latest pax-logging version which is 1.11.0 it did not have
>> the log4j2 core "*org.apache.logging.log4j.core.impl*" doesn't expose
>> outside from bundle.
>>
>> When Comparing *MANIFEST.MF *in pax-logging-log4j2 jars we cold able to
>> see Export-Packages are missing in the 1.11.0 version.
>>
>> Could you, please let us know on way of getting above fixed ?.
>>
>> Thanks
>> Tharindu
>>
>> --
>> --
>> ------------------
>> 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].
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/ops4j/ebfc2603-334f-4594-9244-2de040faf318%40googlegroups.com
>> <https://groups.google.com/d/msgid/ops4j/ebfc2603-334f-4594-9244-2de040faf318%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>
>
> --
> Niclas Hedhman, Software Developer
> http://polygene.apache.org - New Energy for Java
>
> --
> --
> ------------------
> 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].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ops4j/CADmm%2BKfmnX5De9vJU9LbtVMzz%3DwOj4cXu720uFpeaH3vaWvLSQ%40mail.gmail.com
> <https://groups.google.com/d/msgid/ops4j/CADmm%2BKfmnX5De9vJU9LbtVMzz%3DwOj4cXu720uFpeaH3vaWvLSQ%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
-- 
------------------
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].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ops4j/CAAdXmhq2x2Xbymuho6RqM0dXAZd2D_u7bYS2254UuN_aLK3%3D7Q%40mail.gmail.com.

Reply via email to