Msg#: 4024709 posted 1:31 am on Nov 14, 2009 (gmt 0)
I am building a Web interface to monitor an embedded system. I have built a Perl script which runs remote commands and gathers output from that system. Now what i need is a Web interface which makes calls to this script(executes remotes command) and displays data on the web page.
First of all, i need to make my script as a daemon process which can accept requests from the server. I can choose any Server side technology till it can communicate with this Perl script. To keep it simple, i can choose Perl/CGI which can talk to this daemon Perl script.
What is the best way to communicate with this Daemon script. I haven't decided on how the communication needs to be..Sockets or anything else...any suggestions? Are there Perl modules already available which can make my message passing simpler? I can have the Web Page submit actual remote commands which needs to be passed to the Perl script which executes on the embedded system and returns me the result.
Msg#: 4024709 posted 3:47 pm on Nov 15, 2009 (gmt 0)
the communication can be whatever you want it to be. if you don't mind the overhead, you could simply use HTTP. making your script a HTTP-daemon is easy with HTTP::Daemon (or any of the other httpd-modules), and querying it with REST-style queries and LWP::UserAgent shouldn't be too hard as well. Of course, it heavily depends on your performance needs, how many concurrent connections are to be handled etc.