"Recently completed builds with wrong date"

1. Continua version number and edition: 
v1.6.0.292 64 bit

2. Operating system for Continua and agents:
 
Windows 7 64 bits - 1 Agent on same machine as server

3. Database platform:
 
bundled PostgreSQL

4. How much CPU / RAM / Diskspace do you have free on the Continua server, agents, and database:  
eg. 50% free cpu, 90% free RAM (10gig), 10% free hard disk (10 gig)  

5. A detailed description of the issue: 
A couple of days ago there is a build in almost all configurations that failed in the history, its “Finished” column contains the word “Recently” and it appears it finished in the future as you can see in the image:

http://d.pr/i/OU16+

Since this is the most “recent” build every new build goes to the bottom and the “build status” always shows as failed since the “most recent” build failed.

Thanks in advance.

Can I delete a specific build from the history manually?

Hi Luis

Thank you for reporting this. I’ve been looking through the code and I can’t see how this could have happened. We always set the finished date to DateTime.UtcNow. Is it possible that the server date was changed at some point? Is the server time correct now? Are there any errors in the event log around the time the builds should have finished? What times are listed in the build log and timeline?

We don’t currently have a way to clean up a specific build and the cleanup routine won’t clean up a build in the future. The only way you can fix this at the moment  is to update the field in the database. To do this follow these steps:

1. Get the IDs of the builds you need to change: Go to the builds details view - and copy the ID from the URL. This is the number after /view/ e.g. {BuildId} in http://hostname/ProjectName/ci/builds/view/{BuildId}?_=#############
2. Shutdown the Continua CI Server service
3. Ensure that the database is backed up see Backing up the Continua database
4. Work out the build finished time you want it set to in UTC (http://www.worldtimeserver.com/convert_time_in_UTC.aspx)
5. Open C:\Program Files\VSoft Technologies\ContinuaCI\Server\PostgreSQL\bin\pgAdmin3.exe and log in with your connection details. Get these from C:\Program Files\VSoft Technologies\ContinuaCI\Server\Continua.Server.Service.exe.config under configuration->hibernate-configuration->session-factory->property name=“connection.connection_string” 
6. Go to the Tools menu and select Query tool 
7. Ensure the correct database is selected and the execute the query UPDATE builds_build SET Finished = ‘{FinishedTime}’ WHERE id = {BuildId}
e.g.

UPDATE builds_build SET Finished = ‘2015-08-05 01:01:00’ WHERE id = 8182

Repeat for each build id.