Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Canceling running jobs
Canceling running jobs [message #760420] Fri, 02 December 2011 10:29 Go to next message
Louzorios Missing name is currently offline Louzorios Missing nameFriend
Messages: 4
Registered: November 2011
Junior Member
Hello

How can i cancel running jobs in my RCP application. Because when i run it for the second time i get the following error message.
"MESSAGE Job found still running after platform shutdown. Jobs should be canceled by the plugin that scheduled them during shutdown: org.eclipse.ui.internal.AbstractWorkingSetManager$10
Job found still running after platform shutdown. Jobs should be canceled by the plugin that scheduled them during shutdown: org.eclipse.ui.internal.AbstractWorkingSetManager$10"
and it get closed by itself.

Thank you
Re: Canceling running jobs [message #760426 is a reply to message #760420] Fri, 02 December 2011 10:47 Go to previous messageGo to next message
Daniel Krügler is currently offline Daniel KrüglerFriend
Messages: 853
Registered: July 2009
Senior Member
On 2011-12-02 11:29, Louzorios wrote:
> Hello
>
> How can i cancel running jobs in my RCP application. Because when i run
> it for the second time i get the following error message.
> "MESSAGE Job found still running after platform shutdown. Jobs should be
> canceled by the plugin that scheduled them during shutdown:
> org.eclipse.ui.internal.AbstractWorkingSetManager$10
> Job found still running after platform shutdown. Jobs should be canceled
> by the plugin that scheduled them during shutdown:
> org.eclipse.ui.internal.AbstractWorkingSetManager$10" and it get closed
> by itself.

You have studied the API and did not found the function "cancel()"? That
is indeed curious!

But when using this function you need to be aware that calling cancel()
returns a value that determines whether it succeeded or. It will return
false when your job is still running. In this case you need to produce
your own synchronization mechanisms to wait for the job being ready -
this will also depend on how cooperative the actual operation that is
running (checking the progress monitor for cancel state and reacting
correctly on that).

HTH & Greetings from Bremen,

- Daniel Krügler
Re: Canceling running jobs [message #760457 is a reply to message #760426] Fri, 02 December 2011 12:53 Go to previous message
Louzorios Missing name is currently offline Louzorios Missing nameFriend
Messages: 4
Registered: November 2011
Junior Member
Thanks, but what 'im looking for is a solution to cancel all the running jobs of the application when i close it. For example : to do something inside this function :

public void postWindowClose() {
//closing the running jobs..
}
Previous Topic:Pass object to a View (via Constructor)
Next Topic:Eclipse RCP template with EMF, databinding etc.
Goto Forum:
  


Current Time: Mon Dec 22 22:53:34 GMT 2014

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

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