Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Activator invalid problem
Activator invalid problem [message #104091] Sat, 19 January 2008 21:50 Go to next message
lancel lau is currently offline lancel lauFriend
Messages: 31
Registered: July 2009
Member
------=_Part_3065_21721527.1200779543602
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

Hi,
i have 2 simple bundles.one is HelloWorld bundle.in the start method of the second bundle i try to install the first bundle by using this:

String s = "File:../workspace/aaa/";
Bundle b = context.installBundle(s);

i got Exception:
org.osgi.framework.BundleException: The activator aaa.Activator for bundle aaa is invalid

but the bundle aaa runs well itself.
i am searching for the answer for a while.Can anyone give me suggestions about this?thanks.

regards
------=_Part_3065_21721527.1200779543602
Content-Type: application/octet-stream; name=aaa.zip
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename=aaa.zip

UEsDBAoAAAAAACayMzgAAAAAAAAAAAAAAAAEAAAAYWFhL1BLAwQUAAAACAAh sjM41Ryc0qUAAAAz
AQAADgAAAGFhYS8uY2xhc3NwYXRonY89C8IwFEVnBf9DyG6qm0NrEamgQ5VS Z6nJo43Gl5gP0X9v
VYouOri9ezmcy4vT60mRC1gnNSZ0zEaUAHItJNYJ3ZaL4YSm00E/5qpyzlS+ aUPvnQC9vZGjRJFQ
Zzklj/J1Rt9JrrEjta0ZcCWNA3YQnqkqIG/adbYqst18nZezZZ4Vf9iMAMa1 BWbhHKQFsVGhluh+
qXTwJvjOtpf4hOPo8/s7UEsDBBQAAAAIACGyMzj+5MiU4gAAAJgCAAAMAAAA YWFhLy5wcm9qZWN0
vZJBTwMhEIXPNvE/NHsv6K0Huk3UeNOYVH/AFMaVZhkIsI0/X0DWZrNp0kPj 7b3HvHwERmy/Tb88
og/a0qa5Z3fNEklapanbNB/vz6t1s21vF8J5e0AZnzBIr11M0ym9EQQGWwAQ vKgcSWsMUmwFH1VO
az8UwyduP+he7RzK7Kp9TFUgVZJKsb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8uY2xhc3NwYXRoUEsBAhQAFAAAAAgAIbIzOP7kyJTiAAAAmAIA AAwAAAAAAAAAAQAg
AAAA8wAAAGFhYS8ucHJvamVjdFBLAQIUAAoAAAAAACGyMzgAAAAAAAAAAAAA AAAOAAAAAAAAAAAA
EAAAAP8BAABhYWEvLnNldHRpbmdzL1BLAQIUABQAAAAIACGyMzjXjbdOdgAA AJgAAAAoAAAAAAAA
AAEAIAAAACsCAABhYWEvLnNldHRpbmdzL29yZy5lY2xpcHNlLnBkZS5jb3Jl LnByZWZzUEsBAhQA
CgAAAAAAJrIzOAAAAAAAAAAAAAAAAAgAAAAAAAAAAAAQAAAA5wIAAGFhYS9i aW4vUEsBAhQAFAAA
AAgAIbIzONJbYPs/AAAAUAAAABQAAAAAAAAAAQAgAAAADQMAAGFhYS9idWls ZC5wcm9wZXJ0aWVz
UEsBAhQACgAAAAAAIbIzOAAAAAAAAAAAAAAAAA0AAAAAAAAAAAAQAAAAfgMA AGFhYS9NRVRBLUlO
Ri9QSwECFAAUAAAACAAhsjM4XR+0rUwAAAB4AAAAGAAAAAAAAAABACAAAACp AwAAYWFhL01FVEEt
SU5GL01BTklGRVNULk1GUEsBAhQACgAAAAAAIbIzOAAAAAAAAAAAAAAAAAgA AAAAAAAAAAAQAAAA
KwQAAGFhYS9zcmMvUEsFBgAAAAAKAAoAaQIAAFEEAAAAAA==
------=_Part_3065_21721527.1200779543602
Content-Type: application/octet-stream; name=bh.zip
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename=bh.zip

UEsDBAoAAAAAAK2xMzgAAAAAAAAAAAAAAAADAAAAYmgvUEsDBBQAAAAIACKx MzjVHJzSpQAAADMB
AAANAAAAYmgvLmNsYXNzcGF0aJ2PPQvCMBRFZwX/Q8huqptDaxGpoEOVUmep yaONxpeYD9F/b1WK
Ljq4vXs5nMuL0+tJkQtYJzUmdMxGlAByLSTWCd2Wi+GEptNBP+aqcs5UvmlD 750Avb2Ro0SRUGc5
JY/ydUbfSa6xI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AAAAEAIAAAACoF
AABiaC9idWlsZC5wcm9wZXJ0aWVzUEsBAhQACgAAAAAAIrEzOAAAAAAAAAAA AAAAAAwAAAAAAAAA
AAAQAAAAmgUAAGJoL01FVEEtSU5GL1BLAQIUABQAAAAIACKxMzhJczQkhgAA AMgAAAAXAAAAAAAA
AAEAIAAAAMQFAABiaC9NRVRBLUlORi9NQU5JRkVTVC5NRlBLAQIUAAoAAAAA ACKxMzgAAAAAAAAA
AAAAAAAHAAAAAAAAAAAAEAAAAH8GAABiaC9zcmMvUEsBAhQACgAAAAAAIrEz OAAAAAAAAAAAAAAA
AAoAAAAAAAAAAAAQAAAApAYAAGJoL3NyYy9iaC9QSwECFAAUAAAACACpsTM4 XQdzAe4AAACDAgAA
GAAAAAAAAAABACAAAADMBgAAYmgvc3JjL2JoL0FjdGl2YXRvci5qYXZhUEsF BgAAAAAOAA4AXAMA
APAHAAAAAA==
------=_Part_3065_21721527.1200779543602--
Re: Activator invalid problem [message #104145 is a reply to message #104091] Sun, 20 January 2008 19:15 Go to previous messageGo to next message
Simon Kaegi is currently offline Simon KaegiFriend
Messages: 381
Registered: July 2009
Senior Member
Your Activator's start method is probably throwing an exception -- I'd guess
because of a problem with your URL.
Off the top of my head the protocol (file) might be case sensitive and
failing that you might try an absolute file location until you're sure
everything else is working.

To be sure I'd walk through your Activator's start method with a debugger.

HTH
-Simon


"lancel80" <lancelot2k4@hotmail.com> wrote in message
news:1487450.32211200779543604.JavaMail.root@cp1.dzone.com...
> Hi,
> i have 2 simple bundles.one is HelloWorld bundle.in the start method of
> the second bundle i try to install the first bundle by using this:
>
> String s = "File:../workspace/aaa/";
> Bundle b = context.installBundle(s);
>
> i got Exception:
> org.osgi.framework.BundleException: The activator aaa.Activator for bundle
> aaa is invalid
>
> but the bundle aaa runs well itself.
> i am searching for the answer for a while.Can anyone give me suggestions
> about this?thanks.
>
> regards
Re: Activator invalid problem [message #104183 is a reply to message #104145] Mon, 21 January 2008 10:19 Go to previous messageGo to next message
lancel lau is currently offline lancel lauFriend
Messages: 31
Registered: July 2009
Member
Hi Simon,
i have tried the absolute file location and i got the same result.

regards
Re: Activator invalid problem [message #104222 is a reply to message #104183] Mon, 21 January 2008 15:03 Go to previous messageGo to next message
Simon Kaegi is currently offline Simon KaegiFriend
Messages: 381
Registered: July 2009
Senior Member
Hmm... the framework is not succeeding when loading your Activator class.

This usually occurs because either your bundle's classpath is wrong (and the
framework can't find your Activator) or some dependency in your Activator is
not resolving.
I'd first take a look at your Bundle-ClassPath and Bundle-Activator name in
your manifest and make sure they're correct.

If that doesn't work I'd suggest using a debugger and setting a breakpoint
in org.eclipse.osgi.framework.internal.core.AbstractBundle.load Activator()
and walk through the loading of your Activator as this will give you a
chance to look at the underlying exception.

HTH
-Simon

"lancel80" <lancelot2k4@hotmail.com> wrote in message
news:23731244.34531200910802523.JavaMail.root@cp1.dzone.com...
> Hi Simon,
> i have tried the absolute file location and i got the same result.
>
> regards
Re: Activator invalid problem [message #104236 is a reply to message #104183] Mon, 21 January 2008 16:02 Go to previous message
lancel lau is currently offline lancel lauFriend
Messages: 31
Registered: July 2009
Member
It is solved.In this method

installBundle
public Bundle installBundle(java.lang.String location)
throws BundleException

location - The location identifier of the bundle to install

i have some misunderstanding about this parameter location.
i think it should be the directory of the bundle,actually it must be a jar file(a bundle file).

so this works fine:

String s = "File:c:\\plugins\\aaa.jar";
Bundle b = context.installBundle(s);

thanks
regards
Previous Topic:declarative services dependency injection questions
Next Topic:Getting Started with OSGi Webinar
Goto Forum:
  


Current Time: Sat Nov 09 03:39:32 GMT 2024

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

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

Back to the top