My AJAX Framework
I have setup both a PHP and JavaScript framework for making fast AJAX calls. There are a number of implementations of AJAX frameworks out there, but I have found it better to create my own specific server and client implementation so I can implement AJAX patterns in my own versioned controlled project. This will allow me a greater flexibility and ability to extend from my own code.
The idea around the implementation was to be a purely service level framework. A lot of the other frameworks that are available provide quite a bit of dependency between the server and the javascript (often trying to help you generating your JavaScript - which is nice, but also limits you as you could simply change the gateway server implementation from one language to the other, and often influences your design of both the server and the client). Being a service level framework it does not provide the other extended JavaScript functionality that other frameworks offer, such as Drag and Drop helpers, Autocomplete boxes and the like. These can be implemented ontop of the service level framework as seperate libraries, with hopefully close to no reliance on the service framework.
I have modelled the PHP off a MVC/Model 2 implementation that has a build up/tear down of ~5ms (before optimisations, such as concat single file, or compile to bytecode) to service a request and build a response. The design of the framework allows the response to be changed in a modular fashion, such as building a JSON response. The actions are seperated out to promote reusability and modularity and we have an action server and request processor to handle the application process, authentication and application configuration. It will allow the RPC/Request to be processed quickly through a reusable framework.
On the Javascript client end I have built a RPC/Remoting style framework. The framework handles the creating of the request to be sent to the server and allows API to manage state and response. This allows Requests/Calls to be handled individually through a service with state observers and relay responders, and implements timeouts and fault handling.
I am still considering how I will proceed with the framework, I am waiting for a project where I can really take advantage of it.





