Teamcity + Postgress + Stash. Floating build error

Hi everyone! I am duplicate my issue for bug tracker - https://youtrack.jetbrains.com/issue/TW-43560

Teamcity version: 9.1.4 (build 37293)
OS: Debian 8.2
DataBase: Postgress 9.4 9.4.4-1.pgdg60+1
Connection Driver: postgresql-9.4-1206-jdbc41

Some times autobuilds crushed with error below.


Error collecting changes for VCS repository '"protools-gradle-plugin" {instance id=37, parent internal id=24, parent id=AndroidProjects_ProToolsGradlePlugin_ProtoolsGradlePluginMain, description: "ssh://git@stash.mydomain.com:7999/ma/protools-gradle-plugin.git#refs/heads/master"}'
jetbrains.buildServer.serverSide.db.UnexpectedDBException: Error executing batch: Batch entry 0 insert into vcs_changes_graph (child_modification_id, child_revision, parent_num, parent_modification_id, parent_revision) values (2813, 'de1b23c82e80b1d1c1018fe565fb0521b3cab44b', 0, 2808, '589a73ad96ddf9000eb12a2c5207c88541c81e88') was aborted. Call getNextException to see the cause.
ERROR: prepared operator "S_2329" doesnt exist
SQL query: insert into vcs_changes_graph (child_modification_id, child_revision, parent_num, parent_modification_id, parent_revision) values (?, ?, ?, ?, ?)
SQL exception: Batch entry 0 insert into vcs_changes_graph (child_modification_id, child_revision, parent_num, parent_modification_id, parent_revision) values (2813, 'de1b23c82e80b1d1c1018fe565fb0521b3cab44b', 0, 2808, '589a73ad96ddf9000eb12a2c5207c88541c81e88') was aborted. Call getNextException to see the cause.


Full strace you can find in attach here - https://youtrack.jetbrains.com/issue/TW-43560
This error is floating.

Can you help me with this issue?

1 comment

Hi Petr,

The error means that the query cannot be run by the database as it cannot find the prepared statement. However TeamCity creates prepared statement right before the query execution so the only common case when this can occur is when the database connection is dropped and the code does not properly recover from the state. This should be quite a rare case, though.

Could you please try to restart both the database and TeamCity server to see if the error will still occur afterwards? If it does not help, then please enable "debug-all" logging preset, reproduce the issue (then reset the logging preset to default) and send teamcity-server.log and teamcty-vcs.log covering the time.


0

Please sign in to leave a comment.