tika-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bob Paulin (Jira)" <j...@apache.org>
Subject [jira] [Commented] (TIKA-2941) OSGI bundle and app are not self-contained
Date Mon, 07 Oct 2019 13:30:00 GMT

    [ https://issues.apache.org/jira/browse/TIKA-2941?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16945889#comment-16945889
] 

Bob Paulin commented on TIKA-2941:
----------------------------------

Just an update to provide some transparency around the "why" we got here.  With the newer
version of the maven-bundle-plugin when I revert my commit from before I do not see the transitive
dependencies included if the tika-parsers are in provided scope.  With tika-parsers being
embedded it does not really make sense for it to be in provided scope anyways.  However with
tika-parsers as a compile time dependency all the transitive dependencies are included in
maven which is what is being called out as the issue in this JIRA.  The good thing from an
OSGi perspective we're still OK since only the following packages are exported:

 
{code:java}
<Export-Package>
              !org.apache.tika.parser,
              !org.apache.tika.parser.external,
              org.apache.tika.parser.*,
	      org.apache.tika.metadata.serialization.*,
            </Export-Package> {code}
 

But the maven side still shows all the transitive dependencies coming through.  So in an
OSGi runtime all these packages are private as expected but in the development environment
this is a bit confusing since maven shows them coming through.  Will need some time to see
if we can get the maven side of this equation right without breaking the OSGi side.   Hopefully
this helps provide some context around the problem we're solving.

 

> OSGI bundle and app are not self-contained
> ------------------------------------------
>
>                 Key: TIKA-2941
>                 URL: https://issues.apache.org/jira/browse/TIKA-2941
>             Project: Tika
>          Issue Type: Bug
>    Affects Versions: 1.22
>            Reporter: Peng Cheng
>            Priority: Major
>
> Tika bundle still have dependencies spilled out of its package and cause jar hell everywhere.
If tika bundle is declared in maven as a dependency, a maven dependency:tree will indicate:
> [INFO] | +- org.apache.tika:tika-bundle:jar:1.22:test
>  [INFO] | | +- org.apache.tika:tika-core:jar:1.22:test
>  [INFO] | | - org.apache.tika:tika-parsers:jar:1.22:test
>  [INFO] | | +- org.glassfish.jaxb:jaxb-runtime:jar:2.3.2:test
>  [INFO] | | | +- jakarta.xml.bind:jakarta.xml.bind-api:jar:2.3.2:test
>  [INFO] | | | +- org.glassfish.jaxb:txw2:jar:2.3.2:test
>  [INFO] | | | +- com.sun.istack:istack-commons-runtime:jar:3.0.8:test
>  [INFO] | | | +- org.jvnet.staxex:stax-ex:jar:1.8.1:test
>  [INFO] | | | - com.sun.xml.fastinfoset:FastInfoset:jar:1.2.16:test
>  [INFO] | | +- com.sun.activation:jakarta.activation:jar:1.2.1:test
>  [INFO] | | +- org.gagravarr:vorbis-java-tika:jar:0.8:test
>  [INFO] | | +- org.tallison:jmatio:jar:1.5:test
>  [INFO] | | +- org.apache.james:apache-mime4j-core:jar:0.8.3:test
>  [INFO] | | +- org.apache.james:apache-mime4j-dom:jar:0.8.3:test
>  [INFO] | | +- com.epam:parso:jar:2.0.11:test
>  [INFO] | | +- org.brotli:dec:jar:0.1.2:test
>  [INFO] | | +- org.apache.pdfbox:pdfbox:jar:2.0.16:test
>  [INFO] | | | - org.apache.pdfbox:fontbox:jar:2.0.16:test
>  [INFO] | | +- org.apache.pdfbox:pdfbox-tools:jar:2.0.16:test
>  [INFO] | | +- org.apache.pdfbox:jempbox:jar:1.8.16:test
>  [INFO] | | +- org.bouncycastle:bcmail-jdk15on:jar:1.62:test
>  [INFO] | | | - org.bouncycastle:bcpkix-jdk15on:jar:1.62:test
>  [INFO] | | +- org.bouncycastle:bcprov-jdk15on:jar:1.62:test
>  [INFO] | | +- org.apache.poi:poi:jar:4.0.1:test
>  [INFO] | | | - org.apache.commons:commons-collections4:jar:4.2:test
>  [INFO] | | +- org.apache.poi:poi-scratchpad:jar:4.0.1:test
>  [INFO] | | +- org.apache.poi:poi-ooxml:jar:4.0.1:test
>  [INFO] | | | +- org.apache.poi:poi-ooxml-schemas:jar:4.0.1:test
>  [INFO] | | | | - org.apache.xmlbeans:xmlbeans:jar:3.0.2:test
>  [INFO] | | | - com.github.virtuald:curvesapi:jar:1.05:test
>  [INFO] | | +- com.healthmarketscience.jackcess:jackcess:jar:3.0.1:test
>  [INFO] | | +- com.healthmarketscience.jackcess:jackcess-encrypt:jar:3.0.0:test
>  [INFO] | | +- org.ccil.cowan.tagsoup:tagsoup:jar:1.2.1:test
>  [INFO] | | +- org.ow2.asm:asm:jar:7.2-beta:test
>  [INFO] | | +- com.googlecode.mp4parser:isoparser:jar:1.1.22:test
>  [INFO] | | +- com.drewnoakes:metadata-extractor:jar:2.11.0:test
>  [INFO] | | | - com.adobe.xmp:xmpcore:jar:5.1.3:test
>  [INFO] | | +- de.l3s.boilerpipe:boilerpipe:jar:1.1.0:test
>  [INFO] | | +- com.rometools:rome:jar:1.12.1:test
>  [INFO] | | | - com.rometools:rome-utils:jar:1.12.1:test
>  [INFO] | | +- org.gagravarr:vorbis-java-core:jar:0.8:test
>  [INFO] | | +- org.codelibs:jhighlight:jar:1.0.3:test
>  [INFO] | | +- com.pff:java-libpst:jar:0.8.1:test
>  [INFO] | | +- com.github.junrar:junrar:jar:4.0.0:test
>  [INFO] | | +- org.apache.cxf:cxf-rt-rs-client:jar:3.3.2:test
>  [INFO] | | | +- org.apache.cxf:cxf-rt-transports-http:jar:3.3.2:test
>  [INFO] | | | +- org.apache.cxf:cxf-core:jar:3.3.2:test
>  [INFO] | | | | +- com.fasterxml.woodstox:woodstox-core:jar:5.0.3:test
>  [INFO] | | | | | - org.codehaus.woodstox:stax2-api:jar:3.1.4:test
>  [INFO] | | | | +- org.apache.ws.xmlschema:xmlschema-core:jar:2.2.4:test
>  [INFO] | | | | - org.glassfish.jaxb:jaxb-xjc:jar:2.3.2:test
>  [INFO] | | | | +- org.glassfish.jaxb:xsom:jar:2.3.2:test
>  [INFO] | | | | +- org.glassfish.jaxb:codemodel:jar:2.3.2:test
>  [INFO] | | | | +- com.sun.xml.bind.external:rngom:jar:2.3.2:test
>  [INFO] | | | | +- com.sun.xml.dtd-parser:dtd-parser:jar:1.4.1:test
>  [INFO] | | | | +- com.sun.istack:istack-commons-tools:jar:3.0.8:test
>  [INFO] | | | | - com.sun.xml.bind.external:relaxng-datatype:jar:2.3.2:test
>  [INFO] | | | - org.apache.cxf:cxf-rt-frontend-jaxrs:jar:3.3.2:test
>  [INFO] | | | +- jakarta.ws.rs:jakarta.ws.rs-api:jar:2.1.5:test
>  [INFO] | | | - org.apache.cxf:cxf-rt-security:jar:3.3.2:test
>  [INFO] | | +- org.apache.opennlp:opennlp-tools:jar:1.9.1:test
>  [INFO] | | +- com.googlecode.json-simple:json-simple:jar:1.1.1:test
>  [INFO] | | +- com.github.openjson:openjson:jar:1.0.11:test
>  [INFO] | | +- edu.ucar:netcdf4:jar:4.5.5:test
>  [INFO] | | | - net.jcip:jcip-annotations:jar:1.0:test
>  [INFO] | | +- org.jdom:jdom2:jar:2.0.6:test
>  [INFO] | | +- edu.ucar:grib:jar:4.5.5:test
>  [INFO] | | | - org.itadaki:bzip2:jar:0.9.1:test
>  [INFO] | | +- edu.ucar:cdm:jar:4.5.5:test
>  [INFO] | | | +- edu.ucar:udunits:jar:4.5.5:test
>  [INFO] | | | +- org.quartz-scheduler:quartz:jar:2.2.0:test
>  [INFO] | | | - net.sf.ehcache:ehcache-core:jar:2.6.2:test
>  [INFO] | | +- com.mchange:c3p0:jar:0.9.5.4:test
>  [INFO] | | | - com.mchange:mchange-commons-java:jar:0.2.15:test
>  [INFO] | | +- edu.ucar:httpservices:jar:4.5.5:test
>  [INFO] | | +- org.apache.sis.core:sis-utility:jar:0.8:test
>  [INFO] | | | - javax.measure:unit-api:jar:1.0:test
>  [INFO] | | +- org.apache.sis.storage:sis-netcdf:jar:0.8:test
>  [INFO] | | | +- org.apache.sis.storage:sis-storage:jar:0.8:test
>  [INFO] | | | | - org.apache.sis.core:sis-feature:jar:0.8:test
>  [INFO] | | | - org.apache.sis.core:sis-referencing:jar:0.8:test
>  [INFO] | | +- org.apache.sis.core:sis-metadata:jar:0.8:test
>  [INFO] | | +- org.opengis:geoapi:jar:3.0.1:test
>  [INFO] | | +- edu.usc.ir:sentiment-analysis-parser:jar:0.1:test
>  [INFO] | | +- org.apache.pdfbox:jbig2-imageio:jar:3.0.2:test
>  [INFO] | | - com.github.jai-imageio:jai-imageio-core:jar:1.4.0:test
>  
> This should not happen as OSGI bundle should be self-contained without possibility of
external version conflict.
>  
> The same observation applies to app bundle



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message