javaee / jersey

This is no longer the active Jersey repository. Please see the README.md
http://jersey.github.io
Other
2.86k stars 2.36k forks source link

Jersey 2.0 Maven artiifact depends on non repackaged Guava and old ASM version #2156

Closed glassfishrobot closed 10 years ago

glassfishrobot commented 11 years ago

With

jvnet-nexus-promoted Java.net Promoted Repositories [https://maven.java.net/content/repositories/promoted/](https://maven.java.net/content/repositories/promoted/) true false

and

javax.ws.rs javax.ws.rs-api 2.0 org.glassfish.jersey.core jersey-server 2.0

for a web application, we end up with non desired and/or obsolete dependencies in the resulting WEB-INF/lib area with:

1- jersey-client 2.0 ? Why I want a server! 2-asm-all-repackaged-2.1.88: why? First this is the old ASM 3.x non compatible with Java 7, then it is NOT repackaged at all, so any Web App cannot use ASM4.x and Jersey 2.0 together...This would be a blocker for Java 7 support, and not being repackaged is very serious 3- osgi-resource-locator: Why OSGI in a pure JAX-RS simple App? 4 javax.inject-2.1.88 : what is this 2.1.88 version? Is it ancient? Modern? Why tight to hk2? 5 guava-14.0.1.jar: what will happen if/when there is guava15 and my Web App Needs to depend on it, but Jersey is not upgraded?

A Maven nightmare. Key ones are: ASM not being 4.1 so not being Java 7 compatible (stack map frame processing for bytecode 51) and Guava should be repackaged to be a private implementation. Look at the jarjar tools that does that.

Hint: You can use the NetBeans Maven graph viewer on a very simple pom have my 2 entries and you'll see the

Affected Versions

[2.0-rc2, 2.3.1]

glassfishrobot commented 11 years ago

Reported by ludo

glassfishrobot commented 11 years ago

aaronjwhiteside said: And the dependency on

<groupId>javax.annotation</groupId>
<artifactId>javax.annotation-api</artifactId>
<version>1.2</version>

is not resolving for me.. so I had to manually exclude it and include:

<dependency>
            <groupId>javax.annotation</groupId>
            <artifactId>javax.annotation-api</artifactId>
            <version>1.2-b04</version>
        </dependency>

which is the latest one in the central maven repo..

glassfishrobot commented 11 years ago

aaronjwhiteside said: It should also be noted that guava-14.0.1.jar cannot be deployed in a JEE7 container due to CDI being enabled by default (without a beans.xml).

https://code.google.com/p/guava-libraries/issues/detail?id=1433

Update: This now appears to be a CDI 1.1 spec compliance issue, Glassfish 4.0 b90 does not support section 12.1 and 12.4 of the CDI spec at the moment, which makes it impossible to use guava-14.0.1.

glassfishrobot commented 11 years ago

Issue-Links: is related to GLASSFISH-20850 JERSEY-2267 JERSEY-2274

glassfishrobot commented 11 years ago

Was assigned to michalgajdos

glassfishrobot commented 7 years ago

This issue was imported from java.net JIRA JERSEY-1884

glassfishrobot commented 10 years ago

Marked as fixed on Friday, February 7th 2014, 1:42:17 am