| Author |
Using Spring 3 to marshal XML containing local file paths into InputStream/byte[]/etc
|
Nick Stevenson
Greenhorn
Joined: Jan 25, 2012
Posts: 1
|
|
Hello,
Let me start off by saying, I'm not sure if what I'm asking is even possible. Currently, I'm using Spring 3 with a JAXB marshaller to back a small web services project. How it works now is we will send XML requests to the server (using Rest Client for Firefox), which converts the XML into Java objects using custom annotated domain classes, which then get mapped to a specific controllers for further processing. I've now encountered a scenario in which we will want to use this for wrapping a local file for processing on the server (for ease of use and so outside users don't have to worry about any specific implementations). Ideally, I'd like the request to look like :
This would ideally automatically marshal the request into a domain object that looked something like :
I've tried researching how other people have done this, but short of creating a form (which is not an option, unfortunately), or putting the file contents in the request payload itself (something I'm reluctant to do, as client files can sometimes be well over 10GB), I haven't been able to find a solution.
Is what I'm asking for technically possible? Any suggestions or guidance would be of great help.
|
 |
 |
|
|
subject: Using Spring 3 to marshal XML containing local file paths into InputStream/byte[]/etc
|
|
|