0

The software I'm working on uses SOAP::Lite and XML::Parser to communicate with a web service. We are looking into support older machines, but currently cannot because SOAP::Lite requires that OpenSSL be installed and uses XML::Parser which requires that "expat" be installed.

These older machines (Solaris 9) do not have 'expat' in the base install and our users are hesitant about modifying these machines for any reason.

Is there an easy to use non-SSL/non-expat solution for web service communication? Perhaps using LWP::UserAgent and some non-XML data packets?

wsaxton
  • 1,030
  • 15
  • 34
  • 1
    how about `JSON`? Storable/Data::Dumper if perl is on both sides? – mpapec Oct 21 '13 at 15:55
  • The other side is written in Java. I'm actually having my backend engineer try to modify the web service to communicate via JSON to test this out. Do you think LWP::UserAgent via JSON is the way to go? – wsaxton Oct 21 '13 at 16:10
  • you have to answer this question, it is doable but I would first try to install newer perl (perhaps system independent one http://perlbrew.pl/) – mpapec Oct 21 '13 at 16:16
  • 1
    @mpapec Why should installing a newer perl help here? For example, JSON-XS supports 5.8.2 and I think Solaris has perl 5.8.4 installed. Pure perl JSON supports even 5.6.x. And installing a newer perl won't help for the lack of the expat library. – Slaven Rezic Oct 21 '13 at 20:37
  • @SlavenRezic as OP wrote, `and uses XML::Parser which requires that "expat" be installed. These older machines (Solaris 9) do not have these in the base install.` – mpapec Oct 22 '13 at 05:16
  • @mpapec expat is a system library. Installing a new perl won't give you that library. But one can follow the instructions in http://stackoverflow.com/questions/9693031/how-to-install-xmlparser-without-expat-devel about manually installing expat. – Slaven Rezic Oct 22 '13 at 05:27
  • @SlavenRezic Correct, I clarified the issue with expat in the OP. I'm capable of installing 'expat' pretty easily, but I'm just not allowed to on these systems so XML::Parser won't work. – wsaxton Oct 22 '13 at 16:48

3 Answers3

0

If you are looking for a very simple Perl LWP::UserAgent based SOAP client to communicate to a server then this page may be of interest...

http://users.skynet.be/pascalbotte/rcx-ws-doc/perlpost.htm

Personally, I don't really like the idea of having to encode and decode the SOAP data packets myself, but for simple transactions it may meet your requirements.

Rick Sarvas
  • 769
  • 10
  • 20
0

I think my best bet is to use LWP::UserAgent and communicate via JSON. Thanks for the help "brainstorming" in the comments.

wsaxton
  • 1,030
  • 15
  • 34
0

May not be your cup of tea, but check out RPC::ExtDirect and RPC::ExtDirect::Client. Cheap, ready to use RPC interface that just works; the server side should be compatible with perls down to 5.6.

Alex Tokarev
  • 4,821
  • 1
  • 20
  • 30