[
https://issues.apache.org/jira/browse/CXF-7899?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16686023#comment-16686023
]
Hans Brende edited comment on CXF-7899 at 11/14/18 2:42 AM:
------------------------------------------------------------
[~ffang] The thing is though, that *we're not* using it. This is the test that
failed:
{code:java}
@Test
public void testExtractTextAcceptPlainText() throws Exception {
//TIKA-2384
Attachment attachmentPart = new Attachment(
"my-docx-file",
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
ClassLoader.getSystemResourceAsStream("2pic.docx")
);
Response response = WebClient.create(endPoint + TIKA_PATH + "/form")
.type("multipart/form-data")
.accept("text/plain")
.post(attachmentPart); //line 330 <-- ERROR OCCURRED HERE
...
{code}
This code failed on Java 11.
And here is a bit of the stack trace we got out:
{noformat}
...
at
org.apache.cxf.jaxrs.client.WebClient.doChainedInvocation(WebClient.java:1050)
at org.apache.cxf.jaxrs.client.WebClient.doInvoke(WebClient.java:897)
at org.apache.cxf.jaxrs.client.WebClient.doInvoke(WebClient.java:866)
at org.apache.cxf.jaxrs.client.WebClient.invoke(WebClient.java:334)
at org.apache.cxf.jaxrs.client.WebClient.post(WebClient.java:343)
at
org.apache.tika.server.TikaResourceTest.testExtractTextAcceptPlainText(TikaResourceTest.java:330)
...
Caused by: java.lang.ClassNotFoundException:
com.sun.activation.registries.LogSupport
{noformat}
So unless I'm completely crazy, CXF *does* have an undeclared runtime
dependency on com.sun.activation:javax.activation:1.2.0 that is *not* limited
to the test scope.
was (Author: hansbrende):
[~ffang] The thing is though, that *we're not* using it. This is the test that
failed:
{code:java}
@Test
public void testExtractTextAcceptPlainText() throws Exception {
//TIKA-2384
Attachment attachmentPart = new Attachment(
"my-docx-file",
"application/vnd.openxmlformats-officedocument.wordprocessingml.document",
ClassLoader.getSystemResourceAsStream("2pic.docx")
);
Response response = WebClient.create(endPoint + TIKA_PATH + "/form")
.type("multipart/form-data")
.accept("text/plain")
.post(attachmentPart); //line 330
...
{code}
This code failed on Java 11.
And here is a bit of the stack trace we got out:
{noformat}
...
at
org.apache.cxf.jaxrs.client.WebClient.doChainedInvocation(WebClient.java:1050)
at org.apache.cxf.jaxrs.client.WebClient.doInvoke(WebClient.java:897)
at org.apache.cxf.jaxrs.client.WebClient.doInvoke(WebClient.java:866)
at org.apache.cxf.jaxrs.client.WebClient.invoke(WebClient.java:334)
at org.apache.cxf.jaxrs.client.WebClient.post(WebClient.java:343)
at
org.apache.tika.server.TikaResourceTest.testExtractTextAcceptPlainText(TikaResourceTest.java:330)
...
Caused by: java.lang.ClassNotFoundException:
com.sun.activation.registries.LogSupport
{noformat}
So unless I'm completely crazy, CXF *does* have an undeclared runtime
dependency on com.sun.activation:javax.activation:1.2.0 that is *not* limited
to the test scope.
> Java 11 and javax.activation dependencies
> -----------------------------------------
>
> Key: CXF-7899
> URL: https://issues.apache.org/jira/browse/CXF-7899
> Project: CXF
> Issue Type: Task
> Reporter: Tim Allison
> Assignee: Freeman Fang
> Priority: Major
>
> Again, many apologies if this is a duplicate. Over on TIKA-2778, we're
> trying to add only the minimal dependencies that will allow us to compile and
> run with Java 11.
> We tried adding
> {noformat}
> <!-- for java 10 -->
> <dependency>
> <groupId>org.glassfish.jaxb</groupId>
> <artifactId>jaxb-runtime</artifactId>
> <version>2.3.1</version>
> </dependency>
> {noformat}
> However, as [~HansBrende] pointed out, this includes some of the
> javax.activation classes, but not those in com.sun.activation.*
> Any chance you'd be willing to migrate away from classes in this namespace?
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)