[GitHub] jena pull request #428: Update OSGi imports
Github user asfgit closed the pull request at: https://github.com/apache/jena/pull/428 ---
[GitHub] jena pull request #428: Update OSGi imports
Github user afs commented on a diff in the pull request: https://github.com/apache/jena/pull/428#discussion_r194137833 --- Diff: apache-jena-osgi/jena-osgi-features/src/main/resources/features.xml --- @@ -21,28 +21,24 @@ mvn:org.apache.jena/jena-osgi/${project.version} jena_osgi_dependencies - - - mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} - mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} - mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} - mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} - mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} - mvn:org.apache.commons/commons-csv/${ver.commonscsv} - mvn:org.apache.commons/commons-lang3/${ver.commonslang3} - mvn:commons-codec/commons-codec/${ver.commons-codec} - mvn:commons-io/commons-io/${ver.commonsio} - mvn:org.apache.thrift/libthrift/${ver.libthrift} - - - - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xerces/2.11.0_1 - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xmlresolver/1.2_5 + mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} + mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} + mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} + mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} + mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} + mvn:org.apache.commons/commons-compress/${ver.commons-compress} + mvn:org.apache.commons/commons-csv/${ver.commonscsv} + mvn:org.apache.commons/commons-lang3/${ver.commonslang3} + mvn:commons-codec/commons-codec/${ver.commons-codec} + mvn:commons-io/commons-io/${ver.commonsio} + mvn:org.apache.thrift/libthrift/${ver.libthrift} + + mvn:com.google.guava/guava/24.1-jre --- End diff -- Ah - OK - that explains it. All looks to go. ---
[GitHub] jena pull request #428: Update OSGi imports
Github user acoburn commented on a diff in the pull request: https://github.com/apache/jena/pull/428#discussion_r194126560 --- Diff: apache-jena-osgi/jena-osgi-features/src/main/resources/features.xml --- @@ -21,28 +21,24 @@ mvn:org.apache.jena/jena-osgi/${project.version} jena_osgi_dependencies - - - mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} - mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} - mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} - mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} - mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} - mvn:org.apache.commons/commons-csv/${ver.commonscsv} - mvn:org.apache.commons/commons-lang3/${ver.commonslang3} - mvn:commons-codec/commons-codec/${ver.commons-codec} - mvn:commons-io/commons-io/${ver.commonsio} - mvn:org.apache.thrift/libthrift/${ver.libthrift} - - - - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xerces/2.11.0_1 - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xmlresolver/1.2_5 + mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} + mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} + mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} + mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} + mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} + mvn:org.apache.commons/commons-compress/${ver.commons-compress} + mvn:org.apache.commons/commons-csv/${ver.commonscsv} + mvn:org.apache.commons/commons-lang3/${ver.commonslang3} + mvn:commons-codec/commons-codec/${ver.commons-codec} + mvn:commons-io/commons-io/${ver.commonsio} + mvn:org.apache.thrift/libthrift/${ver.libthrift} + + mvn:com.google.guava/guava/24.1-jre --- End diff -- You are correct that jsonld-java does shade guava, but their OSGi bundle still imports the `com.google.common` packages: this is from the jsonld-java OSGi metadata: ``` Import-Package ... com.google.common.cache{version=[24.1,25)} com.google.common.collect {version=[24.1,25)} ``` And so in practice, adding guava as a dependency is still necessary. I think this is an error with the jsonld-java OSGi metadata, and I will bring this up with that project. For example, when trying to load just the `jsonld-java` bundle in Karaf -- once I add the Jackson dependencies -- I get this error if guava is not also installed: ``` Unable to resolve com.github.jsonld-java [46](R 46.0): missing requirement [com.github.jsonld-java [46](R 46.0)] osgi.wiring.package; (&(osgi.wiring.package=com.google.common.cache)(version>=24.1.0)(!(version>=25.0.0))) ``` ...which means that the guava packages need to be installed. Once guava is added, the jsonld-java bundle installs and starts just fine. ---
[GitHub] jena pull request #428: Update OSGi imports
Github user afs commented on a diff in the pull request: https://github.com/apache/jena/pull/428#discussion_r194124193 --- Diff: apache-jena-osgi/jena-osgi-features/src/main/resources/features.xml --- @@ -21,28 +21,24 @@ mvn:org.apache.jena/jena-osgi/${project.version} jena_osgi_dependencies - - - mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} - mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} - mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} - mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} - mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} - mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} - mvn:org.apache.commons/commons-csv/${ver.commonscsv} - mvn:org.apache.commons/commons-lang3/${ver.commonslang3} - mvn:commons-codec/commons-codec/${ver.commons-codec} - mvn:commons-io/commons-io/${ver.commonsio} - mvn:org.apache.thrift/libthrift/${ver.libthrift} - - - - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xerces/2.11.0_1 - mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.xmlresolver/1.2_5 + mvn:com.github.andrewoma.dexx/collection/${ver.dexxcollection} + mvn:com.github.jsonld-java/jsonld-java/${ver.jsonldjava} + mvn:com.fasterxml.jackson.core/jackson-core/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-databind/${ver.jackson} + mvn:com.fasterxml.jackson.core/jackson-annotations/${ver.jackson} + mvn:org.apache.httpcomponents/httpcore-osgi/${ver.httpcore-osgi} + mvn:org.apache.httpcomponents/httpclient-osgi/${ver.httpclient-osgi} + mvn:org.apache.commons/commons-compress/${ver.commons-compress} + mvn:org.apache.commons/commons-csv/${ver.commonscsv} + mvn:org.apache.commons/commons-lang3/${ver.commonslang3} + mvn:commons-codec/commons-codec/${ver.commons-codec} + mvn:commons-io/commons-io/${ver.commonsio} + mvn:org.apache.thrift/libthrift/${ver.libthrift} + + mvn:com.google.guava/guava/24.1-jre --- End diff -- I don't think this is true any more. At version 0.12.0, they shade guava and put in their jar so it does not need com.google.guava:guava. At least, that's the theory! If you have found that in practice it is needed, that has more weight. ---
[GitHub] jena pull request #428: Update OSGi imports
GitHub user acoburn opened a pull request: https://github.com/apache/jena/pull/428 Update OSGi imports Resolves: JENA-1557 This adds an exclusion for `org.checkerframework.checker.*`, which is now pulled in by `jena-shaded-guava`. This also adds guava (jsonld-java depends on this) and commons-compress to the `features.xml` file. In addition, this reformats the `Import-Package` definition to make it easier to read (and maintain). You can merge this pull request into a Git repository by running: $ git pull https://github.com/acoburn/jena JENA-1557 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/jena/pull/428.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #428 commit 443d5697fc22c90172833695ec0bd01252e80a54 Author: Aaron Coburn Date: 2018-06-06T16:33:47Z Update OSGi imports Resolves: JENA-1557 ---