In this chapter we covered a lot of ground, learning all of the concepts that govern web service interaction between Flash and Drupal. When dealing with web services, it is very important to understand how two remote applications communicate and how to develop our software to account for its asynchronous interaction. This is typically always overlooked when developers create their first Flash applications for Drupal, and can easily be avoided if the concepts of web service interaction are understood and taken into account. Each key concept is highlighted as follows:
Flash and Drupal communicate asynchronously. This means that each function call made to Drupal from Flash does not return the result immediately after the call was made. Instead, we need to utilize a
callbackfunction that is triggered when Drupal returns the result from our function call.
We need to wait until the Flash application has finished connecting to Drupal before making any other calls. Otherwise, we will have...