title: How to write a RestService Post that consumes an Excel File?
body: <p>I have to program a Restful Service that Consumes a Excel File Mapps it into a Class and writes it into the DataBase.</p>
  
  <pre><code>@POST
  @Path("/insertDataInDB)
  @Consumes(MediaType.???)
  public Response insertDataInDB(???) {
     //do Stuff
  }
  </code></pre>
  
  <p>My first idea would be to use a ByteStream and than to interpret the Stream with Apache POI. 
  But here i got an Exception: "org.jboss.resteasy.spi.UnsupportedMediaTypeException"</p>
  
  <pre><code>@POST
  @Path("/insertDataInDB")
  @Consumes(MediaType.MULTIPART_FORM_DATA)
  public void insertDataInDB(@FormDataParam("inputfile")
  File inputfile) {
      //do Stuff
  }
  </code></pre>
  
  <p>Has anyone an idea what MediaType to use and what kind of java DataType? </p>
  
  <p>Or has someone a better idea?</p>