dev@glassfish.java.net

Re: Guava in GF 4

From: Sahoo <sanjeeb.sahoo_at_oracle.com>
Date: Wed, 29 Jan 2014 19:57:23 +0530

You are right, only Jersey uses it. In a typical glassfish full profile
installation, these are the following consumers of guava as reported by
OSGi when I resolve all modules:

> com.google.guava [108] exports packages:
> ----------------------------------------
> com.google.common.net; version=14.0.0 imported by:
> org.glassfish.jersey.core.jersey-common [164]
> com.google.common.collect; version=14.0.0 imported by:
> org.glassfish.jersey.media.jersey-media-moxy [173]
> org.glassfish.jersey.core.jersey-server [179]
> org.glassfish.jersey.core.jersey-client [163]
> org.glassfish.jersey.containers.jersey-container-servlet-core [166]
> org.glassfish.jersey.containers.glassfish.jersey-gf-cdi [168]
> org.glassfish.jersey.ext.jersey-mvc-jsp [177]
> org.glassfish.jersey.ext.jersey-bean-validation [162]
> org.glassfish.jersey.ext.jersey-mvc [178]
> org.glassfish.jersey.core.jersey-common [164]
> org.glassfish.jersey.containers.jersey-container-servlet [167]
> com.google.common.primitives; version=14.0.0 imported by:
> org.glassfish.jersey.core.jersey-server [179]
> org.glassfish.jersey.core.jersey-common [164]
> com.google.common.base; version=14.0.0 imported by:
> org.glassfish.jersey.core.jersey-server [179]
> org.glassfish.jersey.core.jersey-client [163]
> org.glassfish.jersey.ext.jersey-bean-validation [162]
> org.glassfish.jersey.ext.jersey-mvc [178]
> org.glassfish.jersey.core.jersey-common [164]
> com.google.common.cache; version=14.0.0 UNUSED
> com.google.common.eventbus; version=14.0.0 UNUSED
> com.google.common.util.concurrent; version=14.0.0 imported by:
> org.glassfish.jersey.core.jersey-client [163]
> org.glassfish.jersey.core.jersey-server [179]
> org.glassfish.jersey.containers.jersey-container-servlet-core [166]
> com.google.common.hash; version=14.0.0 UNUSED
> com.google.common.io; version=14.0.0 UNUSED
> com.google.common.reflect; version=14.0.0 UNUSED
> com.google.common.math; version=14.0.0 UNUSED
> com.google.common.annotations; version=14.0.0 UNUSED

You can do it yourself by executing the following commands in your
glassfish installation (remove the comments while executing the commands):

> sanjsaho-mac:embedded-rar-sample sahoo$
> ~/WS/gf/trunk/appserver/distributions/glassfish/target/stage/glassfish4/glassfish/bin/asadmin
> osgi-shell
> Use "exit" to exit and "help" for online help.
> gogo$ resolve # resolve all modules
> gogo$ lb -l | grep guava # find out id of guava module
> 108|Resolved |
> 1|file:/Users/sahoo/WS/gf/trunk/appserver/distributions/glassfish/target/stage/glassfish4/glassfish/modules/guava.jar
> gogo$ inspect package capability 108 #*i*nspect wiring information for
> *p*ackage *c*apability of guava bundle

HTH,
Sahoo


On 1/29/14 2:55 PM, Michal Gajdos wrote:
> Hi,
>
> is anyone besides Jersey using Guava in GF 4? I couldn't find any
> references in the sources so I am asking explicitly. We're able to
> drop this dependency during Jersey 2.6 integration and I'd like to
> find whether it's possible from the perspective of other modules.
>
> Thanks,
> Michal