Problem with model injection/autowire

171 views
Skip to first unread message

Michael

unread,
Jan 2, 2011, 9:14:10 PM1/2/11
to ColdBox Platform
I am new to ColdBox and am attempting to put together my first app
using the 3.0.0.RC1, Oracle 11i and the CF9 base orm. I started with
the base app configuration and added two models with service. Put
mappings in ModelMappings.cfm. When I try to invoke the handler it
tells me that my services object is undefined in the list function of
the handler so the injector doesn't appear to be working.

Can anybody tell me what I am doing wrong? How do I trouble shoot
this? Any help would be appreciated.



============= config/ModelMappings.cfm ===================

<cfscript>
/* Add all the model mappings you want */
/* addModelMapping(alias="",path="") */

addModelMapping(alias="TransferRequestService",path="model.TransferRequest.TransferRequestService");

addModelMapping(alias="JobPostingService",path="model.JobPosting.JobPostingService");
addModelMapping(alias="DateUtil",path="model.utilities.DateUtil");
</cfscript>

============= config/coldbox.xml.cfm ===================

<?xml version="1.0" encoding="UTF-8"?>
<!--
For all possible configuration options please refer to the
documentation:
http://ortus.svnrepository.com/coldbox/trac.cgi/wiki/cbConfigGuide
-->
<Config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://www.coldbox.org/schema/
config_3.0.0.xsd">
<Settings>

<!-- Application Setup-->

<Setting name="AppName" value="HR06TRJP"/>
<!-- If you are using a coldbox app to power flex/remote apps, you
NEED to set the AppMapping also. In Summary,
the AppMapping is either a CF mapping or the path from the webroot
to this application root. If this setting
is not set, then coldbox will try to auto-calculate it for you.
Please read the docs.
<Setting name="AppMapping" value="/MyApp"/> -->
<Setting name="EventName" value="" />

<!-- Development Settings -->
<Setting name="DebugMode" value="true"/>
<Setting name="DebugPassword" value=""/>
<Setting name="ReinitPassword" value=""/>
<Setting name="HandlersIndexAutoReload" value="true"/>
<Setting name="ConfigAutoReload" value="false"/>

<!-- Implicit Events -->
<Setting name="DefaultEvent" value="General.index"/>
<Setting name="RequestStartHandler" value="Main.onRequestStart"/>
<Setting name="RequestEndHandler" value=""/>
<Setting name="ApplicationStartHandler" value="Main.onAppInit"/>
<Setting name="SessionStartHandler" value=""/>
<Setting name="SessionEndHandler" value=""/>
<Setting name="MissingTemplateHandler" value=""/>

<!-- Extension Points -->
<Setting name="UDFLibraryFile" value="includes/helpers/
ApplicationHelper.cfm" />
<Setting name="PluginsExternalLocation" value="" />
<Setting name="ViewsExternalLocation" value=""/>
<Setting name="LayoutsExternalLocation" value="" />
<Setting name="HandlersExternalLocation" value="" />
<Setting name="RequestContextDecorator" value=""/>

<!-- Error/Exception Handling -->
<Setting name="ExceptionHandler" value=""/>
<Setting name="onInvalidEvent" value=""/>
<Setting name="CustomErrorTemplate" value="" />

<!-- Application Aspects -->
<Setting name="HandlerCaching" value="false"/>
<Setting name="EventCaching" value="false"/>
<Setting name="ProxyReturnCollection" value="false"/>
<Setting name="FlashURLPersistScope" value="session"/>


</Settings>

<!-- Complex Settings follow JSON Syntax. www.json.org.
*IMPORTANT: use single quotes in this xml file for JSON notation,
ColdBox will translate it to double quotes.
-->
<YourSettings>
<!-- @YOURSETTINGS@ -->
</YourSettings>

<!--Model Integration -->
<Models>
<DefinitionFile>config/ModelMappings.cfm</DefinitionFile>
<!--
<SetterInjection>true</SetterInjection>
<ObjectCaching>true</ObjectCaching>
<ExternalLocation></ExternalLocation>
<DICompleteUDF>onDIComplete</DICompleteUDF>
<StopRecursion></StopRecursion>
<ParentFactory type="coldspring or lightwire">definition file</
ParentFactory>
-->
</Models>

<!--
ColdBox Logging via LogBox
Levels: -1=OFF,0=FATAL,1=ERROR,2=WARN,3=INFO,4=DEBUG
-->
<LogBox>
<Appender name="coldboxTracer"
class="coldbox.system.logging.appenders.ColdboxTracerAppender" />
<!-- Log to ColdBox File -->
<Appender name="fileLog"
class="coldbox.system.logging.appenders.AsyncRollingFileAppender">
<Property name="filePath">logs</Property>
<Property name="fileName">${AppName}</Property>
</Appender>
<!-- Root Logger Definition -->
<Root levelMin="FATAL" levelMax="DEBUG" appenders="*" />
</LogBox>

<Layouts>
<!--Declare the default layout, MANDATORY-->
<DefaultLayout>Layout.Main.cfm</DefaultLayout>
<!--
Declare other layouts, with view/folder assignments if needed, else
do not write them
<Layout file="Layout.Popup.cfm" name="popup">
<View>vwTest</View>
<View>vwMyView</View>
<Folder>tags</Folder>
</Layout>
-->
</Layouts>

<Interceptors>
<!-- USE ENVIRONMENT CONTROL -->
<Interceptor class="coldbox.system.interceptors.EnvironmentControl">
<Property name='configFile'>config/environments.xml.cfm</Property>
<Property name='fireOnInit'>true</Property>
</Interceptor>
<!-- USE AUTOWIRING -->
<Interceptor class="coldbox.system.interceptors.Autowire" >
<Property name="entityInjection">true</Property>
<Property name="debugMode">true</Property>
<Property name="enableSetterInjection">true</Property>
</Interceptor>
<!-- USE SES -->
<Interceptor class="coldbox.system.interceptors.SES">
<Property name="configFile">config/Routes.cfm</Property>
</Interceptor>
<!-- @SIDEBAR@ -->
<Interceptor class="coldbox.system.interceptors.coldboxSideBar">
<Property name="yOffset">50</Property>
<Property name="isScroll">false</Property>
<Property name="slideSpeed">15</Property>
<Property name="waitTimeBeforeOpen">0</Property>
<Property name="waitTimeBeforeClose">250</Property>
<Property name="links">
[
{"desc":"ColdBox API","href":"http:\/\/www.coldbox.org\/api
\/"}
,{"desc":"ColdBox SideBar Help","href":"http:\/\/
ortus.svnrepository.com\/coldbox\/trac.cgi\/wiki\/cbSideBar"}
,{"desc":"ColdBox Credits","href":"http:\/\/
ortus.svnrepository.com\/coldbox\/trac.cgi\/wiki\/cbCredits"}
]
</Property>
<Property name="width"></Property>
<Property name="visibleWidth"></Property>
<Property name="imagePath"></Property>
<Property name="imageVAlign"></Property>
<Property name="cssPath"></Property>
</Interceptor>
</Interceptors>

<i18N>
<!--Default Resource Bundle without locale and properties extension--
>
<!--<DefaultResourceBundle>includes/main</DefaultResourceBundle>-->
<!--Java Standard Locale-->
<!--<DefaultLocale>en_US</DefaultLocale>-->
<!--session or client-->
<!--<LocaleStorage>session</LocaleStorage>-->
<!--<UknownTranslation>nothing</UknownTranslation>-->
</i18N>

<!-- Datasource Settings
<Datasources>
<Datasource alias="MyDSNAlias" name="real_dsn_name"
dbtype="mysql" username="" password="" />
</Datasources>
-->

<!--IOC Integration
<IOC>
<Framework type="coldspring or lightwire" reload="true or false"
objectCaching="true or false">definition file</Framework>
<ParentFactory type="coldspring or lightwire>definition file</
ParentFactory>
</IOC>
-->

<!-- Cache Settings
<Cache>
<ObjectDefaultTimeout>60</ObjectDefaultTimeout>
<ObjectDefaultLastAccessTimeout>30</ObjectDefaultLastAccessTimeout>
<UseLastAccessTimeouts>true</UseLastAccessTimeouts>
<ReapFrequency>1</ReapFrequency>
<MaxObjects>100</MaxObjects>
<FreeMemoryPercentageThreshold>0</FreeMemoryPercentageThreshold>
<EvictionPolicy>LRU</EvictionPolicy>
</Cache>
-->

<!-- Debugger Settings
<DebuggerSettings>
<EnableDumpVar>true</EnableDumpVar>
<PersistentRequestProfiler>true</PersistentRequestProfiler>
<maxPersistentRequestProfilers>10</maxPersistentRequestProfilers>
<maxRCPanelQueryRows>50</maxRCPanelQueryRows>
<TracerPanel show="true" expanded="true" />
<InfoPanel show="true" expanded="true" />
<CachePanel show="true" expanded="false" />
<RCPanel show="true" expanded="false" />
</DebuggerSettings>
-->

<!-- Mail Server Settings
<MailServerSettings>
<MailServer></MailServer>
<MailPort></MailPort>
<MailUsername></MailUsername>
<MailPassword></MailPassword>
</MailServerSettings>
-->

<!-- Bug reporting aspect
<BugTracerReports enabled="false">
<MailFrom>mye...@gmail.com</MailFrom>
<CustomEmailBugReport>a custom bug report template</
CustomEmailBugReport>
<BugEmail>mye...@gmail.com</BugEmail>
</BugTracerReports>
-->

<!-- Web Services
<WebServices>
<WebService name="TESTWS1" URL="http://www.test.com/test1.cfc?wsdl" /
>
</WebServices>
-->

</Config>

============= handler/JobPosting.cfm ===================
<cfcomponent output="false" hint="Manage Job Postings"
extends="coldbox.system.EventHandler" >

<!--- Inject Dependencies --->
<cfproperty name="JobPostingService" inject="Model" scope="instance">

<!------------------------------------------- PUBLIC EVENTS
------------------------------------------>

<cffunction name="index" output="false" hint="index">
<cfargument name="event">
<cfset list(arguments.event)>
</cffunction>

<cffunction name="list" output="false" hint="list">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset rc.qContacts = JobPostingService.list()>

<cfset event.setView("JobPosting/list")>
</cffunction>

<cffunction name="add" output="false" hint="add">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.setView("JobPosting/add")>
</cffunction>

<cffunction name="create" output="false" hint="create">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.paramValue("name","")>
<cfset event.paramValue("email","")>

<!--- Verify posting info --->
<cfif NOT len(rc.name) OR NOT len(rc.email)>
<cfset getPlugin("MessageBox").warn("Please enter a value for email
and/or name")>
<cfset setNextEvent("JobPosting.add")>
</cfif>

<!--- Create posting --->
<cfset JobPostingService.create(rc.name,rc.email)>

<cfset getPlugin("MessageBox").info("Job Posting Created!")>
<cfset setNextEvent("JobPosting.list")>
</cffunction>

<cffunction name="delete" output="false" hint="delete">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.paramValue("id","")>

<!--- Remove posting --->
<cfset JobPostingService.remove( rc.id )>

<cfset getPlugin("MessageBox").info("Job Posting Removed!")>
<cfset setNextEvent("JobPosting.list")>
</cffunction>

<!------------------------------------------- PRIVATE EVENTS
------------------------------------------>

</cfcomponent>
============= handler/TransferRequest.cfm ===================
<cfcomponent output="false" hint="Manage Transfer Requests"
extends="coldbox.system.EventHandler" >

<!--- Inject Dependencies --->
<cfproperty name="TransferRequestService" inject="Model"
scope="instance">
<!------------------------------------------- PUBLIC EVENTS
------------------------------------------>

<cffunction name="index" output="false" hint="index">
<cfargument name="event">
<cfset list(arguments.event)>
</cffunction>

<cffunction name="list" output="false" hint="list">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset rc.qRequests = TransferRequestService.list()>

<cfset event.setView("TransferRequest/list")>
</cffunction>

<cffunction name="add" output="false" hint="add">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.setView("TransferRequest/add")>
</cffunction>

<cffunction name="createTransferRequest" output="false"
hint="createTransferRequest">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.paramValue("clockNbr","")>
<cfset event.paramValue("userName","")>

<!--- Verify user info --->
<cfif NOT len(rc.clockNbr) OR NOT len(rc.userName)>
<cfset getPlugin("MessageBox").warn("Please enter a value for
clockNbr and/or userName")>
<cfset setNextEvent("TransferRequest.add")>
</cfif>

<!--- Create Contact --->
<cfset TransferRequestService.create(rc.clockNbr,rc.userName)>

<cfset getPlugin("MessageBox").info("Transfer Request Created!")>
<cfset setNextEvent("TransferRequest.list")>
</cffunction>

<cffunction name="delete" output="false" hint="delete">
<cfargument name="event">
<cfset var rc = event.getCollection()>

<cfset event.paramValue("id","")>

<!--- Remove Contact --->
<cfset TransferRequestService.remove( rc.id )>

<cfset getPlugin("MessageBox").info("Transfer Request Removed!")>
<cfset setNextEvent("TransferRequest.list")>
</cffunction>

<!------------------------------------------- PRIVATE EVENTS
------------------------------------------>

</cfcomponent>
============= model/TransferRequest/TransferRequest.cfm
===================
/**
* DAO to handle TransferRequest operations.
* @author Michael Blakeslee
*/
component persistent="true" table="TBXX49_Transfer_Request" {

// Properties
property name="id" column="nc_id" type="numeric" ormtype="int"
fieldtype="id" generator="sequence"
params={sequence='gc_TRJP_TBXX49_Transfer_Request'};
property name="clockNbr" column="tc_clocknbr" type="string"
length="8" ormtype="string";
property name="userName" column="tc_userName" type="string"
length="120" ormtype="string";

// Relationships

// DEPENDENCIES via WireBOX
property name="DateUtil" inject="model" persistent="false";

}
============= model/TransferRequest/TransferRequestService.cfm
===================
/**
* Service to handle TransferRequest operations.
* @author Michael Blakeslee
*/
component extends="coldbox.system.orm.hibernate.VirtualEntityService"
singleton {


/**
* Constructor
*/
public TransferRequestService function init(){
// init it
super.init(entityName="TransferRequest");
return this;
}

}
============= model/JobPosting/JobPosting.cfm ===================
/**
* DAO to handle TransferRequest operations.
* @author Michael Blakeslee
*/
component persistent="true" table="TBXX50_Job_Posting" {

// Properties
property name="id" column="nc_id" type="numeric" ormtype="int"
fieldtype="id" generator="sequence"
params={sequence='gc_TRJP_TBXX50_Job_Posting'};
property name="name" column="tc_name" type="string" length="120"
ormtype="string";
property name="email" column="tc_email" type="string" length="120"
ormtype="string";

// Relationships

// DEPENDENCIES via WireBOX
property name="DateUtil" inject="model" persistent="false";

}
============= model/JobPosting/JobPostingService.cfm
===================
/**
* Service to handle Job Posting operations.
* @author Michael Blakeslee
*/
component extends="coldbox.system.orm.hibernate.VirtualEntityService"
singleton {

/**
* Constructor
*/
public JobPostingService function init(){
// init it
super.init(entityName="JobPosting");

return this;
}

}

Aaron Greenlee

unread,
Jan 2, 2011, 10:27:04 PM1/2/11
to col...@googlegroups.com
You are very close--just a scoping issue.

<cfproperty name="JobPostingService" inject="Model" scope="instance">

In the above line you are instructing ColdBox to place the JobPostingService in the variables.instance structure; however, you are trying to reference the service without identifying the scope--so, ColdFusion is trying to access variables.JobPostingService.

To resolve, you can simply omit the 'scope=instance' in your DI declaration, or, add prefix all your references to your service with variables.instance or instance.

On another note, since you are using ColdBox 3.0 and ColdFusion 9 you may want to consider using the ColdBox.cfc method of configuring your application over the ColdBox.XML format. It's very nice to be able to programmatically configure your application rather than just providing key/values via XML.

Welcome to the ColdBox community!

Aaron Greenlee

Michael

unread,
Jan 3, 2011, 6:27:57 AM1/3/11
to ColdBox Platform
Thanks for the welcome.

Took out the 'scope="instance"' and get the same result. Didn't have
it in my original but had added it after looking at other examples/
discussions. Have added my application.cfc and the log output below.
The tables are created in the schema, but am allowing the ORM to drop/
create the tables.

FYI, I know that in the debugging the path for ColdBox says D:\sysdev
\downloads\coldbox_2.6.4\ but it contains 3.0.0.RC1.

================ application.cfc ==========================

<!-----------------------------------------------------------------------
********************************************************************************
Copyright 2005-2007 ColdBox Framework by Luis Majano and Ortus
Solutions, Corp
www.coldboxframework.com | www.luismajano.com | www.ortussolutions.com
********************************************************************************

Author : Luis Majano
Date : 10/16/2007
Description :
This is the Application.cfc for usage withing the ColdBox Framework.
Make sure that it extends the coldbox object:
coldbox.system.coldbox

So if you have refactored your framework, make sure it extends
coldbox.
-----------------------------------------------------------------------
>
<cfcomponent extends="coldbox.system.Coldbox" output="false">

<!--- APPLICATION CFC PROPERTIES --->
<cfset this.HLQ="HR06TRJP">

<cfset this.name = this.HLQ & " (" & hash(getCurrentTemplatePath()) &
")">
<cfset this.sessionManagement = true>
<cfset this.sessionTimeout = createTimeSpan(0,0,30,0)>
<cfset this.setClientCookies = true>

// ORM Setup
this.ormEnabled = "true";
this.datasource = "#this.HLQ#";
this.ormSettings = {
cfclocation="model",
dbcreate = "dropcreate",
dialect = "Oracle10g",//Specifies the dialect.
logSQL = "true",
eventhandling = "true",
eventhandler = "model.utilities.ORMEventHandler",
flushAtRequestEnd = "false"
};

<!--- COLDBOX STATIC PROPERTY, DO NOT CHANGE UNLESS THIS IS NOT THE
ROOT OF YOUR COLDBOX APP --->
<cfset COLDBOX_APP_ROOT_PATH =
getDirectoryFromPath(getCurrentTemplatePath())>

<!--- COLDBOX PROPERTIES --->
<cfset COLDBOX_CONFIG_FILE = "">

<!--- on Application Start --->
<cffunction name="onApplicationStart" returnType="boolean"
output="false">
<cfscript>
//Load ColdBox
loadColdBox();
return true;
</cfscript>
</cffunction>

<!--- on Request Start --->
<cffunction name="onRequestStart" returnType="boolean" output="true">
<!--- *************************************************************
--->
<cfargument name="targetPage" type="string" required="true" />
<!--- *************************************************************
--->
<cfsetting enablecfoutputonly="yes">

<!--- Reload Checks --->
<cfset reloadChecks()>

<!--- Process A ColdBox Request Only --->
<cfif findNoCase('index.cfm', listLast(arguments.targetPage, '/'))>
<cfset processColdBoxRequest()>
</cfif>

<!--- WHATEVER YOU WANT BELOW --->
<cfsetting enablecfoutputonly="no">
<cfreturn true>
</cffunction>

<!--- on Application End --->
<cffunction name="onApplicationEnd" returnType="void"
output="false">
<!--- *************************************************************
--->
<cfargument name="applicationScope" type="struct" required="true">
<!--- *************************************************************
--->
<!--- WHATEVER YOU WANT BELOW --->
</cffunction>

<!--- on Session Start --->
<cffunction name="onSessionStart" returnType="void"
output="false">
<cfset super.onSessionStart()>
<!--- WHATEVER YOU WANT BELOW --->
</cffunction>

<!--- on Session End --->
<cffunction name="onSessionEnd" returnType="void" output="false">
<!--- *************************************************************
--->
<cfargument name="sessionScope" type="struct" required="true">
<cfargument name="appScope" type="struct" required="false">
<!--- *************************************************************
--->
<cfset super.onSessionEnd(argumentCollection=arguments)>
<!--- WHATEVER YOU WANT BELOW --->
</cffunction>

</cfcomponent>

================ Log output ==========================


"Severity","Appender","Date","Time","Category","Message"
"DEBUG","fileLog","01/03/2011","05:18:14","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","05:18:14","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 7971450"
"DEBUG","fileLog","01/03/2011","05:18:14","coldbox.system.interceptors.SES","SES
Route matched:
{PATTERN={:handler/},PACKAGERESOLVEREXEMPT={false},CONSTRAINTS={{}},PATTERNPARAMS={[handler]},MODULE={},MODULEROUTING={},REGEXPATTERN={([
^/]+?)/},VALUEPAIRTRANSLATION={true},VIEWNOLAYOUT={false}} on routed
string: TransferRequest/"
"DEBUG","fileLog","01/03/2011","05:18:14","coldbox.system.plugins.BeanFactory","getModelDSL()
cannot find model object
TransferRequestService using definition
{NAME={TransferRequestService},SCOPE={variables},TYPE={Model}}"
"DEBUG","fileLog","01/03/2011","05:18:14","coldbox.system.plugins.BeanFactory","Dependency:
{NAME={TransferRequestService},SCOPE={variables},TYPE={Model}} Not
Found when wiring
protected.mblakesl.HR06TRJP_NEW.handlers.TransferRequest"
"ERROR","fileLog","01/03/2011","05:18:14","HR06TRJP","Application
Execution Exception
ExtraInfo:CFErrorType=ExpressionCFMessage=Variable
TRANSFERREQUESTSERVICE is
undefined.CFStackTrace=coldfusion.runtime.UndefinedVariableException:
Variable TRANSFERREQUESTSERVICE is
undefined.
at coldfusion.runtime.CfJspPage._get(CfJspPage.java:303)
at coldfusion.runtime.CfJspPage._get(CfJspPage.java:283)
at coldfusion.runtime.CfJspPage._get(CfJspPage.java:271)
at cfTransferRequest2ecfc1253590519$funcLIST.runFunction(D:\sysdev
\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc:16)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2582)
at cfTransferRequest2ecfc1253590519$funcINDEX.runFunction(D:\sysdev
\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc:9)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:495)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:354)
at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2301)
at coldfusion.tagext.lang.InvokeTag.doEndTag(InvokeTag.java:382)
at coldfusion.runtime.CfJspPage._emptyTcfTag(CfJspPage.java:2723)
at cfController2ecfc1178273793$funcINVOKER.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\web\Controller.cfc:662)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2582)
at cfController2ecfc1178273793$funcRUNEVENT.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\web\Controller.cfc:553)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:495)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:354)
at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2301)
at cfColdbox2ecfc1451573489$funcPROCESSCOLDBOXREQUEST.runFunction(D:
\sysdev\downloads\coldbox_2.6.4\system\Coldbox.cfc:226)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2582)
at cfApplication2ecfc434716861$funcONREQUESTSTART.runFunction(D:
\sysdev\mblakesl\HR06TRJP_NEW\Application.cfc:66)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:490)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:336)
at coldfusion.runtime.AppEventInvoker.invoke(AppEventInvoker.java:88)
at
coldfusion.runtime.AppEventInvoker.onRequestStart(AppEventInvoker.java:
258)
at coldfusion.filter.ApplicationFilter.invoke(ApplicationFilter.java:
331)
at
coldfusion.filter.RequestMonitorFilter.invoke(RequestMonitorFilter.java:
48)
at coldfusion.filter.MonitoringFilter.invoke(MonitoringFilter.java:
40)
at coldfusion.filter.PathFilter.invoke(PathFilter.java:87)
at coldfusion.filter.ExceptionFilter.invoke(ExceptionFilter.java:70)
at
coldfusion.filter.BrowserDebugFilter.invoke(BrowserDebugFilter.java:
74)
at
coldfusion.filter.ClientScopePersistenceFilter.invoke(ClientScopePersistenceFilter.java:
28)
at coldfusion.filter.BrowserFilter.invoke(BrowserFilter.java:38)
at coldfusion.filter.NoCacheFilter.invoke(NoCacheFilter.java:46)
at coldfusion.filter.GlobalsFilter.invoke(GlobalsFilter.java:38)
at coldfusion.filter.DatasourceFilter.invoke(DatasourceFilter.java:
22)
at coldfusion.filter.CachingFilter.invoke(CachingFilter.java:53)
at coldfusion.CfmServlet.service(CfmServlet.java:200)
at
coldfusion.bootstrap.BootstrapServlet.service(BootstrapServlet.java:
89)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:86)
at
coldfusion.monitor.event.MonitoringServletFilter.doFilter(MonitoringServletFilter.java:
42)
at coldfusion.bootstrap.BootstrapFilter.doFilter(BootstrapFilter.java:
46)
at jrun.servlet.FilterChain.doFilter(FilterChain.java:94)
at jrun.servlet.FilterChain.service(FilterChain.java:101)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:106)
at jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at
jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:
286)
at
jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:
543)
at
jrun.servlet.jrpp.JRunProxyService.invokeRunnable(JRunProxyService.java:
203)
at jrunx.scheduler.ThreadPool
$ThreadThrottle.invokeRunnable(ThreadPool.java:428)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)
CFTagContext=ID: ??; LINE: 16; TEMPLATE: D:\sysdev\mblakesl
\HR06TRJP_NEW\handlers\TransferRequest.cfc ID: CF_UDFMETHOD; LINE: 9;
TEMPLATE: D:\sysdev\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc
ID: CFINVOKE; LINE: 662; TEMPLATE:
D:\sysdev\downloads\coldbox_2.6.4\system\web\Controller.cfc ID:
CF_UDFMETHOD; LINE: 553; TEMPLATE:
D:\sysdev\downloads\coldbox_2.6.4\system\web\Controller.cfc ID:
CF_TEMPLATEPROXY; LINE: 226; TEMPLATE:
D:\sysdev\downloads\coldbox_2.6.4\system\Coldbox.cfc ID: CF_UDFMETHOD;
LINE: 66; TEMPLATE:
D:\sysdev\mblakesl\HR06TRJP_NEW\Application.cfc"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 7971450"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 7971450"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.interceptors.SES","No
SES routes matched on routed string: /"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.interceptors.SES","No
SES routes matched on routed string: /"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 7971450"
"DEBUG","fileLog","01/03/2011","05:18:15","coldbox.system.interceptors.SES","No
SES routes matched on routed string: /"

Aaron Greenlee

unread,
Jan 3, 2011, 11:44:54 AM1/3/11
to col...@googlegroups.com
Are you able to get a reference to the model with getModel('JobPostingService') or getModel('TransferRequestService) ?

If not, it is likely an issue with the model mappins.

Michael

unread,
Jan 3, 2011, 3:32:06 PM1/3/11
to ColdBox Platform
No, getModel() doesn't work either. I put it into the list method of
the handler. Can I get more visibility of the system.plugins.*
through the logger?

Each model and service are in a subdirectory, so JobPostingService.cfc
and JobPosting.cfc are in model/JobPosting/ and
TransferRequestService.cfc and TransferRequest.cfc are in model/
TransferRequest/

I can see from the log that I have an issue with finding the model,
but I don't understand what it is. I AM supposed to map the service,
correct?

Thanks.....

===================== config/ModelMappings.cfm
===================================

<cfscript>
/* Add all the model mappings you want */
/* addModelMapping(alias="",path="") */

addModelMapping(alias="TransferRequestService",path="model.TransferRequest.TransferRequestService");

addModelMapping(alias="JobPostingService",path="model.JobPosting.JobPostingService");
addModelMapping(alias="DateUtil",path="model.utilities.DateUtil");
</cfscript>

===================== log ===================================


"Severity","Appender","Date","Time","Category","Message"
"DEBUG","fileLog","01/03/2011","14:26:01","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","14:26:01","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 22499939"
"DEBUG","fileLog","01/03/2011","14:26:01","coldbox.system.interceptors.SES","SES
Route matched:

{PATTERN={:handler/},PACKAGERESOLVEREXEMPT={false},CONSTRAINTS={{}},PATTERNPARAMS={[handler]},MODULE={},MODULEROUTING={},REGEXPATTERN={([

^/]+?)/},VALUEPAIRTRANSLATION={true},VIEWNOLAYOUT={false}} on routed
string: TransferRequest/"
"DEBUG","fileLog","01/03/2011","14:26:02","coldbox.system.plugins.BeanFactory","getModelDSL()
cannot find model object

TransferRequestService using definition
{NAME={TransferRequestService},SCOPE={variables},TYPE={Model}}"
"DEBUG","fileLog","01/03/2011","14:26:02","coldbox.system.plugins.BeanFactory","Dependency:

{NAME={TransferRequestService},SCOPE={variables},TYPE={Model}} Not
Found when wiring

protected.mblakesl.HR06TRJP_NEW.handlers.TransferRequest"
"ERROR","fileLog","01/03/2011","14:26:02","HR06TRJP","Application
Execution Exception

ExtraInfo:CFErrorType=BeanFactory.modelNotFoundException
CFDetails=The model object could not be located in the following
locations:

D:\sysdev\mblakesl\HR06TRJP_NEW\model OR
CFMessage=Model model.TransferRequest.TransferRequestService could not
be located.
C

FStackTrace=coldfusion.runtime.CustomException: Model
model.TransferRequest.TransferRequestService could not be located.
at coldfusion.tagext.lang.ThrowTag.doStartTag(ThrowTag.java:142)
at coldfusion.runtime.CfJspPage._emptyTcfTag(CfJspPage.java:2722)
at cfFrameworkSupertype2ecfc406421362$func$THROW.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\FrameworkSupertype.cfc:425)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)
at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2547)
at cfBeanFactory2ecfc1799257272$funcGETMODEL.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\plugins\BeanFactory.cfc:207)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:495)
at coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:354)
at coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2301)
at

cfFrameworkSupertype2ecfc406421362$funcGETMODEL.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\FrameworkSupertype.cfc:107)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472)
at coldfusion.filter.SilentFilter.invoke(SilentFilter.java:47)
at coldfusion.runtime.UDFMethod
$ReturnTypeFilter.invoke(UDFMethod.java:405)
at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368)
at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55)
at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220)
at coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2582)
at cfTransferRequest2ecfc1253590519$funcLIST.runFunction(D:\sysdev
\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc:15)
CFTagContext=ID: CFTHROW; LINE: 425; TEMPLATE: D:\sysdev\downloads
\coldbox_2.6.4\system\FrameworkSupertype.cfc
ID: CF_UDFMETHOD; LINE:

207; TEMPLATE: D:\sysdev\downloads\coldbox_2.6.4\system\plugins
\BeanFactory.cfc
ID: CF_TEMPLATEPROXY; LINE: 107; TEMPLATE:

D:\sysdev\downloads\coldbox_2.6.4\system\FrameworkSupertype.cfc
ID: CF_UDFMETHOD; LINE: 15; TEMPLATE:

D:\sysdev\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc
ID: CF_UDFMETHOD; LINE: 9; TEMPLATE:

D:\sysdev\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc
ID: CFINVOKE; LINE: 662; TEMPLATE:

D:\sysdev\downloads\coldbox_2.6.4\system\web\Controller.cfc
ID: CF_UDFMETHOD; LINE: 553; TEMPLATE:

D:\sysdev\downloads\coldbox_2.6.4\system\web\Controller.cfc
ID: CF_TEMPLATEPROXY; LINE: 226; TEMPLATE:

D:\sysdev\downloads\coldbox_2.6.4\system\Coldbox.cfc
ID: CF_UDFMETHOD; LINE: 66; TEMPLATE:

D:\sysdev\mblakesl\HR06TRJP_NEW\Application.cfc"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 22499939"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 22499939"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.interceptors.SES","No
SES routes matched on routed string: /"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.interceptors.SES","No
SES routes matched on routed string: /"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.web.services.RequestService","Request
Context set on request scope"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.cache.CacheFactory","Executing
reap on factoryID: 22499939"
"DEBUG","fileLog","01/03/2011","14:26:03","coldbox.system.interceptors.SES","No

Luis Majano

unread,
Jan 3, 2011, 5:27:26 PM1/3/11
to col...@googlegroups.com
Don't use the path model on the alias.

Sent from my iPhone

> --
> You received this message because you are subscribed to the Google Groups "ColdBox Platform" group.
> To post to this group, send email to col...@googlegroups.com
> To unsubscribe from this group, send email to coldbox-u...@googlegroups.com
> For more options, visit this group at http://groups-beta.google.com/group/coldbox
> For News, visit http://blog.coldbox.org
> For Documentation, visit http://wiki.coldbox.org

Michael

unread,
Jan 4, 2011, 10:47:30 AM1/4/11
to ColdBox Platform
I am now to the point where I am getting a "ORM is not configured for
the current application". I went back and did the generic CF ORM
example Artists to make sure that things were working on the CF end
and was able to get the app to run successfully in Oracle.

I am thinking at this point that the issue is with my use of the orm
event handler.

How can I debug this? Can I get more information using the logger as
to where the problem is? What I need to help myself is a good example
how to debug and trace within this framework as it relates to the CF
ORM. I did look at the EXTRAS:CFORM docs. Can you point me in the
right direction?

I have been using the simple blog5 and crud as my reference apps.

What other information do you need to help me?

Thanks......

Dorioo

unread,
Jan 4, 2011, 10:56:49 AM1/4/11
to col...@googlegroups.com
If you're getting "ORM is not configured for the current application" and you've set it up, try running <cfset ormReload()> .I think that's fixed that error in the past for me.

- Gabriel

Michael

unread,
Jan 4, 2011, 3:55:07 PM1/4/11
to ColdBox Platform
Tried, but it doesn't work.

The issue seems to be in VirtualEntityService when it is initialized
to create the TransferRequestService. The object is returned but no
methods for the object are functional. In fact, the call to
TransferRequestService.list() is what generates the error about the
ORM not being functional.

When dumped the object has 4 properties and the VirtualEntityService
methods:

queryCacheRegion ORMService.defaultCache
useQueryCaching false
eventHandling true
entityName TransferRequest

Any other thoughts?

Luis Majano

unread,
Jan 4, 2011, 6:36:49 PM1/4/11
to col...@googlegroups.com
I am late to this, sorry.  Can you redefine the problem so I can take a look

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com


Michael

unread,
Jan 4, 2011, 11:40:11 PM1/4/11
to ColdBox Platform
I am trying to troubleshoot ORM functionality provided through the
VirtualEntityService. I successfully tested the basic CF9 orm through
my datasource using the Artists example from adobe so I know that part
is working. I probably have some syntax or scoping problem since this
is my first project. I am using CF9 on windows server 2008, ColdBox
RC1, and oracle 11g. I currently have two tables/objects which are
accessed through services and two handlers. I used the base
application as generated adding models and handlers based on the
simpleCRUD and simple-blog-5 projects, plus a couple of other
examples.

ORMsettings has an event handler. I am getting the service object
instantiated in my handler. The handler creates the service object but
none of the methods are functional. I have include that top part of
the error trace below where the object handler is called and list() is
invoked to populate the view. What other pieces would you like to
see? I am happy to troubleshoot my own problem but am having
difficulty understanding how to determine where the error is. If
there is a good troubleshooting tutorial, point me to it.

Thanks for your help.......

Message:
ERROR 10:34:09.882 PM HR06TRJP
Application Execution Exception
ExtraInformation:
CFErrorType=Application CFMessage=ORM is not configured for the
current application. CFStackTrace=coldfusion.orm.ORMUtils
$ORMNotConfiguredException: ORM is not configured for the current
application. at
coldfusion.orm.ORMUtils.getPersistenceManager(ORMUtils.java:46) at
coldfusion.orm.ORMUtils.entityLoad(ORMUtils.java:154) at
coldfusion.runtime.CFPage.EntityLoad(CFPage.java:7618) at
cfBaseORMService2ecfc824939797$funcLIST.runFunction(D:\sysdev\downloads
\coldbox_2.6.4\system\orm\hibernate\BaseORMService.cfc:127) at
coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472) at
coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:
405) at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368) at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55) at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:517) at
coldfusion.runtime.CfJspPage._invokeUDF(CfJspPage.java:2547) at
coldfusion.runtime.SuperScope.invoke(SuperScope.java:18) at
coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2301) at
cfVirtualEntityService2ecfc345824574$funcLIST.runFunction(D:\sysdev
\downloads\coldbox_2.6.4\system\orm\hibernate\VirtualEntityService.cfc:
76) at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:472) at
coldfusion.runtime.UDFMethod$ReturnTypeFilter.invoke(UDFMethod.java:
405) at coldfusion.runtime.UDFMethod
$ArgumentCollectionFilter.invoke(UDFMethod.java:368) at
coldfusion.filter.FunctionAccessFilter.invoke(FunctionAccessFilter.java:
55) at coldfusion.runtime.UDFMethod.runFilterChain(UDFMethod.java:321)
at coldfusion.runtime.UDFMethod.invoke(UDFMethod.java:220) at
coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:490) at
coldfusion.runtime.TemplateProxy.invoke(TemplateProxy.java:336) at
coldfusion.runtime.CfJspPage._invoke(CfJspPage.java:2360) at
cfTransferRequest2ecfc1253590519$funcLIST.runFunction(D:\sysdev
\mblakesl\HR06TRJP_NEW\handlers\TransferRequest.cfc:29) at
\mblakesl\HR06TRJP_NEW\Application.cfc:67) at co

Luis Majano

unread,
Jan 5, 2011, 11:12:55 AM1/5/11
to col...@googlegroups.com
Have you used the SimpleBlog application? Does that work for you?

-- 

Luis F. Majano
President
Ortus Solutions, Corp

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Curt Gratz

unread,
Jan 5, 2011, 11:16:35 AM1/5/11
to col...@googlegroups.com

Also,

 

Have you tried accessing your entity directly, via entityLoad?  It could be a syntax issue with your entity cfc.

 

Curt

Michael

unread,
Jan 6, 2011, 10:10:42 AM1/6/11
to ColdBox Platform
Yes, I was able to get SimpleBlog5 running with a couple of caveats:

Changed this.ormsettings.
<cfset this.ormSettings = {
dbcreate = "dropcreate",
cfclocation="model",
dialect = "Oracle10g",
logSQL = true,
flushAtRequestEnd = true,
eventHandling = true,
eventHandler = "model.utilities.ORMEventHandler"
}>

Changed comment.cfc because of oracle reserved words time and comment
which caused the columns to be created in lowercase.
property name="comment" column="COMMENT_TEXT";
property name="time" column="CTIME" insert="false" update="false";

Changed Entry.cfc for the same reason
property name="time" column="CTIME" insert="false" update="false";

Changed the column type of EntryBody and commentBody to long.

Changed data loader to work with oracle.

Seemed to have issues with the cache and restarted jrun. The first
time the app ran, threw an error stating the tables weren't there,
second time worked so I am guessing some of the issues have to do with
the defaults when creating the tables in oracle. When I get a working
sql script, will send an oracle version of install/mysql.sql.

How can I force the application ORM and cache to fully flush and
reinitialize? Is that ormreload()? How can I troubleshoot orm
initialization issues?

Thanks for your patience...

Curt Gratz

unread,
Jan 6, 2011, 10:28:12 AM1/6/11
to col...@googlegroups.com
Michael,

You are correct, ormreload() is what you want to use. I have this run whenever I run a framework reinit so both ORM and ColdBox start over.

Curt

Thanks for your patience...

Michael

unread,
Jan 7, 2011, 3:44:38 PM1/7/11
to ColdBox Platform
I took another path and took the SimpleBlog5 as my starting point and
moved my handlers and model pieces in and it is starting to come
together. Would be interested in why I couldn't do it with the
generated code tree.

Since my app is now using config/coldbox.cfc was tring to add
coldboxsidebar to my development view. Added the structure below to
interceptors array and while I am not throwing an error, the sidebat
does not appear. Does anyone see any issues the the code below?

//SideBar
{class="coldbox.system.interceptors.coldboxSideBar",
properties = {
yOffset = 50,
isScroll = false,
slideSpeed = 15,
waitTimeBeforeOpen = 5,
links = [
{desc="ColdBox API",href="http:\/\/www.coldbox.org\/api\/"}
,{desc="ColdBox SideBar Help",href="http:\/\/
ortus.svnrepository.com\/coldbox\/trac.cgi\/wiki\/cbSideBar"}
,{desc="ColdBox Credits",href="http:\/\/
ortus.svnrepository.com\/coldbox\/trac.cgi\/wiki\/cbCredits"}
]
}}


I also tried to use <cfgrid> with the output from list() and nothing
would display unless I specified the columns with <cfgridcolumn>. I
was able to dump the query so I know there was data there. Anyone
know the reason that the query wouldn't work without defining the
columns?

Also, Is there a way to add attributes to the model properties and
access them. I wanted to put label information with the model so I
can dynamically generate forms for a model. Maybe there is another
approach in this framework?

Thanks,

MCB
> ...
>
> read more »

Luis Majano

unread,
Jan 7, 2011, 11:42:39 PM1/7/11
to col...@googlegroups.com
You can get the properties by using grtmetadata on the model instance. Also the sidebar needs the declaration plus a setting. I can't remember it now but it is on the docs.

Sent from my iPhone

Reply all
Reply to author
Forward
0 new messages