As sometimes happens in the life of a consultant, I was asked to investigate how to write some utility for mobile phones. After some
brief research, it appears that most widely supported tool for this kind
of development is java. So I downloaded many, many megabytes of SDKs
from Sun, including the Sun ONE studio (which is an insane IDE. Why the
heck do I “mount” a “local directory” instead of simply opening files and
directories? Is it because the network is the computer? Sun, your
terminology can bite me). I also grabbed a copy of the SOAP library kSOAP from Enhydra.
After an hour of tweedling (and some small patches to Enhydra’s stock quote demo), I got an existing cell phone java application (undeftly called a ‘MIDlet’) to run in the emulator. Joy!
I then worked up a mod_perl SOAP::Lite server with an ‘echo’ service. I recompiled the java MIDlet to use the new service. No joy.
It took me a couple hours, but the problem was in the URN bit of the SOAP envelop (you know, the useless bit). I wasn’t able to code the URN
in java in a way that was acceptable to SOAP::Lite’s default on_action handler in SOAP::Transport::HTTP.pm. The solution for me turned out to be this:
Both Perl and Java clients seem to work with this set up. Joy!
Since I couldn’t find docs on this Perl server/Java client SOAP combo, I thought I’d make the smallest effort to document this in case others get stuck on this bit of technical beaucracy.