Reliable way to handle Java node crashs?

zabrane Mikael zabrane3@REDACTED
Thu Jun 17 15:45:33 CEST 2010


Hi List,

I've a java node waiting for some "data messages" from an Erlang node.
As soon as a "data message" arrives, it gets processed by this Java node
(very intensive data processing).
Occasionally, this Java node crashes during the processing phase and the
Erlang node never gets back any response. All my system hangup.
The Erlang part can send only one message at any time and must wait for a
response before sending the next one (this is my current design of the
system)
to the Java node.

Questions:
1. How can i start my "Java node" automatically from within Erlang?
Currently, I'm running the Java node manually on a separate shell, wait for
it to open
its mailbox. Then, i run the Erlang code in another shell. This is a real
nightmare to handle the "restarts" manually when the Java node crashes.

2. What's the best way to robustify my Java node so it'll never stop even
after a crash? The ideal for me is to get it send back an {error, Reason}
message
to Erlang node and wait for a next message to process.

Code snippet will be very welcome guys !

Thanks in advance
-- 
Regards
Zabrane


More information about the erlang-questions mailing list