Home » Eclipse Projects » Plugin Development Environment (PDE) » Problems with product plug-in start level configuration form
|
Re: Problems with product plug-in start level configuration form [message #59180 is a reply to message #59154] |
Fri, 01 May 2009 12:52 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) ![Go to next message Go to next message](theme/Solstice/images/down.png) |
Chris Aniszczyk![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=caniszczyk%40gmail.com) Messages: 674 Registered: July 2009 |
Senior Member |
|
|
Eric Jain wrote:
> In 3.5M6 there appears to be a form in the product configuration edit
> page where one can list plug-ins that need to be auto-started (along
> with their start levels). There is an existing bug report (resolved for
> M7, apparently) about the launcher ignoring these settings, but I've run
> into two other problems:
>
> 1. The Start-Level and Auto-Start fields are read only. (Work-around:
> Edit source...)
>
> 2. If I list even one plug-in, the application fails with this exception:
>
> "java.lang.IllegalStateException: Unable to acquire application
> service. Ensure that the org.eclipse.core.runtime bundle is resolved and
> started (see config.ini)."
>
> Looking into the config.ini, I see that the following entry has been
> replaced with a long list of bundles, none of which has :start!
>
>
> osgi.bundles=reference\:file\:org.eclipse.equinox.simpleconfigurator.jar@1\:start
>
>
> Is this behavior expected? If not, might this already be fixed in the
> upcoming milestone release, or should I create a bug report?
So that behavior is fine, simpleconfigurator is being used since you
included it in your product definition somehow. Under the covers, p2 is
used to managed your bundles and a bundle.info is created that lists all
the bundles along with proper start levels.
One thing you have to becareful about is ensuring your start levels are
properly set for bundles like core.runtime and equinox.common if you're
building an RCP application. The launch configurations in Eclipse
generally set these bundles to their appropriate start levels. One thing
I recommend for people is if they have a launch configuration working
with their product, they can create a new product definition from a
LAUNCH CONFIGURATION and by doing that, it should set the proper start
levels in the definition itself.
Does that help?
Also, I'd wait until M7 as there were a few holes that had to be ironed
out with that functionality which you noticed :)
Cheers,
Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
|
|
|
Re: Problems with product plug-in start level configuration form [message #59303 is a reply to message #59180] |
Sat, 02 May 2009 18:00 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) ![Go to next message Go to next message](theme/Solstice/images/down.png) |
Eric Jain![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=eric.jain%40gmail.com) Messages: 266 Registered: July 2009 |
Senior Member |
|
|
Chris Aniszczyk wrote:
> So that behavior is fine, simpleconfigurator is being used since you
> included it in your product definition somehow. Under the covers, p2 is
> used to managed your bundles and a bundle.info is created that lists all
> the bundles along with proper start levels.
Sorry for being unclear: simpleconfigurator is only being used as long as
I *don't* specify any bundles in the configuration page of the product
editor. If I list even one bundle,
osgi.bundles=[...]simpleconfigurator.jar@1:start is replaced with a long
list of all bundles, and none has "start". Looks like a bug to me, but
this may already be fixed in M7?
I've also tried placing a p2.inf file with "instructions.install =
markStarted(started:true);" into the META-INF of a bundle that I'd like to
have started automatically. Even though the file appears to be processed
by the build script (there is an error if I mess up the syntax), this
doesn't mark the bundle as started in the generated bundles.info file...
> One thing you have to becareful about is ensuring your start levels are
> properly set for bundles like core.runtime and equinox.common if you're
> building an RCP application. The launch configurations in Eclipse
> generally set these bundles to their appropriate start levels. One thing
> I recommend for people is if they have a launch configuration working
> with their product, they can create a new product definition from a
> LAUNCH CONFIGURATION and by doing that, it should set the proper start
> levels in the definition itself.
If I launch the product from Eclipse and tell it to generate a config.ini
file, there is the same problem as with the headless build. Again, if I
don't list any bundles and start levels in the product configuration page,
all is fine.
btw are there plans to let a launch configuration use the bundles and
start levels defined in the product file, or will this information still
have to be maintained in duplicate?
|
|
|
Re: Problems with product plug-in start level configuration form [message #59378 is a reply to message #59303] |
Sat, 02 May 2009 21:00 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) ![Go to next message Go to next message](theme/Solstice/images/down.png) |
Chris Aniszczyk![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=caniszczyk%40gmail.com) Messages: 674 Registered: July 2009 |
Senior Member |
|
|
Eric Jain wrote:
> Sorry for being unclear: simpleconfigurator is only being used as long
> as I *don't* specify any bundles in the configuration page of the
> product editor. If I list even one bundle,
> osgi.bundles=[...]simpleconfigurator.jar@1:start is replaced with a long
> list of all bundles, and none has "start". Looks like a bug to me, but
> this may already be fixed in M7?
This is the way the logic works in PDE when self-hosting:
If you have simpleconfigurator in your list of bundles in the
dependencies page via a bundle or feature, we will use p2 and generate a
proper bundles.info file.
If you have update.configurator, we will use that (not recommended)
If you don't list any configurator, we will simply write out all the
bundles and their proper start levels in the osgi.bundles property.
There is no management of bundles via a configurator with this approach.
This isn't generally recommend either unless you have a specific use
case of your app not being updated (or via something that isn't p2 or
Update).
If you include both configurators by accident, PDE will choose
simpleconfigurator (p2).
> I've also tried placing a p2.inf file with "instructions.install =
> markStarted(started:true);" into the META-INF of a bundle that I'd like
> to have started automatically. Even though the file appears to be
> processed by the build script (there is an error if I mess up the
> syntax), this doesn't mark the bundle as started in the generated
> bundles.info file...
PDE doesn't look at p2.inf files when generating launch configurations
or the bundles.info when self-hosting. You're free to open a bug about
this, but it probably won't get addressed in 3.5... you should really be
used the product definition to drive start levels imho
> If I launch the product from Eclipse and tell it to generate a
> config.ini file, there is the same problem as with the headless build.
> Again, if I don't list any bundles and start levels in the product
> configuration page, all is fine.
Can you be more specific what the problem is?
> btw are there plans to let a launch configuration use the bundles and
> start levels defined in the product file, or will this information still
> have to be maintained in duplicate?
When you launch from the product definition, PDE should sync the launch
configuration with the correct start level information.
Please try out your scenarios with Eclipse 3.5 M7 which just came out
today. It would be great if you could report back :)
http://eclipsesource.com/blogs/2009/05/02/eclipse-35m7-is-ou t/
Cheers,
Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
|
|
| | | |
Re: Problems with product plug-in start level configuration form [message #596647 is a reply to message #59154] |
Fri, 01 May 2009 12:52 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) |
Chris Aniszczyk![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=caniszczyk%40gmail.com) Messages: 674 Registered: July 2009 |
Senior Member |
|
|
Eric Jain wrote:
> In 3.5M6 there appears to be a form in the product configuration edit
> page where one can list plug-ins that need to be auto-started (along
> with their start levels). There is an existing bug report (resolved for
> M7, apparently) about the launcher ignoring these settings, but I've run
> into two other problems:
>
> 1. The Start-Level and Auto-Start fields are read only. (Work-around:
> Edit source...)
>
> 2. If I list even one plug-in, the application fails with this exception:
>
> "java.lang.IllegalStateException: Unable to acquire application
> service. Ensure that the org.eclipse.core.runtime bundle is resolved and
> started (see config.ini)."
>
> Looking into the config.ini, I see that the following entry has been
> replaced with a long list of bundles, none of which has :start!
>
>
> osgi.bundles=reference\:file\:org.eclipse.equinox.simpleconfigurator.jar@1\:start
>
>
> Is this behavior expected? If not, might this already be fixed in the
> upcoming milestone release, or should I create a bug report?
So that behavior is fine, simpleconfigurator is being used since you
included it in your product definition somehow. Under the covers, p2 is
used to managed your bundles and a bundle.info is created that lists all
the bundles along with proper start levels.
One thing you have to becareful about is ensuring your start levels are
properly set for bundles like core.runtime and equinox.common if you're
building an RCP application. The launch configurations in Eclipse
generally set these bundles to their appropriate start levels. One thing
I recommend for people is if they have a launch configuration working
with their product, they can create a new product definition from a
LAUNCH CONFIGURATION and by doing that, it should set the proper start
levels in the definition itself.
Does that help?
Also, I'd wait until M7 as there were a few holes that had to be ironed
out with that functionality which you noticed :)
Cheers,
Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
|
|
|
Re: Problems with product plug-in start level configuration form [message #596685 is a reply to message #59180] |
Sat, 02 May 2009 18:00 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) |
Eric Jain![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=eric.jain%40gmail.com) Messages: 266 Registered: July 2009 |
Senior Member |
|
|
Chris Aniszczyk wrote:
> So that behavior is fine, simpleconfigurator is being used since you
> included it in your product definition somehow. Under the covers, p2 is
> used to managed your bundles and a bundle.info is created that lists all
> the bundles along with proper start levels.
Sorry for being unclear: simpleconfigurator is only being used as long as
I *don't* specify any bundles in the configuration page of the product
editor. If I list even one bundle,
osgi.bundles=[...]simpleconfigurator.jar@1:start is replaced with a long
list of all bundles, and none has "start". Looks like a bug to me, but
this may already be fixed in M7?
I've also tried placing a p2.inf file with "instructions.install =
markStarted(started:true);" into the META-INF of a bundle that I'd like to
have started automatically. Even though the file appears to be processed
by the build script (there is an error if I mess up the syntax), this
doesn't mark the bundle as started in the generated bundles.info file...
> One thing you have to becareful about is ensuring your start levels are
> properly set for bundles like core.runtime and equinox.common if you're
> building an RCP application. The launch configurations in Eclipse
> generally set these bundles to their appropriate start levels. One thing
> I recommend for people is if they have a launch configuration working
> with their product, they can create a new product definition from a
> LAUNCH CONFIGURATION and by doing that, it should set the proper start
> levels in the definition itself.
If I launch the product from Eclipse and tell it to generate a config.ini
file, there is the same problem as with the headless build. Again, if I
don't list any bundles and start levels in the product configuration page,
all is fine.
btw are there plans to let a launch configuration use the bundles and
start levels defined in the product file, or will this information still
have to be maintained in duplicate?
|
|
|
Re: Problems with product plug-in start level configuration form [message #596717 is a reply to message #59303] |
Sat, 02 May 2009 21:00 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) |
Chris Aniszczyk![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=caniszczyk%40gmail.com) Messages: 674 Registered: July 2009 |
Senior Member |
|
|
Eric Jain wrote:
> Sorry for being unclear: simpleconfigurator is only being used as long
> as I *don't* specify any bundles in the configuration page of the
> product editor. If I list even one bundle,
> osgi.bundles=[...]simpleconfigurator.jar@1:start is replaced with a long
> list of all bundles, and none has "start". Looks like a bug to me, but
> this may already be fixed in M7?
This is the way the logic works in PDE when self-hosting:
If you have simpleconfigurator in your list of bundles in the
dependencies page via a bundle or feature, we will use p2 and generate a
proper bundles.info file.
If you have update.configurator, we will use that (not recommended)
If you don't list any configurator, we will simply write out all the
bundles and their proper start levels in the osgi.bundles property.
There is no management of bundles via a configurator with this approach.
This isn't generally recommend either unless you have a specific use
case of your app not being updated (or via something that isn't p2 or
Update).
If you include both configurators by accident, PDE will choose
simpleconfigurator (p2).
> I've also tried placing a p2.inf file with "instructions.install =
> markStarted(started:true);" into the META-INF of a bundle that I'd like
> to have started automatically. Even though the file appears to be
> processed by the build script (there is an error if I mess up the
> syntax), this doesn't mark the bundle as started in the generated
> bundles.info file...
PDE doesn't look at p2.inf files when generating launch configurations
or the bundles.info when self-hosting. You're free to open a bug about
this, but it probably won't get addressed in 3.5... you should really be
used the product definition to drive start levels imho
> If I launch the product from Eclipse and tell it to generate a
> config.ini file, there is the same problem as with the headless build.
> Again, if I don't list any bundles and start levels in the product
> configuration page, all is fine.
Can you be more specific what the problem is?
> btw are there plans to let a launch configuration use the bundles and
> start levels defined in the product file, or will this information still
> have to be maintained in duplicate?
When you launch from the product definition, PDE should sync the launch
configuration with the correct start level information.
Please try out your scenarios with Eclipse 3.5 M7 which just came out
today. It would be great if you could report back :)
http://eclipsesource.com/blogs/2009/05/02/eclipse-35m7-is-ou t/
Cheers,
Chris Aniszczyk | EclipseSource Austin | +1 860 839 2465
http://twitter.com/eclipsesource | http://twitter.com/caniszczyk
|
|
| | | |
Goto Forum:
Current Time: Fri Aug 16 20:11:38 GMT 2024
Powered by FUDForum. Page generated in 0.05025 seconds
|