Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » e(fx)clipse » Right way to use the embedded Guava Library?
Right way to use the embedded Guava Library? [message #1159223] Mon, 28 October 2013 11:26 Go to next message
Ghislain Mustermann is currently offline Ghislain MustermannFriend
Messages: 24
Registered: April 2013
Junior Member
Hello Everyone,

i'm actually uncapable to use the guava library coming with e(fx)clipse. I have a really basic example. My Application run perfectly, now i want to use for example
Preconditions.checknotnull
. What i done before is to add into App Bundles the Guava Bundle too or just importing the package containing Preconditions into "Imported Packages".

But while compiling i have a Error saying that the product cant find the Guava Bundle. I also add needed Plugins into the Run Configuration, but nothing change.

How is the right to integrate and propely use Guava with e(fx)clipse?
Re: Right way to use the embedded Guava Library? [message #1180262 is a reply to message #1159223] Sun, 10 November 2013 22:11 Go to previous messageGo to next message
Ghislain Mustermann is currently offline Ghislain MustermannFriend
Messages: 24
Registered: April 2013
Junior Member
I always got this Error when i imported guava(12.0.0) into my Required Plugins :

!ENTRY org.eclipse.osgi 2 0 2013-11-10 23:03:09.741
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-11-10 23:03:09.741
!MESSAGE Bundle com.myproject.app_1.0.0.qualifier [2019] was not resolved.
!SUBENTRY 2 com.myproject.app 2 0 2013-11-10 23:03:09.741
!MESSAGE Package uses conflict: Require-Bundle: com.google.guava; bundle-version="12.0.0"

!ENTRY org.eclipse.osgi 2 0 2013-11-10 23:03:09.764
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2013-11-10 23:03:09.765
!MESSAGE Bundle com.myproject.app_1.0.0.qualifier [2019] was not resolved.
!SUBENTRY 2 com.myproject.app 2 0 2013-11-10 23:03:09.765
!MESSAGE Package uses conflict: Require-Bundle: com.google.guava; bundle-version="12.0.0"

I'm really trying to solve this mess since a month now, can someone help me out on this?
Re: Right way to use the embedded Guava Library? [message #1181172 is a reply to message #1180262] Mon, 11 November 2013 12:24 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5465
Registered: July 2009
Senior Member
On 10.11.13 23:11, Ghislain Mustermann wrote:
> I always got this Error when i imported guava(12.0.0) into my Required
> Plugins :
> !ENTRY org.eclipse.osgi 2 0 2013-11-10 23:03:09.741
> !MESSAGE The following is a complete list of bundles which are not
> resolved, see the prior log entry for the root cause if it exists:
> !SUBENTRY 1 org.eclipse.osgi 2 0 2013-11-10 23:03:09.741
> !MESSAGE Bundle com.myproject.app_1.0.0.qualifier [2019] was not resolved.
> !SUBENTRY 2 com.myproject.app 2 0 2013-11-10 23:03:09.741
> !MESSAGE Package uses conflict: Require-Bundle: com.google.guava;
> bundle-version="12.0.0"
>
> !ENTRY org.eclipse.osgi 2 0 2013-11-10 23:03:09.764
> !MESSAGE The following is a complete list of bundles which are not
> resolved, see the prior log entry for the root cause if it exists:
> !SUBENTRY 1 org.eclipse.osgi 2 0 2013-11-10 23:03:09.765
> !MESSAGE Bundle com.myproject.app_1.0.0.qualifier [2019] was not resolved.
> !SUBENTRY 2 com.myproject.app 2 0 2013-11-10 23:03:09.765
> !MESSAGE Package uses conflict: Require-Bundle: com.google.guava;
> bundle-version="12.0.0"
>
> I'm really trying to solve this mess since a month now, can someone help
> me out on this?

This is a mess you seem to have created your own! I'm not sure what we
can help with. We are shipping guava 10.0.1 in our target, which IIRC
misses stuff you want use, so you have gotten 12.0.0 from somewhere
else. You now have 2 guava versions in your target and OSGi tries to
resolve both of them somehow on the same bundle.

How does your MANIFEST.MF look like? Did you make sure that only one of
the guava libs is enabled in your launch config?

Tom
Re: Right way to use the embedded Guava Library? [message #1212760 is a reply to message #1181172] Wed, 27 November 2013 01:52 Go to previous messageGo to next message
Ghislain Mustermann is currently offline Ghislain MustermannFriend
Messages: 24
Registered: April 2013
Junior Member
Well, into my Target Content i have one location :

http://downloads.efxclipse.org/eclipse.org/p2-repos/runtime/nightly/ (0.9.0.201307250003) and i see com.google.guava(12.0.0...) into it.

so what is wrong with that? it's come straight from efxclipse.

I use Eclipse Kepler by the way.

[Updated on: Wed, 27 November 2013 02:03]

Report message to a moderator

Re: Right way to use the embedded Guava Library? [message #1216054 is a reply to message #1212760] Thu, 28 November 2013 09:55 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5465
Registered: July 2009
Senior Member
Oh you are right! Let me see what I can findout

Tom

On 27.11.13 02:52, Ghislain Mustermann wrote:
> Well, into my Target Content i have one location :
> http://download.eclipse.org/efxclipse/runtime-nightly/site and i see
> com.google.guava(12.0.0...) so what is wrong with that? it's come
> straight from efxclipse.
Re: Right way to use the embedded Guava Library? [message #1216084 is a reply to message #1212760] Thu, 28 November 2013 10:09 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5465
Registered: July 2009
Senior Member
Just tested this myself and it works without problems. Is your project
based on features? Did you make sure that the bundle is launched? You
can check this by launching with -console -noexit and enter ss to see
which bundles are available.

Tom

On 27.11.13 02:52, Ghislain Mustermann wrote:
> Well, into my Target Content i have one location :
> http://download.eclipse.org/efxclipse/runtime-nightly/site and i see
> com.google.guava(12.0.0...) so what is wrong with that? it's come
> straight from efxclipse.
Re: Right way to use the embedded Guava Library? [message #1216791 is a reply to message #1216084] Thu, 28 November 2013 16:31 Go to previous messageGo to next message
Ghislain Mustermann is currently offline Ghislain MustermannFriend
Messages: 24
Registered: April 2013
Junior Member
http://download.eclipse.org/efxclipse/runtime-nightly/site has 0 plug-ins available, is there some troubles??

Well! i used feature in my product. But which one is better? Features vs Plug-Ins?
Re: Right way to use the embedded Guava Library? [message #1216844 is a reply to message #1216791] Thu, 28 November 2013 17:01 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 5465
Registered: July 2009
Senior Member
If there's a problem then it is on your side, in my target def I get all
bundles.

If you want you can also download them as a zip-File
http://download.eclipse.org/efxclipse/runtime-nightly/site_assembly.zip
and yes you should use features.

Tom

On 28.11.13 17:31, Ghislain Mustermann wrote:
> http://download.eclipse.org/efxclipse/runtime-nightly/site has 0
> plug-ins available, is there some troubles??
>
> Well! i used feature in my product. But which one is better? Features vs
> Plug-Ins?
Re: Right way to use the embedded Guava Library? [message #1217382 is a reply to message #1216844] Thu, 28 November 2013 22:28 Go to previous message
Ghislain Mustermann is currently offline Ghislain MustermannFriend
Messages: 24
Registered: April 2013
Junior Member
Well my Target Plattform cannot reach the "runtime-nightly" site anymore. Now i set the location to eclipse_home.
Still having Error while i run my Product :

!ENTRY org.eclipse.osgi 2 0 2013-11-28 23:12:58.113
!MESSAGE Info: cycle(s) found while stopping bundles: [[org.eclipse.core.contenttype,org.eclipse.core.runtime,org.eclipse.equinox.registry,org.eclipse.equinox.preferences,org.eclipse.equinox.app]].
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.18.0:publish-products (default-publish-products) on project my.demo.app.product: Exception while publishing product C:\WS_DEMO\my.demo.app.product\my.demo.app.product.product: "publishing result": ["Included element my.demo.app.feature.feature.group 1.0.0.201311282212 is missing. Cannot determine filter for requirement to this element."] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.eclipse.tycho:tycho-p2-publisher-plugin:0.18.0:publish-products (default-publish-products) on project my.demo.app.product: Exception while publishing product C:\WS_DEMO\my.demo.app.product\my.demo.app.product.product
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleThreadedBuilder$1.call(LifecycleThreadedBuilder.java:167)
at org.apache.maven.lifecycle.internal.LifecycleThreadedBuilder$1.call(LifecycleThreadedBuilder.java:163)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:724)
Caused by: org.apache.maven.plugin.MojoExecutionException: Exception while publishing product C:\WS_DEMO\my.demo.app.product\my.demo.app.product.product
at org.eclipse.tycho.plugins.p2.publisher.PublishProductMojo.publishContent(PublishProductMojo.java:96)
at org.eclipse.tycho.plugins.p2.publisher.AbstractPublishMojo.execute(AbstractPublishMojo.java:38)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 13 more
Caused by: org.eclipse.tycho.p2.tools.FacadeException: "publishing result": ["Included element my.demo.app.feature.feature.group 1.0.0.201311282212 is missing. Cannot determine filter for requirement to this element."]
at org.eclipse.tycho.p2.tools.publisher.PublisherServiceImpl.handlePublisherStatus(PublisherServiceImpl.java:168)
at org.eclipse.tycho.p2.tools.publisher.PublisherServiceImpl.executePublisher(PublisherServiceImpl.java:157)
at org.eclipse.tycho.p2.tools.publisher.PublisherServiceImpl.publishProduct(PublisherServiceImpl.java:92)
at org.eclipse.tycho.plugins.p2.publisher.PublishProductMojo.publishContent(PublishProductMojo.java:92)
... 16 more
[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
Previous Topic:Linking to the fxgraph model from another xtext language
Next Topic:Using RBAC Pattern with e(fx)clipse
Goto Forum:
  


Current Time: Mon Nov 24 15:34:19 GMT 2014

Powered by FUDForum. Page generated in 0.01995 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software