Maven jersey-multipart missing dependency for javax.ws.rs.core.Response

Yeah found it!

Apparently the dependencies were OK.

Added these to my imports

import javax.ws.rs.Consumes;
import javax.ws.rs.core.MediaType;

And changed the code to

@POST
@Path("copy")
@Consumes(MediaType.MULTIPART_FORM_DATA)
public Response copy(@FormDataParam("file") InputStream uploadedInputStream,
            @FormDataParam("file") FormDataContentDisposition fileDetail);

And now suddenly everything works! So hope I can help someone else with the same problem...


@FormDataParam seems to be very fussy about the @Consumes annotation. Note that (unlike just about everything else) placing this annotation on an interface definition of the method isn't good enough for @FormDataParam !