Model-Glue Welcomes Dan Wilson

This post is awfully belated: I'm happy to welcome Dan Wilson as a member to the Model-Glue project.

He's helping out with bug fixes, administering the AboutWeb-provided server that runs the new bug tracking site (and eventually docs / wiki), and writing blog entries for Model-Glue.com.

Welcome aboard, Dan!

New MG3 Feature: Dynamic viewMappings

Some of the new features in MG3, such as its revised core, focus on work being done in the more "enterprise" arena. A specific case that I'm working hard to support is the case where many customers are running "their own instance" of a common code base and how to support per-customer modification.

Realizing the use case, let's imagine that you host a blog platform. Customers can sign up and immediately have their own blog deployed. Each blog is running the exact same code base, all hosted on the same server/cluster.

Inevitably, a customer will offer to pony up cash to have a view things change. On the service / controller side, MG3 has you covered by allowing ColdSpring-based definition of services and controllers, allowing you to use ColdSpring "overriding" to one-off services and controllers.

For views, however, things were tricky. To support this case, the concept of "dynamic viewMappings" is being developed (actually, I just need to commit to SVN!).

Model-Glue crawls an array of "view mappings" looking for your application's views: it's defined in your app's Coldspring.xml file.

With dynamic viewMappings added, you can manipulate this list at runtime.

Let's solve our blog engine case, pretending that customer "acmeCorp" needs a suite of custom views, overriding the default views only when a custom is defined. All we have to do is update the viewMappings inside a listener function whenever the user is from acmeCorp:

<cfset var user = sessionFacade.getUser() />
<cfset var customViewMappings = user.getCompany().getCustomViewMapping() />
<cfset var viewMappings = "" />

<cfif len(customViewMappings)>
   <cfset viewMappings = event.getValue("viewMappings") />
   <!--- Insert the custom mappings first, adding a value like "/views/custom/acmeCorp" --->
   <cfset arrayInsertAt(viewMappings, 1, customViewMappings) />
   <cfset event.setValue("viewMappings", viewMappings) />   
</cfif>

Et voila.

Update on ModelGlue:3 Gesture

Version 3 of the Model-Glue framework is under development right now. Here is an update on where we stand...

Issue Tracker

Reporting bugs/enhancement requests for Model-Glue just got easier. We now have a fully licensed JIRA issue tracker. This will help us stay on top of bugs, features and such. A special thanks to the fine folks at Atlassian for making licenses available to the Model-Glue project at no charge.

Load Testing

I've been load testing a MG:3 application pretty heavily for the last couple of weeks. The framework holds up extremely well to load and shows no memory leakage or other misbehavior.

Fixed Bugs

The bug count has been reduced by 50%. Keep logging and reporting issues!

Want to try Model-Glue:3?

The framework still has an Alpha label for now and while we have a pretty active group of folks using the MG:3 alpha, others are still welcome. Download the latest framework code from http://svn.firemoss.com/modelglue/trunk/ModelGlue and tell us what you think.

© 2008 Joe Rinehart
BlogCFC was created by Raymond Camden. This blog is running version 5.8.001.