mirror of
https://github.com/sismics/docs.git
synced 2024-11-22 05:57:57 +01:00
increase h2 lock timeout
This commit is contained in:
parent
94951c59f3
commit
8bd4d27d2f
@ -231,11 +231,11 @@ public class DocumentDao {
|
|||||||
* @param document Document
|
* @param document Document
|
||||||
*/
|
*/
|
||||||
public void updateFileId(Document document) {
|
public void updateFileId(Document document) {
|
||||||
/*EntityManager em = ThreadLocalContext.get().getEntityManager();
|
EntityManager em = ThreadLocalContext.get().getEntityManager();
|
||||||
Query query = em.createNativeQuery("update T_DOCUMENT d set d.DOC_IDFILE_C = :fileId where d.DOC_ID_C = :id");
|
Query query = em.createNativeQuery("update T_DOCUMENT d set d.DOC_IDFILE_C = :fileId where d.DOC_ID_C = :id");
|
||||||
query.setParameter("fileId", document.getFileId());
|
query.setParameter("fileId", document.getFileId());
|
||||||
query.setParameter("id", document.getId());
|
query.setParameter("id", document.getId());
|
||||||
query.executeUpdate();*/
|
query.executeUpdate();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ public final class EMF {
|
|||||||
if (databaseUrl == null) {
|
if (databaseUrl == null) {
|
||||||
props.put("hibernate.connection.driver_class", "org.h2.Driver");
|
props.put("hibernate.connection.driver_class", "org.h2.Driver");
|
||||||
props.put("hibernate.dialect", "org.hibernate.dialect.HSQLDialect");
|
props.put("hibernate.dialect", "org.hibernate.dialect.HSQLDialect");
|
||||||
props.put("hibernate.connection.url", "jdbc:h2:file:" + dbFile + ";CACHE_SIZE=65536");
|
props.put("hibernate.connection.url", "jdbc:h2:file:" + dbFile + ";CACHE_SIZE=65536;LOCK_TIMEOUT=10000");
|
||||||
props.put("hibernate.connection.username", "sa");
|
props.put("hibernate.connection.username", "sa");
|
||||||
} else {
|
} else {
|
||||||
props.put("hibernate.connection.driver_class", "org.postgresql.Driver");
|
props.put("hibernate.connection.driver_class", "org.postgresql.Driver");
|
||||||
|
Loading…
Reference in New Issue
Block a user