Skip to content

Commit 07acc4c

Browse files
committed
more wip on boxlang prime
1 parent cc0b268 commit 07acc4c

10 files changed

Lines changed: 55 additions & 64 deletions

File tree

server-boxlang@1.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
},
2121
"JVM":{
2222
"heapSize":"768",
23+
"javaVersion":"openjdk21_jre",
2324
"args":"-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=9999"
2425
},
2526
"cfconfig":{
@@ -29,6 +30,7 @@
2930
"BOXLANG_DEBUG":true
3031
},
3132
"scripts":{
32-
"onServerInitialInstall":"install bx-mail,bx-pdf,bx-mysql,bx-esapi,testbox@be --noSave"
33-
}
33+
"onServerInitialInstall":"install bx-mail,bx-pdf,bx-mysql,bx-esapi,bx-orm@be --noSave"
34+
},
35+
"conosole":true
3436
}

system/core/database/SchemaInfo.cfc

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -188,20 +188,4 @@ component singleton {
188188
}
189189
}
190190

191-
/**
192-
* Get the query param type for a specific datasource for a date/time column
193-
*
194-
* @dsn The datasource name
195-
* @username The username to use
196-
* @password The password to use
197-
* @deprecated There are no longer any instances where this would be different between engines. Deprecate in 7.x and remove in 8x.
198-
*/
199-
public string function getQueryParamDateTimeType(
200-
required string dsn,
201-
username = "",
202-
password = ""
203-
){
204-
return "cf_sql_timestamp";
205-
}
206-
207191
}

system/logging/appenders/DBAppender.cfc

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ component accessors="true" extends="coldbox.system.logging.AbstractAppender" {
9292

9393
// DB Rotation Time
9494
variables.lastDBRotation = "";
95-
variables.queryParamDataTimeType = variables.schemaInfo.getQueryParamDateTimeType( getProperty( "dsn" ) );
95+
variables.queryParamDataTimeType = "timestamp";
9696
return this;
9797
}
9898

@@ -230,31 +230,31 @@ component accessors="true" extends="coldbox.system.logging.AbstractAppender" {
230230
",
231231
{
232232
uuid : {
233-
cfsqltype : "cf_sql_varchar",
233+
cfsqltype : "varchar",
234234
value : "#variables.uuid.randomUUID().toString()#"
235235
},
236236
severity : {
237-
cfsqltype : "cf_sql_varchar",
237+
cfsqltype : "varchar",
238238
value : "#arguments.data.severity#"
239239
},
240240
category : {
241-
cfsqltype : "cf_sql_varchar",
241+
cfsqltype : "varchar",
242242
value : "#arguments.data.category#"
243243
},
244244
timestamp : {
245245
cfsqltype : variables.queryParamDataTimeType,
246246
value : "#arguments.data.timestamp#"
247247
},
248248
name : {
249-
cfsqltype : "cf_sql_varchar",
249+
cfsqltype : "varchar",
250250
value : "#left( getName(), 100 )#"
251251
},
252252
message : {
253-
cfsqltype : "cf_sql_varchar",
253+
cfsqltype : "varchar",
254254
value : "#arguments.data.message#"
255255
},
256256
extraInfo : {
257-
cfsqltype : "cf_sql_varchar",
257+
cfsqltype : "varchar",
258258
value : "#arguments.data.extraInfo#"
259259
}
260260
},

test-harness/Application.cfc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ component {
4646
this.mappings[ "/coldbox" ] = rootPath;
4747
// Test Harness Path
4848
this.mappings[ "/cbtestharness" ] = COLDBOX_APP_ROOT_PATH;
49-
5049
// Core Application.cfc mixins - ORM Settings, etc
5150
include "config/ApplicationMixins.cfm";
5251

test-harness/config/ApplicationMixins.cfm

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<cfscript>
22
3-
// Lucee 5 Cache Definition
3+
// Lucee Cache Definition
44
this.cache.connections[ "default" ] = {
55
"class" = 'lucee.runtime.cache.ram.RamCache'
66
, "storage" = false
@@ -15,7 +15,10 @@
1515
this.ormEnabled = true;
1616
this.datasource = "coolblog";
1717
this.ormSettings = {
18+
// CFML Approach
1819
cfclocation = "/cbtestharness/models/entities",
20+
// BoxLang approach
21+
entityPaths = "/cbtestharness/models/entities",
1922
logSQL = false,
2023
flushAtRequestEnd = false,
2124
autoManageSession = false,
Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
<!-----------------------------------------------------------------------Author : Luis MajanoDate : September 25, 2005Description : General handler for my hello application. Please remember to alter your extends base component using the Coldfusion Mapping. example: Mapping: fwsample Argument Type: fwsample.system.EventHandlerModification History:Sep/25/2005 - Luis Majano -Created the template.-----------------------------------------------------------------------><cfcomponent name="ehTest" extends="coldbox.system.EventHandler" output="false">
2-
<cffunction name="dspExternal" access="public" returntype="void" output="false">
3-
<cfargument name="Event" type="coldbox.system.web.context.RequestContext"><cfscript>
4-
var rc = Event.getCollection();
5-
Event.setView( "vwExternalHandler" );
6-
</cfscript>
7-
</cffunction>
8-
</cfcomponent>
1+
component{
2+
3+
function dspExternal( event, rc, prc ){
4+
event.setView( "vwExternalHandler" );
5+
}
6+
7+
}
Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1-
<!-----------------------------------------------------------------------Author : Luis MajanoDate : September 25, 2005Description : General handler for my hello application. Please remember to alter your extends base component using the Coldfusion Mapping. example: Mapping: fwsample Argument Type: fwsample.system.EventHandlerModification History:Sep/25/2005 - Luis Majano -Created the template.-----------------------------------------------------------------------><cfcomponent output="false">
2-
<cffunction name="dspExternal" access="public" returntype="void" output="false">
3-
<cfargument name="Event" type="coldbox.system.web.context.RequestContext"><cfscript>
4-
var rc = Event.getCollection();
5-
Event.setView( "vwExternalHandler" );
6-
</cfscript>
7-
</cffunction>
8-
</cfcomponent>
1+
component{
2+
3+
/**
4+
* This is a test handler that does not inherit from the base handler.
5+
* It is used to test the behavior of handlers without inheritance.
6+
*/
7+
function dspExternal( event, rc, prc ){
8+
event.setView( "vwExternalHandler" );
9+
}
10+
11+
}
Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1-
<!-----------------------------------------------------------------------Author : Luis MajanoDate : September 25, 2005Description : General handler for my hello application. Please remember to alter your extends base component using the Coldfusion Mapping. example: Mapping: fwsample Argument Type: fwsample.system.EventHandlerModification History:Sep/25/2005 - Luis Majano -Created the template.-----------------------------------------------------------------------><cfcomponent name="ehTest" extends="BaseTest" output="false">
2-
<cffunction name="dspExternal" access="public" returntype="void" output="false">
3-
<cfargument name="Event" type="coldbox.system.web.context.RequestContext"><cfscript>
4-
var rc = Event.getCollection();
5-
Event.setView( "vwExternalHandler" );
6-
</cfscript>
7-
</cffunction>
8-
</cfcomponent>
1+
component{
2+
3+
/**
4+
* This is a test handler for external testing
5+
*/
6+
function dspExternal( event, rc ){
7+
rc.message = "This is an external test handler";
8+
event.setView( "vwExternalHandler" );
9+
}
10+
11+
}
Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1-
<!-----------------------------------------------------------------------Author : Luis MajanoDate : September 25, 2005Description : General handler for my hello application. Please remember to alter your extends base component using the Coldfusion Mapping. example: Mapping: fwsample Argument Type: fwsample.system.EventHandlerModification History:Sep/25/2005 - Luis Majano -Created the template.-----------------------------------------------------------------------><cfcomponent name="message" extends="coldbox.system.EventHandler" output="false">
2-
<cffunction name="dspMessages" access="public" returntype="void" output="false">
3-
<cfargument name="Event" type="coldbox.system.web.context.RequestContext"><cfscript>
4-
var rc = Event.getCollection();
5-
Event.setView( "vwExternalHandler" );
6-
</cfscript>
7-
</cffunction>
8-
</cfcomponent>
1+
component{
2+
3+
/**
4+
* This is a test handler for external testing
5+
*/
6+
function dspExternal( event, rc ){
7+
rc.message = "This is an external test handler";
8+
event.setView( "vwExternalHandler" );
9+
}
10+
11+
}

tests/specs/core/database/SchemaInfoTest.cfc

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,6 @@ component extends="testbox.system.BaseSpec" {
4343
expect( data ).toBe( "LONGTEXT" );
4444
} );
4545

46-
it( "can get a query param data/time column type", function(){
47-
var data = schemaInfo.getQueryParamDateTimeType( dsn );
48-
expect( data ).toBe( "cf_sql_timestamp" );
49-
} );
50-
5146
it( "can get all the tables on the specified datasource", function(){
5247
var data = schemaInfo.getTables( dsn );
5348
expect( data ).toBeArray();

0 commit comments

Comments
 (0)