users@jersey.java.net

Re: [Jersey] Why does contrib/multipart depend on jersey-server?

From: Craig McClanahan <Craig.McClanahan_at_Sun.COM>
Date: Thu, 29 Jan 2009 04:27:50 -0800

Paul Sandoz wrote:
>
> On Jan 28, 2009, at 4:57 AM, Gili wrote:
>
>>
>> I tried running Proguard against my code and I just noticed that
>> FormDataMultiPartDispatchProvider$FormDataMultiPartParamInjectable
>> depends
>> on com.sun.jersey.server.impl.inject.AbstractHttpContextInjectable
>>
>> Isn't contrib/multipart supposed to be independent of the server module?
>>
>
> Not necessarily. The above piece of functionality is server side
> specific and related to @FormParam support for multipart/form-data for
> resource methods. We are currently working to transition such
> functionality from jersey-server to jersey-multipart so that the
> multipart implementation is leveraged.
>
> However, the code should be independent of the implementation packages
> of jersey-server. There should be no requirement that the
> jersey-server module be depended on, since the functionality will
> never be used without jersey-server anyway, and for the client the
> functionality will never be loaded.
>
And this is precisely why the dependency includes
"<optional>true</optional>" so it doesn't cause problems if you're on
the client side and don't have jersey-server in your classpath.
> Paul.
Craig

>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>