Looking for ideas for Multipart Form Handling on Web Service
<p>I'm playing around with writing a web service that runs on Android 
that handles uploading photos.  I am only writing the server, and do 
not have any control over the client. </p>

<p>Inside of the message is a small SOAP message, and then the binary 
data.  I am trying to figure out if there's a library that can do the 
parsing of the two pieces.  Apache Commons FileUpload looked like the 
obvious choice, however, it seems to be heavily intertwined with 
servlet libraries, and I don't know if it's possible (or if it's a 
good idea) to put too much J2EE infrastructure on a phone. </p>

<p>Parsing it myself doesn't seem too bad.  I'm not too familiar with the 
raw HTTP layers/protocol, but it looks like the the boundary delimiter 
string is given in the content type header.  If I find and index past 
those, I should be able to find the two halves of the multi-part 
message that I need to deal with.  At least that's what I seem to 
think after looking at a wireshark trace of the client talking to the 
real server. </p>

<p>Any thoughts would be appreciated. </p>

<p>-Kevin </p>
