Hi Sanjeewa, ATM msf4j also supports a similar approach[1]. You can also access File object like in[2]
[1] - https://github.com/wso2/msf4j/blob/master/samples/formparam/src/main/java/org/wso2/msf4j/example/FormService.java#L170 [2] - https://github.com/wso2/msf4j/blob/master/samples/formparam/src/main/java/org/wso2/msf4j/example/FormService.java#L132 Thanks Thusitha On Mon, Oct 31, 2016 at 3:29 PM, Sanjeewa Malalgoda <[email protected]> wrote: > Hi Azeez, All, > When we are implementing multi part file uploads and document updates via > post we may need to access file data within service implementation in > addition to input stream. In such cases most of the REST frameworks create > this object[1] in framework level as passed to service implementation. When > it comes to MSF4J what is the best approach to do form post with data file? > Also what is the best way to pass file data to service implementation layer? > > As of now we are using > org.glassfish.jersey.media.multipart.FormDataContentDisposition > class for this in API Manager REST API store and publisher micro services. > And we are still not sure what comes to implementation layer when we add > this to micro service. Most of the time we may need to do some work to fill > data to this object. Also we cannot zip those jars due to license > mismatching and it can impact on binary size. Is there any possibility of > supporting this from MSF4J framework level. Otherwise we have to generate > file data class from code generator and add it to generated code. But IMO > its not clean solution. > > Appreciate your feedback on this. > > [1]https://jersey.java.net/apidocs/2.8/jersey/org/glassfish/jersey/media/ > multipart/FormDataContentDisposition.html > > Thanks, > sanjeewa. > > -- > > *Sanjeewa Malalgoda* > WSO2 Inc. > Mobile : +94713068779 > > <http://sanjeewamalalgoda.blogspot.com/>blog :http://sanjeewamalalgoda. > blogspot.com/ <http://sanjeewamalalgoda.blogspot.com/> > > > -- Thusitha Dayaratne Software Engineer WSO2 Inc. - lean . enterprise . middleware | wso2.com Mobile +94712756809 Blog alokayasoya.blogspot.com About http://about.me/thusithathilina <http://wso2.com/signature>
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
