我正在通过ColdFusion创建一个简单的CRUD应用程序.我要去ColdFusion管理员面板http://localhost:8600/CFIDE/administrator/index.cfm,并添加一个"新数据源".但是我收到以下错误:
Connection verification failed for data source: dsnMyVariable
java.sql.SQLNonTransientConnectionException: Could not create connection to database server. Attempted reconnect 3 times. Giving up.
The root cause was that: java.sql.SQLNonTransientConnectionException: Could not create connection to database server. Attempted reconnect 3 times. Giving up.
Run Code Online (Sandbox Code Playgroud)
如何在 Coldfusion 线程中使用函数参数?我不明白为什么会出现以下错误:
元素 SOMEID 在 ARGUMENTS 中未定义。
我的代码的简化示例。
public any function createSomeEntity(required numeric someId) {
thread action="run" name="someThread" {
var result = someFunction(someId = arguments.someId);
// some logic
}
thread action="join" name="someThread" timeout="5000";
if (someThread.status != "COMPLETED") {
// action 1
} else {
// action 2
}
}
Run Code Online (Sandbox Code Playgroud)