Re: [Resin-interest] Custom hessian serialization in Resin

2009-05-14 Thread Scott Ferguson

On May 14, 2009, at 11:05 AM, Jeff Schnitzer wrote:

> Is there a way to register custom hessian serializers in Resin?
>
> Resin4 can't serialize java.net.URL :-(

Hmm.  I refactored that customization for Resin4 and it looks like URL  
wasn't handled properly.

Serializers and deserializers can be registered in META-INF/hessian/ 
serializers and META-INF/hessian/deserializers.  The 4.0 resin.jar  
should include some already.  You would want to follow the pattern of  
the FileDeserializer in com.caucho.hessian.io.

-- Scott

>
>
> Thanks,
> Jeff
>
>
> ___
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest



___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


Re: [Resin-interest] Custom hessian serialization in Resin

2009-05-14 Thread Jeff Schnitzer
Solved the problem of serializing a byte[]... it had nothing to do
with the byte[], it was because we are calling overloaded methods.
Must call HessianProxyFactory.setOverloadEnabled(true), which we here
are now calling the "setBroken(false)" method :-)

Still can't deserialize java.net.URL, looks like Hessian is calling
the URL(String) constructor and passing in a null.

Jeff

On Thu, May 14, 2009 at 11:27 AM, Jeff Schnitzer  wrote:
> In addition, we're having problems serializing a byte[].
>
> One additional complication is that if we turn com.caucho.hessian
> logging to finest, it throws an exception that is not thrown when
> logging is lower (and not useful, unfortunately):
>
> [11:21:06.493] {http--8080-9} WARNING [ErrorPageManager]
> java.lang.IllegalStateException: 1 is an unknown object type
> [11:21:06.493] {http--8080-9}   at
> com.caucho.hessian.io.HessianDebugState$ObjectState.(HessianDebugState.java:1345)
> [11:21:06.493] {http--8080-9}   at
> com.caucho.hessian.io.HessianDebugState$State.nextObject(HessianDebugState.java:523)
> [11:21:06.493] {http--8080-9}   at
> com.caucho.hessian.io.HessianDebugState$CompactListState.next(HessianDebugState.java:1651)
> [11:21:06.493] {http--8080-9}   at
> com.caucho.hessian.io.HessianDebugState.next(HessianDebugState.java:98)
>
> Thanks,
> Jeff
>
> On Thu, May 14, 2009 at 11:05 AM, Jeff Schnitzer  wrote:
>> Is there a way to register custom hessian serializers in Resin?
>>
>> Resin4 can't serialize java.net.URL :-(
>>
>> Thanks,
>> Jeff
>>
>


___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


Re: [Resin-interest] Custom hessian serialization in Resin

2009-05-14 Thread Jeff Schnitzer
In addition, we're having problems serializing a byte[].

One additional complication is that if we turn com.caucho.hessian
logging to finest, it throws an exception that is not thrown when
logging is lower (and not useful, unfortunately):

[11:21:06.493] {http--8080-9} WARNING [ErrorPageManager]
java.lang.IllegalStateException: 1 is an unknown object type
[11:21:06.493] {http--8080-9}   at
com.caucho.hessian.io.HessianDebugState$ObjectState.(HessianDebugState.java:1345)
[11:21:06.493] {http--8080-9}   at
com.caucho.hessian.io.HessianDebugState$State.nextObject(HessianDebugState.java:523)
[11:21:06.493] {http--8080-9}   at
com.caucho.hessian.io.HessianDebugState$CompactListState.next(HessianDebugState.java:1651)
[11:21:06.493] {http--8080-9}   at
com.caucho.hessian.io.HessianDebugState.next(HessianDebugState.java:98)

Thanks,
Jeff

On Thu, May 14, 2009 at 11:05 AM, Jeff Schnitzer  wrote:
> Is there a way to register custom hessian serializers in Resin?
>
> Resin4 can't serialize java.net.URL :-(
>
> Thanks,
> Jeff
>


___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest


[Resin-interest] Custom hessian serialization in Resin

2009-05-14 Thread Jeff Schnitzer
Is there a way to register custom hessian serializers in Resin?

Resin4 can't serialize java.net.URL :-(

Thanks,
Jeff


___
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest