Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » AspectJ » Problem with Equinox Weaving in Virgo Tomcat
Problem with Equinox Weaving in Virgo Tomcat [message #1221800] Wed, 18 December 2013 13:08 Go to next message
Kevin Ng is currently offline Kevin NgFriend
Messages: 4
Registered: December 2013
Junior Member
Hi all,

I'm using equinox weaving to do aspect across OSGi bundles.My server is Virgo tomcat. Below exception occured when i start my plan:

Unable to satisfy dependencies of bundle 'org.eclipse.equinox.weaving.aspectj' at version '1.0.0.v20100503': Cannot resolve: org.eclipse.equinox.weaving.aspectj Resolver report: An Import-Package could not be resolved. Caused by missing constraint in bundle <org.eclipse.equinox.weaving.aspectj_1.0.0.v20100503> constraint: <Import-Package: org.eclipse.equinox.service.weaving; version="0.0.0">

http://dev.eclipse.org/mhonarc/lists/ajdt-dev/msg01552.html
https://bugs.eclipse.org/bugs/show_bug.cgi?id=333646
These two websites give some recommendations to fix this problem. But it doesn't work. Anyone can help me with it.

Thx
Kevin
Re: Problem with Equinox Weaving in Virgo Tomcat [message #1221890 is a reply to message #1221800] Wed, 18 December 2013 16:21 Go to previous messageGo to next message
Andrew Eisenberg is currently offline Andrew EisenbergFriend
Messages: 382
Registered: July 2009
Senior Member
The most likely cause is that your config.ini is not set up properly to load the org.eclipse.equinox.weaving.hook fragment. Try this. Start up with an osgi prompt (use the -console option) and type 'ss'. This will list your bundles and fradments. Do you see the hook fragment? If not, then it is not being loaded properly and you should fix your config.ini. If it is, then something else is the matter.
Re: Problem with Equinox Weaving in Virgo Tomcat [message #1221969 is a reply to message #1221890] Thu, 19 December 2013 01:51 Go to previous messageGo to next message
Kevin Ng is currently offline Kevin NgFriend
Messages: 4
Registered: December 2013
Junior Member
Hi Andrew

Thank u for ur reply. I follow ur step and org.eclipse.equinox.weaving.hook doesn't load. I have set
osgi.framework.extensions=org.eclipse.equinox.weaving.hook

i have also try to set the start level lower
osgi.bundles=org.eclipse.equinox.weaving.hook@1\:start

But it doesn't work yet. Attachment is my config.ini. Is there any problem

Thx
Kevin
  • Attachment: config.png
    (Size: 1.81MB, Downloaded 522 times)
Re: Problem with Equinox Weaving in Virgo Tomcat [message #1221977 is a reply to message #1221969] Thu, 19 December 2013 05:25 Go to previous messageGo to next message
Andrew Eisenberg is currently offline Andrew EisenbergFriend
Messages: 382
Registered: July 2009
Senior Member
Two things:

1. I don't see any osgi.framework.extensions entry. This is required in order for equinox to know about framework adapters.
2. Things may be different since you're using virgo. You may need to load framework adapters differently.
Re: Problem with Equinox Weaving in Virgo Tomcat [message #1223474 is a reply to message #1221977] Mon, 23 December 2013 13:54 Go to previous messageGo to next message
Kevin Ng is currently offline Kevin NgFriend
Messages: 4
Registered: December 2013
Junior Member
I've start org.eclipse.equinox.weaving.hook and org.eclipse.equinox.weaving.aspectj successfully by putting jars into virgo\plugins and modifying virgo\configuration\org.eclipse.equinox.simpleconfigurator\bundles.info. Bundles' state list below

id State Bundle
0 ACTIVE org.eclipse.osgi_3.8.1.v20120830-144521
Fragments=1, 2
1 RESOLVED org.eclipse.virgo.kernel.equinox.extensions_3.6.2.RELEASE
Master=0
2 RESOLVED org.eclipse.equinox.weaving.hook_1.0.200.I20130319-1000
Master=0
3 ACTIVE org.eclipse.equinox.weaving.aspectj_1.0.300.I20130319-1000
......
66 RESOLVED org.aspectj.weaver_1.7.3.20130613144500-a
67 RESOLVED org.aspectj.runtime_1.7.3.20130613144500-a
......

I'm sure my aspect bundle started erlier than target bundle. But aspect doesn't work
Re: Problem with Equinox Weaving in Virgo Tomcat [message #1223513 is a reply to message #1223474] Mon, 23 December 2013 16:20 Go to previous message
Andrew Eisenberg is currently offline Andrew EisenbergFriend
Messages: 382
Registered: July 2009
Senior Member
Hmmm...I wonder if this is a problem with Virgo and how it does classloading differently. I am not familiar with Virgo, so I can't really be sure.

Do you see log messages stating that the weaver and the hooks have been started? If you have logging turned on in your config.ini, you should see that information in the console.
Previous Topic:Equinox Weaving Missing Constraint
Next Topic:Circular dependencies
Goto Forum:
  


Current Time: Fri Apr 19 16:37:44 GMT 2024

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

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

Back to the top