We're updating the issue view to help you get more done. 

shutdown/redeploy of workbench results in lock exception for query repository

Description

When using the tomcat manager to shut down the workbench application, undeploy it, and redeploy, an error appears when trying to access the workbench.

trace:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 javax.servlet.ServletException: org.openrdf.repository.RepositoryLockedException: SAIL is already locked by: 15047@deepthought in /home/jeen/.aduna/openrdf-workbench/queries org.openrdf.workbench.commands.QueryServlet.init(QueryServlet.java:136) org.openrdf.workbench.proxy.ProxyRepositoryServlet.createServlet(ProxyRepositoryServlet.java:131) org.openrdf.workbench.proxy.ProxyRepositoryServlet.init(ProxyRepositoryServlet.java:55) org.openrdf.workbench.proxy.WorkbenchServlet.service(WorkbenchServlet.java:238) org.openrdf.workbench.proxy.WorkbenchServlet.handleRequest(WorkbenchServlet.java:151) org.openrdf.workbench.proxy.WorkbenchServlet.service(WorkbenchServlet.java:119) org.openrdf.workbench.proxy.WorkbenchGateway.service(WorkbenchGateway.java:131) org.openrdf.workbench.base.BaseServlet.service(BaseServlet.java:137) org.openrdf.workbench.proxy.CookieCacheControlFilter.doFilter(CookieCacheControlFilter.java:63) root cause org.openrdf.repository.RepositoryLockedException: SAIL is already locked by: 15047@deepthought in /home/jeen/.aduna/openrdf-workbench/queries org.openrdf.repository.sail.SailRepository.initializeInternal(SailRepository.java:103) org.openrdf.repository.base.RepositoryBase.initialize(RepositoryBase.java:37) org.openrdf.workbench.util.QueryStorage.<init>(QueryStorage.java:133)

At first glance, it looks as if the workbench does not properly shut down the repository it uses for storing queries. Possible fix is a runtime shutdownhook, or switching to the new RepositoryProvider class (which takes care of shutting down cleanly for you).

Environment

Tomcat 7.0.32 (linux x64)

Status

Assignee

JeenB

Reporter

JeenB

Labels

None

Components

Fix versions

Affects versions

2.7.0

Priority

Major