You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@jena.apache.org by GitBox <gi...@apache.org> on 2020/04/21 15:13:18 UTC

[GitHub] [jena] acoburn opened a new pull request #731: JENA-1888: Exclude log4j2 from OSGi bundle

acoburn opened a new pull request #731:
URL: https://github.com/apache/jena/pull/731


   This excludes the log4j2 dependency from the OSGi bundle metadata


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] kinow commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
kinow commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-618072699


   > @kinow yes, there are ways to automate the testing of OSGi. Typically, one uses [pax-exam](https://ops4j1.jira.com/wiki/spaces/PAXEXAM4/overview) for this. In fact, there is already [some code](https://github.com/apache/jena/blob/master/apache-jena-osgi/jena-osgi-test/src/test/java/org/apache/jena/osgi/test/JenaOSGITest.java) in the Jena source tree that uses pax-exam for this sort of test.
   
   First time I heard about pax-exam, looks interesting, thanks @acoburn . 
   
   >That test code, however, is not currently enabled, and it is a bit out-of-date, but it would be quite possible to restructure that a bit to automate the OSGi testing.
   
   Should we create a JIRA ticket for that? Maybe one of us could work re-enabling it later, and make it easier to spot and fix issues with OSGi.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] acoburn commented on pull request #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
acoburn commented on pull request #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-619441709


   I spent some time familiarizing myself with the log4j2 code dependency in jena-base. Because log4j-api and log4j-core are marked as optional in that module's pom.xml (and given how the code is structured in LogCtl.java), it seems more correct for those OSGi imports to be marked as optional. To me, this seems like a better solution than excluding the imports; plus, it mirrors the dependency structure of jena-base itself.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] afs removed a comment on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
afs removed a comment on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-617288513


   For my information: log4j and slf4j-log4j12 weren't excluded in the past so has something changed that log4j2 is being picked up? If so, then maybe the issue is earlier in the process.
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] afs commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
afs commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-618384775


   JENA-913 "mvn clean verify" did not work but I can't understand the thread and links to know what the problem really was. 
   
   Ah - maybe - the preflight jenkins job "Jena_Development_Test" - and jena-osgi only works off installed, not built-in-job, artifacts which i think "mvn verify" normally does.
   
   Another option would to run a separate job that checks OSGi and get it to run after a successful build.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] acoburn commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
acoburn commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-617368874


   I looked a little deeper into this. The issue is related to the `org.apache.logging.log4j.core` package, which isn't exported by the pax-logger implementation that is part of the newer Karaf platforms. (Running `package:exports | grep -i log4j` in the different versions of Karaf will give you this information).
   
   The simple work-around is to just install the required bundle:
   
   ```
   bundle:install -s mvn:org.apache.logging.log4j/log4j-core/2.13.1
   ```
   
   (or the equivalent in a downstream features file).
   
   Either way, it seems that this PR is _not_ the right approach, and this should not be merged. The open question is just whether this dependency should be added to the Jena-provided features.xml file or just leave things as they currently are, but documenting how this works.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] afs commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
afs commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-617288513


   For my information: log4j and slf4j-log4j12 weren't excluded in the past so has something changed that log4j2 is being picked up? If so, then maybe the issue is earlier in the process.
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] kinow commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
kinow commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-617602698


   @acoburn just random question, would it be possible to use Jenkins/Travis/GH actions/etc to start a container with Karaf, build Jena from sources, deploy and test to see if any change broke OSGi? Or is it something that needs manually testing and reviewing the dependencies (only read about OSGi, and had very little contact while using jboss/wildfly).


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org


[GitHub] [jena] acoburn commented on issue #731: JENA-1888: Exclude log4j2 from OSGi bundle

Posted by GitBox <gi...@apache.org>.
acoburn commented on issue #731:
URL: https://github.com/apache/jena/pull/731#issuecomment-617727676


   @kinow yes, there are ways to automate the testing of OSGi. Typically, one uses [pax-exam](https://ops4j1.jira.com/wiki/spaces/PAXEXAM4/overview) for this. In fact, there is already [some code](https://github.com/apache/jena/blob/master/apache-jena-osgi/jena-osgi-test/src/test/java/org/apache/jena/osgi/test/JenaOSGITest.java) in the Jena source tree that uses pax-exam for this sort of test. That test code, however, is not currently enabled, and it is a bit out-of-date, but it would be quite possible to restructure that a bit to automate the OSGi testing.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@jena.apache.org
For additional commands, e-mail: pr-help@jena.apache.org