= Fusion RFC 1: Use !OpenLayers.Class and other prototype capabilities = This page contains a change request (RFC) for the Fusion project. More Fusion RFCs can be found on the [wiki:RFCs RFCs] page. == Status == ||Submission Date||20 Mar 08|| ||Last Modified||20 Mar 08|| ||Author||Paul Spencer|| ||RFC Status||draft|| ||Implementation Status||pending|| ||Proposed Milestone||1.1|| ||Assigned PSC guide(s)||(when determined)|| ||'''Voting History'''||(vote date)|| ||+1||''tbd''|| ||+0||''tbd''|| ||-0||''tbd''|| ||-1||''tbd''|| == Overview == This RFC proposes to change the core javascript framework that it uses for defining classes from Prototype to !OpenLayers. == Motivation == One of the performance bottle necks that Fusion has is the size of the javascript code that gets downloaded to the client browser is pretty substantial. Fusion relies on Jx. Jx is based on Prototype and Scriptaculous. Prototype and Scriptaculous combine into a compressed file size of 185kb. We would like to change these libraries in Jx to something lighter-weight and potentially snazzier. The problem for Fusion is that Fusion uses some aspects of Prototype (Class, Function, Ajax, Event) extensively and it will be a substantial effort to change. If we don't like the new library in Jx, we may want to try another library. This could get painful. !OpenLayers has implemented many of the features of Prototype that we actually use in Fusion, including Class, Function.bind, and Ajax. == Proposed Solution == Replace all existing uses of Prototype in Fusion with the equivalent functionality from !OpenLayers. == Implications == This change should have no noticeable effect on existing applications. There will be no functional change to any existing code. Applications that have been written to take advantage of Jx and some aspects of Prototype (for instance, the $() function) will still work because Jx will not change as part of this work. If we modify Jx to use a different library at a future time, then existing applications will need to be modified at that time to accommodate the change in underlying libraries. == Test Plan == There is no set of automated tests for Fusion at this time. Ad hoc testing will be conducted after the change using the existing !MapServer and !MapGuide application samples. == Funding/Resources == DM Solutions Group will do all the work for this change.