jinterface problems

Joakim G. jocke@REDACTED
Tue Mar 11 21:17:10 CET 2003


XML-RPC could be an alternative as well:

An Erlang XML-RPC lib: http://www.gleipnir.com/xmlrpc/
A Java XML-RPC lib: http://ws.apache.org/xmlrpc/

An example Fibonacci XML-RPC server in Erlang:
http://www.gleipnir.com/xmlrpc/unpacked/LATEST/examples/fib_server.erl
A Java XML-RPC client using the above example Erlang server:
http://www.gleipnir.com/xmlrpc/unpacked/LATEST/examples/FibClient.java

Cheers
/Jocke

Luke Gorrie wrote:

>Rasmus Jonsson <rasmus_jonsson@REDACTED> writes:
>
>  
>
>>What we actually are trying to accomplish is to let any client
>>(anywhere) download an java applet over http from a inets server on
>>the erlang node, and then we want the java applet and the e-node to
>>start communica- ting. (here we cannot require any empd running on
>>the client!)
>>    
>>
>
>I think that jinterface is the right way, but I would suggest using
>your own protocol instead of distributed Erlang. You can do this by
>opening a regular TCP socket and the Otp{Input,Output}Stream in Java
>and term_to_binary/binary_to_term in Erlang to translate between
>Erlang terms and binary data (for sending over sockets.)
>
>Two good things about this approach: the networking part is simple and
>predictable (you open the socket however you like), and you have
>control over what messages are sent and how they are
>processed. Security-wise, giving someone access to your Erlang node
>via distribution is equivalent to giving them a shell on your machine,
>so if you used distributed Erlang you should be very careful about who
>you let run the applet.
>
>The other main option for Java<->Erlang communication is UBF:
>http://www.sics.se/~joe/ubf/site/home.html (more experimental, but
>generally simpler.)
>
>Cheers,
>Luke
>  
>





More information about the erlang-questions mailing list