I’m trying to receive data from Agile 9.0, which, as far as I can determine, can send via HTTP POST, but only as “multipart/form-data”. I cannot figure out how to get my flow service to receive this data. I have a service that can receive “text/xml” data, but can’t find any information on receiving “multipart/form-data” requests.
Have you looked into WmSamples package of mime Folder there are some sample services like (sample.mime:extract_MultipartMIME)which internally takes InputStream object and pass the MIME message to the local createMimeData service.
To check where the HTTP post data is sending “multipart/form-data” use the getTransportInfo service and see whether the contentStream object is showing up and Content-Type=“multipart/form-data”
There is a multipart/form-data ContentHandler in the WmJBoss package.
Unfortunately in what in hindsight was a very stupid move, I mixed the startup and shutdown code of the JBoss server with the startup and shutdown of the handler. The idea was this code would move into the core IS, but it has not happened as of yet because no one has been bugging support or, even better, sales about it.
But if one happened to put the classes that ship in WmJBoss/code/classes/wm/mime and WmJBoss/code/classes/wm/mime/resources into their package and they wrote the following two services as their package’s startup and shutdown services, something good could happen, which I cannot guarantee or support.
startup service contains:
ServerAPI.registerContentHandler(“multipart/form-data”, new HandlerFactory_Multipart());
shutdown service contains:
You mean, like this?
MimeMultipartContentHandler.zip (10.1 k)
What would a unit test for this look like?
I did tried using the package that you created, but still I’m not able to extract the file contents when posting an HTML form using enctype as multipart/form-data. The receiving service is still not allowing me to extact the file contents though I can see them through savePipeline.
I then tried copying just the mime class files from your package & copied them to my own package within the classes folder…but still no results.
Please help me in identifying whats missing…I’m really stuck and need your help to come out of it…Thanks much!