[ColdBox 4.0 cborm Railo] Multiple datasource support

I just wanted to check an see if anyone is actually using ColdBox 4.0 and the cborm module with Railo. I just tried it, but there is a compile error on the OrmFlush() function. I’m on the latest patch available on the Railo development channel which is 4.2.1.008. However if I recall, Gunnar said the multi-data source support was in 4.3 which doesn’t appear to be available for general consumption yet.

I think that means no one can actually use cborm on Railo unless they have some pre-release access to Railo 4.3.

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’m using 4.2.1.008 on Railo and I’m able to call ORMFlush(). However I’ve been unable to get multiple datasources to work ever :frowning:

And I’ve been playing with cborm and everything seems to work fine unless i’m doing something wrong and i don’t even know it.​

Jeremey, the issue isn’t when I manually call ORMFlush() ,it’s that Railo won’t even compile the cborm/models/util/ORMUtilSupport.cfc file. This happens as soon as my application starts up and ORM tries to initialize any ORM entities. I have my modules folder in the CFCLocation path, so it’s finding the cborm module and erroring out as soon as it sees this line:

ORMFlush( arguments.datasource );

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

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

BTW, if I remove “modules” from the CFCLocation my site runs without error. At first I couldn’t get that work. It turns out my code looked like this:

cfclocation=[ “model” ],

but the actual folder was “models” with an s. Apparently, if the all the CFCLocations aren’t found, Railo just completely ignores the CFCLocation setting and scans the entire web root. I think I would have preferred an error telling me the “model” folder didn’t exist.

Of course, this isn’t much of a fix and it means I can’t install any modules that includes ORM entities without adding them individually to the CFCLocation array.

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’ve seen the same issue on 4.2.1.008. Had to manually declare individual models folders for specific modules in cfclocation to get around it.