Exception error:
Caused by: Org. apache. commons. DBCP. sqlnestedexception: cannot create poolableconnectionfactory (the database is already in use by another process: Org. HSQLDB. persist. niolockfile @ 4a60a3da: Java. lang. exception: the process cannot access the file because another program has locked part of the file. : D:/Zhao/code/OTAs-ds-workspace/OTAs-ds-server/output/funambol/tools/hypersonic/data/funambol. LCK)
At org. Apache. commons. DBCP. basicdatasource. createdatasource (basicdatasource. Java: 855)
At org. Apache. commons. DBCP. basicdatasource. getconnection (basicdatasource. Java: 540)
At com. Npower. Ds. Core. usersmsqueuedao. getquerylist (usersmsqueuedao. Java: 70)
... 42 more
Caused by: Java. SQL. sqlexception: the database is already in use by another process: Org. HSQLDB. persist. niolockfile @ 4a60a3da: Java. lang. exception: the process cannot access the file because another program has locked part of the file. : D:/Zhao/code/OTAs-ds-workspace/OTAs-ds-server/output/funambol/tools/hypersonic/data/funambol. LCK
At org. HSQLDB. JDBC. util. sqlexception (unknown source)
At org. HSQLDB. JDBC. jdbcconnection. (unknown source)
At org. HSQLDB. jdbcdriver. getconnection (unknown source)
At org. HSQLDB. jdbcdriver. Connect (unknown source)
At org. Apache. commons. DBCP. driverconnectionfactory. createconnection (driverconnectionfactory. Java: 37)
At org. Apache. commons. DBCP. poolableconnectionfactory. makeobject (poolableconnectionfactory. Java: 290)
At org. Apache. commons. DBCP. basicdatasource. validateconnectionfactory (basicdatasource. Java: 877)
At org. Apache. commons. DBCP. basicdatasource. createdatasource (basicdatasource. Java: 851)
... 44 more
After half a day, find the reason
It turns out to be a URL problem. It is written as a file.
<Parameter>
<Name> URL </Name>
<Value> JDBC: HSQLDB: file: C:/hypersonic/lib/../data/funambol </value>
</Parameter>
It should be:
<Parameter>
<Name> URL </Name>
<Value> JDBC: HSQLDB: hsql: // localhost/funambol </value>
</Parameter>
(I use the HSQLDB database as an example)