Quick CF9 Remoting Tip

I was working with a CF9 + Flex 4 example last night. This was a new installation of CF9 - and I hadn't tweaked any of the remoting settings at all (more on that in a bit). I was setting up a data paging example - and noticed that the Flex application was going crazy. From the network monitor I noticed that it was making continuous calls - and eventually caused the application to hang. After further analysis in the network monitor, I determined that Flex was receiving the objects back from ColdFusion - but they didn't contain any data. I hadn't seen this issue before.

After rummaging through the remoting config files, I discovered the issue. My bean CFC was using ColdFusion 9's new implicit getters/setters. To get this to work properly, you have to change a setting in the remoting config( specifically in services-config.xml):

XML:
  1. <use-accessors>true</use-accessors>
  2. <use-implicit-accessors>true</use-implicit-accessors>

By setting use-implicit-accessors to true, ColdFusion then uses the new implicit getters and setters in CF9 for your remoting calls. With that quick fix (and a restart) everything was working perfectly.




2 Responses to “Quick CF9 Remoting Tip”

  1. PHP would be a better choice, but it’s your tense neck and back muscles at the end of the day buddy! ;)

  2. Rob says:

    Is PHP still around?

Leave a Reply