[ColdBox MVC + ORM] Passin along a message to the next event

Just remember, ColdBox’s persist functionality uses flash storage which defaults to session so you’ll want to switch it in your config to store somehwere like client.

Also, if youi’re using Railo, check out our Railo Couchbase Extension. It is a commercial product that allows you to store session data in a couchbase cluster which is perfect for clustered environments that require scale.

http://www.ortussolutions.com/products/couchbase-railo

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

@Brad,
Thanks for pointing that out. I will make sure to go through the different options for storing the flash scope.

I am also curious about Aaron’s question: Is there a difference in performance between the LITE and FULL frameworks? I don’t really care of there are more files in the FULL framework, even if it takes a bit longer to init, as long as subsequent execution times are similar?

There is a smaller overhead since there’s no interceptors and simpler life cycle, but it’s very small of a difference (probably nanoseconds). Most of what makes ColdBox LITE “light” is simply that it has 80% of the functionality stripped out of it. I’ve never measured the init times, but I doubt they’re much different. For instance, plugins aren’t loaded until the first time they are used, so there’s zero overhead for plugins your not using.

ColdBox LITE is for people who JUST want some MVC conventions but want to build all their tools and libraries by themselves. I personally think that sounds like a painful way to build apps, but there’s people who like the idea of “minimalist” frameworks so we created LITE for those people. If you want to tap into all the plugins, libraries, and extensibility ecosystem of the ColdBox platform-- then LITE is not for you.

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

I needed to do something similar; so I used the MessageBox right before the SetNextEvent directly in the Handler. So, in your case, try:

function save(event,rc,prc){
event.paramValue( “patientID”, 0 );
patientService.save( populateModel( patientService.get( rc.patientID ) ) );
getPlugin(“MessageBox”).info(“Saved successfully!”);
setNextEvent(“patient.list”);
}

Then no need to use…

<cfif structKeyExists( prc, “message” ) AND len( prc.message )>

Hope it helps