Project: bamboo
Issue BAM-7676: Git Repository server cache should be thread-safe (during fetches)
h3. System Error Details Build test - testmasterclean : Unable to detect changes (com.atlassian.bamboo.repository.RepositoryException : Cannot fetch 'git://github.com/cixot/test.git', branch 'master' to source directory '/home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository'. Cannot move pack to /home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository/.git/objects/pack/pack-9debbf5763a2286524c616934e72bf0cb8b71dba.pack) Occurred: 05 Jan 2011, 5:12:03 PM com.atlassian.bamboo.repository.RepositoryException: Cannot fetch 'git://github.com/cixot/test.git', branch 'master' to source directory '/home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository'. Cannot move pack to /home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository/.git/objects/pack/pack-9debbf5763a2286524c616934e72bf0cb8b71dba.pack {code} com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:193) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:157) com.atlassian.bamboo.plugins.git.GitRepository.collectChangesSinceLastBuild(GitRepository.java:154) com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuild(DefaultChangeDetectionManager.java:92) com.atlassian.bamboo.v2.trigger.ChangeDetectionListenerAction.process(ChangeDetectionListenerAction.java:75) com.atlassian.bamboo.chains.ChainExecutionManagerImpl.createChainState(ChainExecutionManagerImpl.java:164) com.atlassian.bamboo.chains.ChainExecutionManagerImpl.start(ChainExecutionManagerImpl.java:107) sun.reflect.GeneratedMethodAccessor178.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:616) org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198) $Proxy41.start(Unknown Source) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.startWithLockTaken(PlanExecutionManagerImpl.java:174) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.access$100(PlanExecutionManagerImpl.java:39) com.atlassian.bamboo.plan.PlanExecutionManagerImpl$2.call(PlanExecutionManagerImpl.java:155) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.doWithProcessLock(PlanExecutionManagerImpl.java:306) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:148) com.atlassian.bamboo.v2.trigger.ChangeDetectionListener.handleEvent(ChangeDetectionListener.java:50) com.atlassian.bamboo.event.EventListenerRunnable.run(EventListenerRunnable.java:22) java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:50) java.lang.Thread.run(Thread.java:636) Caused by: org.eclipse.jgit.errors.TransportException: Cannot move pack to /home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository/.git/objects/pack/pack-9debbf5763a2286524c616934e72bf0cb8b71dba.pack org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:292) org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:230) org.eclipse.jgit.transport.FetchProcess.fetchObjects(FetchProcess.java:217) org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:152) org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:114) org.eclipse.jgit.transport.Transport.fetch(Transport.java:904) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:188)	... 23 more Caused by: java.io.IOException: Cannot move pack to /home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository/.git/objects/pack/pack-9debbf5763a2286524c616934e72bf0cb8b71dba.pack org.eclipse.jgit.transport.IndexPack.renameAndOpenPack(IndexPack.java:1163) org.eclipse.jgit.transport.BasePackFetchConnection.receivePack(BasePackFetchConnection.java:674) org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:285)	... 29 more {code} ---- h3. System Error Details Build test - testmaster : Unable to detect changes (com.atlassian.bamboo.repository.RepositoryException : Cannot fetch 'git://github.com/cixot/test.git', branch 'master' to source directory '/home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository'. Unknown repository format "null"; expected "0".) Occurred: 05 Jan 2011, 5:12:03 PM com.atlassian.bamboo.repository.RepositoryException: Cannot fetch 'git://github.com/cixot/test.git', branch 'master' to source directory '/home/pstefaniak/bamboo/atlassian-bamboo-2.7.3-standalone/home/xml-data/build-dir/_git-repositories-cache/0x-7300b201-1/repository'. Unknown repository format "null"; expected "0". {code} com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:193) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:157) com.atlassian.bamboo.plugins.git.GitRepository.collectChangesSinceLastBuild(GitRepository.java:154) com.atlassian.bamboo.v2.trigger.DefaultChangeDetectionManager.collectChangesSinceLastBuild(DefaultChangeDetectionManager.java:92) com.atlassian.bamboo.v2.trigger.ChangeDetectionListenerAction.process(ChangeDetectionListenerAction.java:75) com.atlassian.bamboo.chains.ChainExecutionManagerImpl.createChainState(ChainExecutionManagerImpl.java:164) com.atlassian.bamboo.chains.ChainExecutionManagerImpl.start(ChainExecutionManagerImpl.java:107) sun.reflect.GeneratedMethodAccessor178.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:616) org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304) org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:198) $Proxy41.start(Unknown Source) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.startWithLockTaken(PlanExecutionManagerImpl.java:174) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.access$100(PlanExecutionManagerImpl.java:39) com.atlassian.bamboo.plan.PlanExecutionManagerImpl$2.call(PlanExecutionManagerImpl.java:155) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.doWithProcessLock(PlanExecutionManagerImpl.java:306) com.atlassian.bamboo.plan.PlanExecutionManagerImpl.start(PlanExecutionManagerImpl.java:148) com.atlassian.bamboo.v2.trigger.ChangeDetectionListener.handleEvent(ChangeDetectionListener.java:50) com.atlassian.bamboo.event.EventListenerRunnable.run(EventListenerRunnable.java:22) java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:50) java.lang.Thread.run(Thread.java:636) Caused by: java.io.IOException: Unknown repository format "null"; expected "0". org.eclipse.jgit.storage.file.FileRepository.(FileRepository.java:180) org.eclipse.jgit.storage.file.FileRepository.(FileRepository.java:126) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:169)	... 23 more {code} h3. System Error Details Build gp - linuskernelhttp3 - Default Job 4 : Error occurred while executing the build for GP-LINUSKERNELHTTP3-JOB1-4 (com.atlassian.bamboo.repository.RepositoryException : null Could not delete file /home/hgrepo/bamboo-agent-home/xml-data/build-dir/GP-LINUSKERNELHTTP3-JOB1/.git/objects/incoming_4443714216792466821.idx) Occurred: 05 Jan 2011, 5:29:19 PM Agent: lucyfer (2) com.atlassian.bamboo.repository.RepositoryException: null Could not delete file /home/hgrepo/bamboo-agent-home/xml-data/build-dir/GP-LINUSKERNELHTTP3-JOB1/.git/objects/incoming_4443714216792466821.idx {code} com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:193) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetchAndCheckout(GitOperationHelper.java:151) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetchAndCheckout(GitOperationHelper.java:142) com.atlassian.bamboo.plugins.git.GitRepository.retrieveSourceCode(GitRepository.java:203) com.atlassian.bamboo.v2.build.task.CheckoutUpdateForBuild.doCall(CheckoutUpdateForBuild.java:136) com.atlassian.bamboo.v2.build.task.CheckoutUpdateForBuild.call(CheckoutUpdateForBuild.java:41) com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:189) com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:90) com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:102) com.atlassian.bamboo.build.pipeline.concurrent.NamedThreadFactory$2.run(NamedThreadFactory.java:50) java.lang.Thread.run(Thread.java:636) Caused by: org.eclipse.jgit.errors.TransportException: Could not delete file /home/hgrepo/bamboo-agent-home/xml-data/build-dir/GP-LINUSKERNELHTTP3-JOB1/.git/objects/incoming_4443714216792466821.idx org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:292) org.eclipse.jgit.transport.TransportHttp$SmartHttpFetchConnection.doFetch(TransportHttp.java:613) org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:230) org.eclipse.jgit.transport.FetchProcess.fetchObjects(FetchProcess.java:217) org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:152) org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:114) org.eclipse.jgit.transport.Transport.fetch(Transport.java:904) com.atlassian.bamboo.plugins.git.GitOperationHelper.fetch(GitOperationHelper.java:188)	... 10 more Caused by: java.io.IOException: Could not delete file /home/hgrepo/bamboo-agent-home/xml-data/build-dir/GP-LINUSKERNELHTTP3-JOB1/.git/objects/incoming_4443714216792466821.idx org.eclipse.jgit.util.FileUtils.delete(FileUtils.java:133) org.eclipse.jgit.util.FileUtils.delete(FileUtils.java:91) org.eclipse.jgit.transport.IndexPack.index(IndexPack.java:473) org.eclipse.jgit.transport.BasePackFetchConnection.receivePack(BasePackFetchConnection.java:673) org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:285)	... 17 more {code}
Story points: 2