After upgrade to EAP build 23373, can't fetch any changes

Since upgrading from 7.0 to the latest 7.1 EAP, we can no longer run any builds.  They fail saying
"Failed to start build"
"Failed to collect changes, error: Revisions are not found for build configuration [...]"

catalina.out includes this ominous-looking snippet many times:

TeamCity 7.1 EAP (build 23373) initialized, OS: Linux, JRE: 1.6.0_22-b22
TeamCity is running in enterprise mode
java.lang.NullPointerException
        at jetbrains.buildServer.vcs.SingleVersionRepositoryStateAdapter.hashCode(SingleVersionRepositoryStateAdapter.java:12)
        at jetbrains.buildServer.buildTriggers.vcs.LoadChangesInterval.hashCode(LoadChangesInterval.java:12)
        at java.util.HashMap.put(HashMap.java:389)
        at jetbrains.buildServer.vcs.impl.VcsChangesLoaderImpl.getLoadChangesIntervals(VcsChangesLoaderImpl.java:14)
        at jetbrains.buildServer.vcs.impl.VcsChangesLoaderImpl.loadChangesNoLocking(VcsChangesLoaderImpl.java:21)
        at jetbrains.buildServer.vcs.impl.VcsChangesLoaderImpl.loadChanges(VcsChangesLoaderImpl.java:31)
        at jetbrains.buildServer.vcs.impl.VcsManagerImpl.loadChanges(VcsManagerImpl.java:507)
        at jetbrains.buildServer.serverSide.impl.auth.SecuredVcsManager.loadChanges(SecuredVcsManager.java:22)
        at jetbrains.buildServer.serverSide.impl.VcsModificationChecker$1.run(VcsModificationChecker.java:25)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:679)


In teamcity-vcs.log, it looks like the server had to do some kind of different initialization after the upgrade:

[2012-05-30 15:05:35,917]   INFO [TeamCityStartup] - gers.vcs.git.MirrorManagerImpl - No mapping file found at /home/admintf/.BuildServer/system/caches/git/map, create a new one
[2012-05-30 15:05:35,917]   INFO [TeamCityStartup] - gers.vcs.git.MirrorManagerImpl - Restore mapping from existing repositories
[2012-05-30 15:05:35,918]   INFO [TeamCityStartup] - gers.vcs.git.MirrorManagerImpl - 5 existing repositories found


but after restarting a few times and trying to run new builds, all this log file outputs is:

[2012-05-30 15:27:22,163]   WARN [rmal executor 9] -      jetbrains.buildServer.VCS - Collecting changes for build configurations [... {id=bt4}] failed
[2012-05-30 15:31:24,465]   WARN [rmal executor 2] -      jetbrains.buildServer.VCS - Collecting changes for build configurations [... {id=bt10}] failed


and the like.

Is this a known problem? Is there a workaround or fix of some kind?
1 comment
Comment actions Permalink

Hello Michael,

unfortunatelly this is a new bug, here is the issue in the tracker: http://youtrack.jetbrains.com/issue/TW-21808.

There is a workaround, but it can be tedious if you have a lot of VCS roots. TeamCity stores current VCS root state inside a file

.BuildServer/system/pluginData/repositoryStates/<parent vcs root id>/<vcs root id>

Each state files has the following format:

<singleVersion>
  <version> ..some version here.. </version>
</singleVersion>

to workaround the problem you should stop TeamCity, add the following line to each state file:

<myTimestamp>2012-06-01 12:00:00.000 UTC</myTimestamp>

so content of the state file becomes:

<singleVersion>
  <version> ..some version here.. </version>
  <myTimestamp>2012-06-01 12:00:00.000 UTC</myTimestamp>
</singleVersion>

and then start TeamCity. Or you can wait for the build with fix.

0

Please sign in to leave a comment.