Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1057079 - Intermittent exceptions when creating a new business process
Summary: Intermittent exceptions when creating a new business process
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: jBPM Designer
Version: unspecified
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ER1
: 6.0.2
Assignee: Tihomir Surdilovic
QA Contact: Zuzana Krejčová
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-01-23 12:41 UTC by Zuzana Krejčová
Modified: 2016-08-01 01:08 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-06 19:49:54 UTC
Type: Bug


Attachments (Terms of Use)
part of the server log covering the process creation, showing the whole stacktrace (deleted)
2014-01-23 12:41 UTC, Zuzana Krejčová
no flags Details

Description Zuzana Krejčová 2014-01-23 12:41:19 UTC
Created attachment 854367 [details]
part of the server log covering the process creation, showing the whole stacktrace

Description of problem:
When creating a new business process, using the Designer, sometimes you get these in the server log:
ERROR [stderr] org.uberfire.java.nio.IOException: java.lang.RuntimeException: org.eclipse.jgit.api.errors.ConcurrentRefUpdateException: Could not lock HEAD. RefUpdate return code was: LOCK_FAILURE
ERROR [stderr] 	at org.uberfire.java.nio.fs.jgit.JGitFileSystemProvider.createDirectory(JGitFileSystemProvider.java:892)
ERROR [stderr] 	at org.jbpm.designer.repository.vfs.VFSRepository.createIfNotExists(VFSRepository.java:523)
ERROR [stderr] 	at org.jbpm.designer.repository.vfs.VFSRepository.createAsset(VFSRepository.java:341)
...

Followed by:
ERROR [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit]  java.lang.RuntimeException: org.eclipse.jgit.api.errors.ConcurrentRefUpdateException: Could not lock HEAD. RefUpdate return code was: LOCK_FAILURE
ERROR [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit] java.lang.RuntimeException: java.lang.RuntimeException: java.io.IOException: Creating directory /home/zkrejcov/.niogit/repository1.git/objects/d7 failed
ERROR [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit]  java.io.IOException: Creating directory /home/zkrejcov/.niogit/repository1.git/objects/0a failed
and similar. The process is created anyway.


Version-Release number of selected component (if applicable):
BPMS 6.0  CR1

Comment 1 Alexandre Porcelli 2014-02-28 12:29:30 UTC
I've been trying to reproduce but I couldn't... can you provide more info how to? Maybe more info about OS, browser...

Comment 2 Zuzana Krejčová 2014-02-28 13:33:53 UTC
(In reply to Alexandre Porcelli from comment #1)
> I've been trying to reproduce but I couldn't... can you provide more info
> how to? Maybe more info about OS, browser...

These messages appear with the addition of various *.fw, *.png, *.json and such files to 'global' folder (which is a by product of creating a new process):

14:15:35,708 INFO  [org.guvnor.common.services.builder.ResourceChangeIncrementalBuilder] (org.uberfire.backend.server.IOWatchServiceNonDotImpl(WatchService{FileSystem=git://localhost:9418/repository1
ssh://localhost:8001/repository1})) Incremental build request received for: default://master@repository1/project1/global/backbonejsinclude.fw (added).
14:15:35,740 ERROR [org.jbpm.designer.web.preprocessing.impl.JbpmPreprocessingUnit] (http-/127.0.0.1:8080-5) org.eclipse.jgit.api.errors.ConcurrentRefUpdateException: Could not lock HEAD. RefUpdate return code was: LOCK_FAILURE

Description of ConcurrentRefUpdateException:
"Exception thrown when a command wants to update a ref but failed because another process is accessing (or even also updating) the ref."

There is a lot of files being created at pretty much the same time, or so close to each other (time-wise) that it might seem like concurrent access.

It is possible that you won't see this if you already have a process in your project, created via the business-central - because in such a case, you will probably already have all those files in the 'global' folder.

Comment 3 Alexandre Porcelli 2014-02-28 18:42:02 UTC
Asked Tiho to add batch updates in order to avoid multiple commits (and avoid git corruptions).

Comment 4 Tihomir Surdilovic 2014-03-03 15:13:57 UTC
added batch updates for preprocessing steps. commits in master and 6.0.x designer branches

Comment 5 Zuzana Krejčová 2014-05-22 14:06:18 UTC
Verified with ER2.


Note You need to log in before you can comment on or make changes to this bug.