We currently have a Java applet that generates a lot of data and uploads it to our servers. One of the upload methods we have is to use an HTTP POST to our server, the contents of which are just the raw data (no multipart encoding or anything).
I'm looking at implementing a Flex app that does the same thing, but I don't see a way to duplicate that network behavior. All the HTTP-related network classes in Flex seem to work under the assumption that you're simply making a request. I don't see a way to actually set the payload of the POST (other than setting a couple query parameters, which wouldn't work here).
What I'd really like is to be able to initiate an HTTP POST, but then be able to write to the connection like I would a socket. Is this possible without having to write my own HTTP implementation on top of the Socket class? Is there any way to set the payload of an HTTP POST within Flex?
Clarification: Being able to create a data buffer and send that to the server is sufficient (which it looks like is possible). It would be better if I could treat the connection as a socket and send data to it over time, instead of all at once, but that isn't strictly required.