<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Hi Balz<br>
<br>
I am not sure currently how to do this best.<br>
<br>
What about doing together a short hackthon?<br>
<br>
I am currently working on various REST interfaces for Yulup<br>
<br>
<a class="moz-txt-link-freetext" href="https://www.yulup.com/en/documentation/swagger-ui/index.html">https://www.yulup.com/en/documentation/swagger-ui/index.html</a><br>
<br>
and I would like to add more interfaces and would be to upload
multiple images with one request, which I guess would also be your
usecase, right? Or what is your usecase?<br>
<br>
Thanks<br>
<br>
Michael<br>
<br>
<br>
Am 28.03.17 um 17:35 schrieb basZero:<br>
</div>
<blockquote
cite="mid:CAOXzDSEmNLtxuiMyERZyOWpQqjQ-ejZguHqQEQZDyGLRiEocFA@mail.gmail.com"
type="cite">
<div dir="ltr">Hi,
<div><br>
</div>
<div>I want to extend my realm by a resource that can handle
multipart POST requests according to the Servlet Spec 3.0.</div>
<div><br>
</div>
<div>In order to make use of the Servlet 3.0 features, the
servlet class must be annotated by @MultipartConfig, e.g.</div>
<div><br>
</div>
<div>
<div>@MultipartConfig</div>
<div>public class YanelMultipartServlet extends HttpServlet {</div>
</div>
<div> ...</div>
<div>}</div>
<div><br>
</div>
<div>Currently I think everything is mapped to the YanelServlet
in web.xml</div>
<div><br>
</div>
<div>My question is: how should I extend Yanel?</div>
<div>What probably has to be done:</div>
<div><br>
</div>
<div>- Somehow extend web.xml so that a certain realm path gets
mapped to the new YanelMultipartServlet</div>
<div>- Maybe YanelMultipartServlet can be a subclass of
YanelServlet, which then would find out the mapped resource
and the processing of the request could still be done in the
resource.</div>
<div><br>
</div>
<div>So, how should I do this?</div>
<div><br>
</div>
<div>Use Case why I need this:</div>
<div>in Servlet 3.0 you can easily process all parts in a
multipart request like this:</div>
<div>Collection<Part> parts = request.getParts();<br>
</div>
<div><br>
</div>
<div>Then you can iterate over all parts.</div>
<div><br>
</div>
<div>But the getParts() method only works correctly if the
servlet is annotated by @MultipartConfig</div>
<div><br>
</div>
<div>Cheers, Balz</div>
<div><br>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
</blockquote>
<br>
</body>
</html>