Skip to content

Instantly share code, notes, and snippets.

@jclausen
Last active April 26, 2017 19:01
Show Gist options
  • Save jclausen/b188d712278b69815dfa9d8bcf31c01e to your computer and use it in GitHub Desktop.
Save jclausen/b188d712278b69815dfa9d8bcf31c01e to your computer and use it in GitHub Desktop.
HSQL
this.datasource = "myApp";
// ORM SETTINGS
this.ormEnabled = true;
this.ormSettings = {
// ENTITY LOCATIONS, ADD MORE LOCATIONS AS YOU SEE FIT
cfclocation=[ "models", "modules", "modules_app" ],
// THE DIALECT OF YOUR DATABASE OR LET HIBERNATE FIGURE IT OUT, UP TO YOU TO CONFIGURE
//dialect = "MySQLwithInnoDB",
// DO NOT REMOVE THE FOLLOWING LINE OR AUTO-UPDATES MIGHT FAIL.
dbcreate = "update",
// FILL OUT: IF YOU WANT CHANGE SECONDARY CACHE, PLEASE UPDATE HERE
secondarycacheenabled = true,
cacheprovider = "EhCache",
// ORM SESSION MANAGEMENT SETTINGS, DO NOT CHANGE
logSQL = false,
flushAtRequestEnd = false,
autoManageSession = false,
// ORM EVENTS MUST BE TURNED ON FOR CONTENTBOX TO WORK
eventHandling = true,
eventHandler = "cborm.models.EventHandler",
// THIS IS ADDED SO OTHER CFML ENGINES CAN WORK WITH CONTENTBOX
skipCFCWithError = true
};
this.datasources[ "myApp" ] = {
class : 'org.h2.Driver',
connectionString : 'jdbc:h2:' & expandPath( '/config/' ) & '/myapp;MODE=MySQL',
storage : true,
clob : true,
blob : true
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment