I'm having a lot of problem trying to upload a file in appengine using jersey 2.8
this is the method I use
@POST
@Consumes(MediaType.MULTIPART_FORM_DATA)
@Produces("application/json")
public StringT uploadFile(@FormDataParam("file") InputStream fileInputStream, @FormDataParam("file") FormDataContentDisposition fileDisposition){
...
return new StringT("ok");
}
the exception I'm having is this
Uncaught exception from servlet
javax.servlet.UnavailableException: A MultiException has 3 exceptions. They are:
1. java.lang.SecurityException: Unable to create temporary file
2. java.lang.IllegalStateException: Unable to perform operation: create on org.glassfish.jersey.media.multipart.internal.MultiPartReaderServerSide
3. java.lang.IllegalStateException: Unable to perform operation: create on org.glassfish.jersey.message.internal.MessageBodyFactory
I do not need to store the file, I just want to handle it
Anybody knows a solution?