Build ID skipping numbers

Hello. I just setup a new server with Teamcity on it. Teamcity is running version 2022.10.2 and is running as a docker container. I am using a MySQL database as a docker container in the same compose stack. The MySQL database have default config except innodb buffer pool size and log file size (according to the documentation) that I put in the local.cnf file.

When I started to use the build server I realized that after rebooting the system it seems that build IDs skip to the closes 100 number. So if the latest build has id 213 then after reboot the first new build gets 301. I have never seen this before on Teamcity and I want to make sure nothing is wrong before we start using the server in our workflow. We use build id as the version for our releases/builds and it seems very weird to skip numbers on restart.

Does anyone know if this is expected behvaiour? Is something wrong or is it a configuration issue?

0
4 comments
Hello Andreas,

I have just checked the logic with the devs; each node will reserve a batch of 100 build IDs which will then be used for newly started builds. If node is restarted before the batch is exhausted, a new batch will be reserved, so the behavior is expected.

Can you please let me know why build number is based on build ID in your case?
0

Okey, thank you! Good to know its a feature, not a bug :)

If we dont plan to add any more nodes, is it possible to disable this feature and just use incremental numbers?

0
Hello Andreas,

Unfortunately, I believe this is the default behavior even if there is just one node set up. Perhaps if you could share more details of your usage scenario, I could suggest an alternative approach?
0

We have previously used the build id as the version for all our artifacts since we needed unique IDs across projects. But its not a real issue that the IDs skip numbers and in our new build environment it does not matter at all since we are merging projects into one build and can use build number as version. If we could disable it we would, but its not important at all :)

Thanks for the help.

0

Please sign in to leave a comment.