[Red5] ServiceInvoker / ConversionUtils: how to invoke methods with List<CustomClass> params

Victor dreamland_skib2 at mail333.com
Wed Dec 19 08:33:01 PST 2007


Hello,

seems there is a problem in Red5's ConversionUtils class when trying to 
call methods (from Flex client) with a collection of custom 
(user-defined) objects. Example:

interface MyService {
  void test(List<MyClass> param);
}

When you try to execute this method from Flex client, Red5 tries to pass 
List<Map> - that is Red5 does NOT reconstruct MyClass from Map of 
attributes. Flex example:

connection.call("myService.test", new Responder(onResult), param);

Some days ago, we have fixed one bug related to the reconstruction of 
any custom object from Map:
http://jira.red5.org/browse/APPSERVER-229
But seems there is a problem when working with collections (List, Map, 
...) of custom objects and even Red5 can not convert List<Integer> to 
List<Long> (Flex does not have Long type).
I think Red5 should try to convert parameters recursively in 
ConversionUtils.convertParams().

What do you think about this? Did somebody try to call such methods from 
Flex? Maybe there is a workaround for this?

Thanks,
Victor Novichihin



More information about the Red5 mailing list