Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Late startup?
Late startup? [message #1714423] Thu, 12 November 2015 09:58 Go to next message
Eclipse UserFriend
I haven't quite been able to sort out the Google magic to find an answer for this myself...

I know that Eclipse has a mechanism for starting bundles on start up in the form of the IStartup with its earlyStartup method.

Is there a notion of "late startup"?

I have something that I'd like to run every time Eclipse starts up, but I don't need it to start immediately. Some mechanism that activates the bundle sometime after everything else is running would be perfect.

I know that I can create a lightweight bundle that starts early and use a workspace job to make the good stuff happen later. Is there a better (lazier) option?

I don't need a lot of detail in an answer. Just a pointer if you have one.

Thanks,

Wayne
Re: Late startup? [message #1714429 is a reply to message #1714423] Thu, 12 November 2015 11:10 Go to previous message
Eclipse UserFriend
Wayne,

Comments below.

On 12/11/2015 3:58 PM, Wayne Beaton wrote:
> I haven't quite been able to sort out the Google magic to find an
> answer for this myself...
>
> I know that Eclipse has a mechanism for starting bundles on start up
> in the form of the IStartup with its earlyStartup method.
Yes, though it's actually not so early. I.e., it's called after the
workbench is up and running and has presented its face to the user.
>
> Is there a notion of "late startup"?
I think the current mechanism is late enough!
>
> I have something that I'd like to run every time Eclipse starts up,
> but I don't need it to start immediately. Some mechanism that
> activates the bundle sometime after everything else is running would
> be perfect.
Then it should be a good fit. Furthermore, it's called on a background
thread so you can do work that will not interfere with the activities of
the display thread.
>
> I know that I can create a lightweight bundle that starts early and
> use a workspace job to make the good stuff happen later. Is there a
> better (lazier) option?
That's not a good option, best to use IStartup. There you can also
create a Job and schedule it with a delay
org.eclipse.core.runtime.jobs.Job.schedule(long) with this mechanism
you can kick something off arbitrarily long after the workbench as
displayed itself.

In the ideal world, UI contributions would be more careful about doing
lots of work in the bundle start and use this mechanism instead. UI
bundles tend to run start on the UI thread and kick in early, preventing
the workbench from coming up quickly...
>
> I don't need a lot of detail in an answer. Just a pointer if you have
> one.
>
> Thanks,
>
> Wayne
Previous Topic:Get menu button with specific id
Next Topic:Set minimum width of a view
Goto Forum:
  


Current Time: Tue Apr 15 02:52:17 EDT 2025

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

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

Back to the top