RE: interrupt java rpc execution

From: josh singer <josh.singer_at_parc-technologies.com>
Date: Wed 09 Jan 2002 02:52:55 PM GMT
Message-ID: <0B9686DD2E83D411B67200508B9A9DA255F7B1@LON-SRV2>
Dear Heiko,

We considered the very same question in relation to Parc Technologies'
applications a few months ago. The solution which was agreed on (though I
don't think it has been implemented yet) was somewhat involved, but has the
advantage of being applicable to both EmbeddedEclipse and
RemoteEclipse/OutOfProcessEclipse. It is basically a "polling" solution,
which reflects the synchronous nature of the Java-ECLiPSe interface. 

On the Java side you have a ToEclipseQueue which is used solely to signal
abort messages from Java. You have a QueueListener on this queue. Whenever
the dataRequest method of this QueueListener is invoked, it writes a message
which means either "abort" or "continue" on the queue. Which of these is
sent can depend on the state of a boolean on the Java side, which can be set
by a method running in a thread other than the thread which called rpc (e.g.
the event thread).

On the Eclipse side you set up an "after-event timer" which posts an event
at regular time intervals. The handler of this event reads from the Eclipse
end of the ToEclipseQueue mentioned above. If it reads "continue", it
succeeds; if it reads "abort", it throws an error. 

If you implement this, do get back to us with any feedback as we were
considering at one stage writing an ECLiPSe library to set it up, although
there are no immediate plans to do so.

Hope this helps, 

Josh Singer


Developer, Parc Technologies Limited
josh.singer@parc-technologies.com
http://www.parc-technologies.com

This e-mail message is for the sole use of the intended recipient(s)
-its contents are the property of Parc Technologies Limited (or its
licensors) and are confidential. Please do not copy, review, use
(except for the intended purposes), disclose or distribute the e-mail
or its contents (or allow anyone else to do so) without our prior
permission. Parc Technologies Limited does not guarantee that this
e-mail has not been intercepted and amended nor that it is
virus-free. You should carry out your own virus checks before opening
any attachment.  Any opinions expressed in this e-mail message are
those of the author and not necessarily Parc Technologies Limited.


-----Original Message-----
From: Heiko Lötzbeyer [mailto:heiko@loetzbeyer.de]
Sent: Wednesday, January 09, 2002 12:34 PM
To: eclipse-users@icparc.ic.ac.uk
Subject: [eclipse-users] interrupt java rpc execution


Hello,

is it possible to interrupt a java rpc execution?
(e.g. send an interrupt event to eclipse?)
Or is there any other possibility to terminate a
long running eclipse execution?

Thanks,

Heiko

P.S: I use the embedded eclipse engine.
Received on Wed Jan 09 14:52:59 2002

This archive was generated by hypermail 2.1.8 : Wed 16 Nov 2005 06:07:12 PM GMT GMT