--- AnyEvent-MP/MP.pm 2009/11/08 23:58:02 1.105 +++ AnyEvent-MP/MP.pm 2010/06/21 15:09:34 1.116 @@ -32,7 +32,7 @@ # create a port on another node my $port = spawn $node, $initfunc, @initdata; - # destroy a prot again + # destroy a port again kil $port; # "normal" kill kil $port, my_error => "everything is broken"; # error kill @@ -157,7 +157,7 @@ use base "Exporter"; -our $VERSION = 1.23; +our $VERSION = 1.29; our @EXPORT = qw( NODE $NODE *SELF node_of after @@ -193,6 +193,9 @@ to know is its own name, and optionally it should know the addresses of some other nodes in the network to discover other nodes. +The key/value pairs are basically the same ones as documented for the +F command line utility (sans the set/del prefix). + This function configures a node - it must be called exactly once (or never) before calling other AnyEvent::MP functions. @@ -494,7 +497,7 @@ callbacks, i.e. runtime errors will cause the port to get Ced. The effect is basically as if it returned C<< sub { peval $SELF, sub { -BLOCK } } >>. +BLOCK }, @_ } >>. This is useful when you register callbacks from C callbacks: @@ -652,12 +655,12 @@ Kill the specified port with the given C<@reason>. -If no C<@reason> is specified, then the port is killed "normally" (ports -monitoring other ports will not necessarily die because a port dies -"normally"). +If no C<@reason> is specified, then the port is killed "normally" - +monitor callback will be invoked, but the kil will not cause linked ports +(C form) to get killed. -Otherwise, linked ports get killed with the same reason (second form of -C, see above). +If a C<@reason> is specified, then linked ports (C +form) get killed with the same reason. Runtime errors while evaluating C callbacks or inside C blocks will be reported as reason C<< die => $@ >>. @@ -951,8 +954,8 @@ Strings can easily be printed, easily serialised etc. and need no special procedures to be "valid". -And as a result, a miniport consists of a single closure stored in a -global hash - it can't become much cheaper. +And as a result, a port with just a default receiver consists of a single +closure stored in a global hash - it can't become much cheaper. =item Why favour JSON, why not a real serialising format such as Storable? @@ -978,7 +981,7 @@ L - more, lower-level, stuff. -L - network maintainance and port groups, to find +L - network maintenance and port groups, to find your applications. L - establish data connections between nodes.