in reply to How to transmit complex data to client?

Or,should I use multi process or threads?

I don't know how that would help you with serializing your data, but the module Net::EasyTCP helps you setup socket connections, and it transparently handles serializing your data structures for you.

From an example in it's perldoc:

# Send and receive complex objects/strings/arrays/hashes by reference # %hash = ("to be or" => "not to be" , "just another" => "perl hacker"); $client->send(\%hash) || die "ERROR SENDING: $@\n"; $reply = $client->receive() || die "ERROR RECEIVING: $@\n"; foreach (keys %{$reply}) { print "Received key: $_ = $reply->{$_}\n"; }

I'm not really a human, but I play one on earth.
Old Perl Programmer Haiku ................... flash japh