erlang <-> pvm

Joe Armstrong joe@REDACTED
Mon Oct 4 15:02:22 CEST 2004


   I think the "easiest" (TM) way  to do this would be to implement the
pvmd protocol  itself in Erlang. Sending and  receiving messages from
TCP/UDP  ports in  Erlang is  very easy  (especially using  the binary
syntax).

   If you use libraries in C/perl/whatever to do this for you you'll end up
with fighting the problem of "how to interface Erlang to C/perl/whatever ..."
instead of interfacing Erlang to pvm.

   The  direct method  using sockets  and doing  all the  protocol work
yourself should be much easier than using some C/perl... library - this
is because the  Erlang concurrency model matches very  nicely with the
pvm  concurrency model. In  C/perl/.../any sequential  language you'll
have to simulate concurrency with callbacks.

   I spent 10 minutes Googeling to see if I could find the PVM protocol
specification - but  I couldn't find it <<  amazing the most important
document of all is missing >> - in the PVM distribution there is a file
pvmproto.h which describes the inter-machine pvm *packets* (but not the
*protocol*).

   If  (and it's  a big  if)  the entire  protocol is  as described  in
pvmproto.h  and if  the protocol  is stateless  (meaning that  the PMV
machine  can receive  any of  these protocol  packets in  any internal
state) then your problem looks to be rather simple.

  Just code up the protocol as implied by pvmproto.h and send message to
the appropriate PVM port.

  BTW - if you make any progress on this please let us know.

   I'm  specifically interested  in any  pointers to  the  PVM protocol
specification -  I had  hoped to find  a short document  defining the
protocol  and the  ports  etc.  that  it  uses.  Give  such a  document
Erlangizing the interface  should be easy. (failing this  you'd have to
read the PVM code, always a painful alternative)

   Cheers

   /Joe


On Mon, 4 Oct 2004, Dietmar Admin Schaefer wrote:

> Hi !
>
>
> I have a very special problem !
>
> I need to read and send messages between a system using pvm as the message 
> passing method
> and erlang processes.
>
> My first idea was to use perl as a glue because perl can read/write pvm 
> messages and can send
> messages to erlang processes using sockets.
>
> I now find this solution a little bit dissatisfactory.
>
>
> Does anybody out there know how to directly connect erlang to pvm  ???
>
> HOw much afford would it be ?
>
>
>
> Regards
>
>
>
> Dietmar
>
>



More information about the erlang-questions mailing list