cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrus Adamchik (Closed) (JIRA)" <>
Subject [jira] [Closed] (CAY-1629) [PATCH] Can't add custom Hessian serializers to the client
Date Tue, 22 Nov 2011 07:58:43 GMT


Andrus Adamchik closed CAY-1629.

       Resolution: Fixed
    Fix Version/s: 3.1M4
> [PATCH] Can't add custom Hessian serializers to the client
> ----------------------------------------------------------
>                 Key: CAY-1629
>                 URL:
>             Project: Cayenne
>          Issue Type: Improvement
>          Components: ROP
>    Affects Versions: 3.1M4
>         Environment: Mac 10.6
>            Reporter: John Huss
>            Priority: Minor
>              Labels: patch
>             Fix For: 3.1M4
>         Attachments: client_custom_serializers_patch.txt
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
> There isn't any way to register custom Hessian serializers to the client in an ROP setup.
 They can be registered with the server by doing this:
> public class SampleServlet extends ROPHessianServlet {
> 	public void init(ServletConfig configuration) throws ServletException {
> 		super.init(configuration);
> 		getSerializerFactory().addFactory(new MySerializerFactory());
> 	}
> }
> The attached patch saves and exposes a reference to the serializerFactory on the client
so that the same thing can be done there as well, like so:
> ClientRuntime clientRuntime = new ClientRuntime(...);
> ((HessianConnection) clientRuntime.getConnection()).getSerializerFactory().addFactory(new
> In either case these custom serializers will not be reflected when using the static methods
in HessianUtil since those factories are completely internal. This could be considered an
existing bug since the server already supports adding custom factories.  Perhaps the better
variables modifiable, but that feels ugly.  
> For the time being though, the patch provides some essential functionality that is missing.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message