Initial Release of prototype SAMP Hub
Alasdair Allan
aa at astro.ex.ac.uk
Wed May 7 14:03:52 PDT 2008
All,
Ahead of the Trieste meeting...
I've just completed a prototype SAMP Hub written in Perl, developed
against the IVOA working draft of the specification dated 2008-04-30
distributed on the apps-samp mailing lis, with additions such as the
argument order for the call( ) and callAll( ) methods taken from the
apps-samp mailing list over the last couple of days.
You can download it from
http://www.babilim.co.uk/software/SAMP_Hub.tar.gz
and testbed clients can be found at,
http://www.babilim.co.uk/software/SAMP_Clients.tar.gz
This is an initial first cut release of the SAMP Hub and as such
comes with no guarantees except there will be horrendous bugs. Also
since this is the first implementation of a Hub, it probably won't
play well with others, clients or hubs, either because of toolkit
issues or because my interpretation of the specification doesn't
entirely match other peoples. The software has been tested under OSX
Tiger and Ubuntu Linux 7.10.
You will need the following Perl modules installed to run the hub and
testbed clients,
XMLRPC::Lite
XML::Simple
DateTime
File::Spec
Carp
Data::Dumper
Getopt::Long
Socket
Net::Domain
POSIX
Errno
depending on your version of Perl some (but not all) of these will
ship with the core distribution. The rest can be obtained from CPAN
(http://search.cpan.org/). I think I've caught all the dependancies,
but if you notice any I haven't listed any let me know I've forgotten
them.
There is no documentation. Many of the Perl modules have inline POD,
however most of it didn't keep up with the pace of development so
it's out of date. However, once you install the additional modules,
open up a terminal window and start the Hub as follows,
% tar -zxvf SAMP_Hub.tar.gz
% cd SAMP_Hub/
% ./samp_hub.pl
you can put the Hub through its paces by opening up two more terminal
windows and running the testbed clients. You should start the
listener client in all cases,
% tar -zxvf SAMP_Clients.tar.gz
% cd SAMP_Clients/
% ./listener_client.pl
this is the test client that listens for notify( ) and call( )'s from
the Hub.
In the second window you can either start the client that exercises
the notify( ) method, or the other than exercises the call( ) method. So
% cd SAMP_Clients/
% ./callAll_test.pl
or
% cd SAMP_Clients/
% ./notifyAll_test.pl
These two clients have a heart beat which will dispatch a call or a
notification periodically. The first heartbeat will happen 15 seconds
(or so) after the client has completed its registering with the Hub.
It should be noted that the initial Hub implementation does NOT
implement callAndWait( ) pending discussion of asynchronous vs
synchronous messaging, either on the apps-samp mailing list or at the
Tieste meeting itself.
I'm interested in hearing from other Hub implementors, or people
putting together SAMP client support, whether what I've generated
interoperates okay with your implementation. It won't, but it'd be
nice to get close...
Cheers,
Al.
More information about the apps-samp
mailing list