javax.jcr.lock.LockException: Node already locked: /prefix-repo-dev-release/com/company/pom-root

JFrog JIRA | Peter Lynch | 9 years ago
  1. 0

    I recently upgraded from revision 642 1.2.1-SNAPSHOT to 1.2.1 final release. Things went pretty smooth for a while - however after running the server for a while ( several days, not much traffic) and then trying to deploy a pom artifact, I noticed Internal Error 500 being returned. Looking at the logs I see that the node is already locked. I have no idea what is causing the locks but it keeps happening. I will mention that after restarting the server the same pom can be deployed without problem as it seems that locks are removed upon restart. However it always happens that eventually nodes will become locked again for some unknown reason and prevent deployment and I am always forced to restart. {noformat} [] 2007-07-19 22:40:46,239 DEBUG NodeLock.lock(74) | Cannot lock node '/prefix-repo-dev-release/com/company/pom-root'.. Cause: javax.jcr.lock.LockException: Node already locked: /prefix-repo-dev-release/com/company/pom-root at org.apache.jackrabbit.core.lock.LockManagerImpl.internalLock(LockManagerImpl.java:274) at org.apache.jackrabbit.core.lock.XALockManager.lock(XALockManager.java:73) at org.apache.jackrabbit.core.NodeImpl.lock(NodeImpl.java:4060) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:58) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:39) at org.artifactory.jcr.JcrHelper.createFolder(JcrHelper.java:430) at org.artifactory.jcr.JcrHelper.getOrCreateFolderNode(JcrHelper.java:456) at org.artifactory.jcr.JcrHelper.createPath(JcrHelper.java:198) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:341) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:333) at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:184) at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:331) at org.artifactory.engine.UploadEngine.process(UploadEngine.java:158) at org.artifactory.webapp.servlet.RepoFilter.handleUploadRequest(RepoFilter.java:106) at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:75) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178) at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:72) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:841) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:639) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) [] 2007-07-19 22:40:46,240 ERROR RepoFilter.handleUploadRequest(108) | Upload request failed java.lang.RuntimeException: Failed to save resource '{prefix-repo-dev-release:com/company/pom-root/8/pom-root-8.pom}'. at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:378) at org.artifactory.engine.UploadEngine.process(UploadEngine.java:158) at org.artifactory.webapp.servlet.RepoFilter.handleUploadRequest(RepoFilter.java:106) at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:75) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178) at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:72) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:841) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:639) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) Caused by: java.lang.RuntimeException: Failed to execute JcrCallback. at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:188) at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:331) ... 25 more Caused by: java.lang.RuntimeException: Failed to acquire node lock on '/prefix-repo-dev-release/com/company/pom-root' after 15 retries. at org.artifactory.jcr.NodeLock.lock(NodeLock.java:88) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:39) at org.artifactory.jcr.JcrHelper.createFolder(JcrHelper.java:430) at org.artifactory.jcr.JcrHelper.getOrCreateFolderNode(JcrHelper.java:456) at org.artifactory.jcr.JcrHelper.createPath(JcrHelper.java:198) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:341) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:333) at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:184) ... 26 more {noformat} Any ideas?

    JFrog JIRA | 9 years ago | Peter Lynch
    javax.jcr.lock.LockException: Node already locked: /prefix-repo-dev-release/com/company/pom-root
  2. 0

    I recently upgraded from revision 642 1.2.1-SNAPSHOT to 1.2.1 final release. Things went pretty smooth for a while - however after running the server for a while ( several days, not much traffic) and then trying to deploy a pom artifact, I noticed Internal Error 500 being returned. Looking at the logs I see that the node is already locked. I have no idea what is causing the locks but it keeps happening. I will mention that after restarting the server the same pom can be deployed without problem as it seems that locks are removed upon restart. However it always happens that eventually nodes will become locked again for some unknown reason and prevent deployment and I am always forced to restart. {noformat} [] 2007-07-19 22:40:46,239 DEBUG NodeLock.lock(74) | Cannot lock node '/prefix-repo-dev-release/com/company/pom-root'.. Cause: javax.jcr.lock.LockException: Node already locked: /prefix-repo-dev-release/com/company/pom-root at org.apache.jackrabbit.core.lock.LockManagerImpl.internalLock(LockManagerImpl.java:274) at org.apache.jackrabbit.core.lock.XALockManager.lock(XALockManager.java:73) at org.apache.jackrabbit.core.NodeImpl.lock(NodeImpl.java:4060) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:58) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:39) at org.artifactory.jcr.JcrHelper.createFolder(JcrHelper.java:430) at org.artifactory.jcr.JcrHelper.getOrCreateFolderNode(JcrHelper.java:456) at org.artifactory.jcr.JcrHelper.createPath(JcrHelper.java:198) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:341) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:333) at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:184) at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:331) at org.artifactory.engine.UploadEngine.process(UploadEngine.java:158) at org.artifactory.webapp.servlet.RepoFilter.handleUploadRequest(RepoFilter.java:106) at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:75) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178) at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:72) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:841) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:639) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) [] 2007-07-19 22:40:46,240 ERROR RepoFilter.handleUploadRequest(108) | Upload request failed java.lang.RuntimeException: Failed to save resource '{prefix-repo-dev-release:com/company/pom-root/8/pom-root-8.pom}'. at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:378) at org.artifactory.engine.UploadEngine.process(UploadEngine.java:158) at org.artifactory.webapp.servlet.RepoFilter.handleUploadRequest(RepoFilter.java:106) at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:75) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178) at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:72) at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139) at org.mortbay.jetty.Server.handle(Server.java:295) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:841) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:639) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361) at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442) Caused by: java.lang.RuntimeException: Failed to execute JcrCallback. at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:188) at org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:331) ... 25 more Caused by: java.lang.RuntimeException: Failed to acquire node lock on '/prefix-repo-dev-release/com/company/pom-root' after 15 retries. at org.artifactory.jcr.NodeLock.lock(NodeLock.java:88) at org.artifactory.jcr.NodeLock.lock(NodeLock.java:39) at org.artifactory.jcr.JcrHelper.createFolder(JcrHelper.java:430) at org.artifactory.jcr.JcrHelper.getOrCreateFolderNode(JcrHelper.java:456) at org.artifactory.jcr.JcrHelper.createPath(JcrHelper.java:198) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:341) at org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:333) at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:184) ... 26 more {noformat} Any ideas?

    JFrog JIRA | 9 years ago | Peter Lynch
    javax.jcr.lock.LockException: Node already locked: /prefix-repo-dev-release/com/company/pom-root
  3. 0

    how to remove node lock when lock belongs to different session

    Stack Overflow | 2 years ago | Amit Sinha
    javax.jcr.lock.LockException: Node not locked by this session.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Jackrabbit - Users - using mix:lockable throwing Unresolved conflicts in oak 1.2.2

    nabble.com | 1 year ago
    javax.jcr.lock.LockException: Node /ka:system/ka:counter is not locked

    Root Cause Analysis

    1. javax.jcr.lock.LockException

      Node already locked: /prefix-repo-dev-release/com/company/pom-root

      at org.apache.jackrabbit.core.lock.LockManagerImpl.internalLock()
    2. Jackrabbit Core
      NodeImpl.lock
      1. org.apache.jackrabbit.core.lock.LockManagerImpl.internalLock(LockManagerImpl.java:274)
      2. org.apache.jackrabbit.core.lock.XALockManager.lock(XALockManager.java:73)
      3. org.apache.jackrabbit.core.NodeImpl.lock(NodeImpl.java:4060)
      3 frames
    3. org.artifactory.jcr
      JcrHelper.createPath
      1. org.artifactory.jcr.NodeLock.lock(NodeLock.java:58)
      2. org.artifactory.jcr.NodeLock.lock(NodeLock.java:39)
      3. org.artifactory.jcr.JcrHelper.createFolder(JcrHelper.java:430)
      4. org.artifactory.jcr.JcrHelper.getOrCreateFolderNode(JcrHelper.java:456)
      5. org.artifactory.jcr.JcrHelper.createPath(JcrHelper.java:198)
      5 frames
    4. org.artifactory.repo
      JcrRepo$9.doInJcr
      1. org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:341)
      2. org.artifactory.repo.JcrRepo$9.doInJcr(JcrRepo.java:333)
      2 frames
    5. org.artifactory.jcr
      JcrHelper.doInSession
      1. org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:184)
      1 frame
    6. org.artifactory.repo
      JcrRepo.saveResource
      1. org.artifactory.repo.JcrRepo.saveResource(JcrRepo.java:331)
      1 frame
    7. org.artifactory.engine
      UploadEngine.process
      1. org.artifactory.engine.UploadEngine.process(UploadEngine.java:158)
      1 frame
    8. org.artifactory.webapp
      ArtifactoryFilter.doFilter
      1. org.artifactory.webapp.servlet.RepoFilter.handleUploadRequest(RepoFilter.java:106)
      2. org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:75)
      3. org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89)
      3 frames
    9. Jetty Server
      ServletHandler$CachedChain.doFilter
      1. org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089)
      1 frame
    10. Acegi Security Core
      BasicProcessingFilter.doFilter
      1. org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178)
      1 frame
    11. org.artifactory.webapp
      ArtifactoryFilter.doFilter
      1. org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:72)
      2. org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:89)
      2 frames
    12. Jetty Server
      SelectChannelEndPoint.run
      1. org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089)
      2. org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365)
      3. org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
      4. org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
      5. org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)
      6. org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
      7. org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211)
      8. org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
      9. org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
      10. org.mortbay.jetty.Server.handle(Server.java:295)
      11. org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:503)
      12. org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:841)
      13. org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:639)
      14. org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:210)
      15. org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:379)
      16. org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:361)
      16 frames
    13. Jetty Util
      BoundedThreadPool$PoolThread.run
      1. org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)[]
      1 frame