Do you get any exception?
On Sep 20, 2009, at 7:55 PM, John Cuiuli <
jcu...@gmail.com> wrote:
>
> Ok... so I've got further.
>
> I can send anything simple through (int, string etc) but it's choking
> when I try to return a Grails Domain Object. They should be just plain
> beans so I'm confused as to what the problem is.
>
> This is the last bit of the log file... I wonder if the Grails Domain
> Object is reflecting as something else
> (groovy.lang.ExpandoMetaClass)??
>
>
> 2009-09-21 09:42:31,307 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - search found serializer
> org.jabsorb.serializer.impl.BeanSerializer
> 2009-09-21 09:42:31,307 [27373743@qtp0-2] INFO impl.BeanSerializer -
> analyzing java.util.concurrent.ConcurrentHashMap$Values
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG impl.BeanSerializer -
> invoking isEmpty()
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - marshall class java.lang.Boolean
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - looking for serializer -
> java:java.lang.Boolean json:null
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - direct match serializer
> org.jabsorb.serializer.impl.BooleanSerializer
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG impl.BeanSerializer -
> invoking getJavaClass()
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG impl.BeanSerializer -
> invoking getClassNode()
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - marshall null
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG impl.BeanSerializer -
> invoking getExpandoProperties()
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - marshall class java.util.Collections
> $UnmodifiableCollection
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - looking for serializer -
> java:java.util.Collections$UnmodifiableCollection json:null
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] DEBUG
> jabsorb.JSONSerializer - search found serializer
> org.jabsorb.serializer.impl.BeanSerializer
> 2009-09-21 09:42:31,309 [27373743@qtp0-2] INFO impl.BeanSerializer -
> analyzing java.util.Collections$UnmodifiableCollection
> 2009-09-21 09:42:31,310 [27373743@qtp0-2] DEBUG impl.BeanSerializer -
> invoking isEmpty()
> 2009-09-21 09:42:31,312 [27373743@qtp0-2] DEBUG
> jabsorb.JSONRPCServlet - send: {"id":2,"error":{"code":
> 593,"msg":"bean com.beachit.gespm.JobStatus bean
> groovy.lang.ExpandoMetaClass element 0"}}
> 2009-09-21 09:42:31,312 [27373743@qtp0-2] DEBUG
> jabsorb.JSONRPCServlet - send: {
> "error": {
> "code": 593,
> "msg": "bean com.beachit.gespm.JobStatus bean
> groovy.lang.ExpandoMetaClass element 0"
> },
> "id": 2
> }
> 2009-09-21 09:42:31,312 [27373743@qtp0-2] DEBUG
> jabsorb.JSONRPCServlet - not gzipping because size is 114 (less than
> the GZIP_THRESHOLD of 200 bytes)
> 2
> On Sep 21, 7:30 am, sub <
sub.cont...@gmail.com> wrote:
>> Hi,
>>
>> RE: Grails/Groovy integration with jabsorb
>>
>> Has anybody tried integrating the two?
>> I'm trying a simple example and am getting weird errors complaining
>> about groovy.lang.ExpandoMetaClass.
>>
>> Error code: 593
>> Message: "bean ]com.beachit.gespm.JobStatus bean
>> groovy.lang.ExpandoMetaClass element 0"
>>
>> It registers fine when I create the RPC object in javascript - it
>> correctly returns the list of functions etc.
>>
>> Here is the snippet I'm using to set up the servlet in grails
>>
>> JSONRPCBridge json_bridge = (JSONRPCBridge)
>> session.getAttribute("JSONRPCBridge")
>>
>> if(json_bridge == null)
>> {
>> json_bridge = new JSONRPCBridge();
>> session.setAttribute("JSONRPCBridge", json_bridge);
>> def jobStatusService = new
>> com.beachit.gespm.JobStatusService()
>>
>> json_bridge.registerObject("jobStatusService",
>> jobStatusService);
>>
>> }
>
> >