Not adding new files on build

We have TeamCity configured with a VCS connected to a svn, and over the last 2 years things have been working great. Every time we commit a change to the repo, TeamCity builds it perfectly.
But now I notice TeamCity is not adding any new files commited to the repository. If we make changes in existing files, and commit them, they get built. But when we add new files, they don´t get built.

When committing new files (and existing as well) the change in repo triggers a build in TeamCity. And TeamCity is aware of the new files - they are displayed as "added". And the build process finishes and says "Success". But I can´t see the new files anywhere...

Any suggestions to where the problem might be? All help is welcomed.

And I should add, that this is not within my tech comfort-zone. I´m really new to this, and was not involved with the setup of our system.

11 comments
Comment actions Permalink

Hi,

Could you please attach screenshot of your Version Control Settingsm page Checkout Options? Also please attach build log.

0
Comment actions Permalink

Hi Alina

Is this the info you are looking for?

I have altered a small portion of the build-log, just masking some info (nothing important to the log).

I just committed a small change to one of the files in the repo - the file is nowhere to be found after the build. (Notice - I did not commit a "new file/add file" in this repo-commit).


The build log shows an [ResolveAssemblyReference] warning. This is not new, and we are aware of the issue. This was happening before the reported issue started to occur, so I´m thinking this is not the reason why added files are not added.



Attachment(s):
vcs-checkout_options.gif
Inside_Staging_358_build_log.txt.zip
0
Comment actions Permalink

Hi Kartin,

I'm sorry for the late response. There were lots of fixes done since 8.0.1 version. Could you please upgrade to the latest TeamCity release? Please let us know if you face the problem after the upgrade.

0
Comment actions Permalink

Hi again,

I have just updated to version 8.1.5. The issue is still there - none of the "added" files are built....

0
Comment actions Permalink

Sorry for inconvenience. Could you please attach details of VCS Root settings, teamcity-vcs.logs and teamcity-server.log + details of the change which wasn't detected by TeamCity (fragment of svn log -v command).

0
Comment actions Permalink

I have attached the requested items. Please note, that the log-files have been masked, and I´ve removed some of the older content from them. Please let me know if you need more information.

In your comment you say "+ details of the change which wasn't detected by TeamCity (fragment of svn log -v command).". I must stress that TeamCity detects the change, and it acts on it! The build process starts - but when it´s finished, there are no new files!

This is an example:

  • Locally I add a new view-file. When building locally, everything works fine - I can see the new view-file.
  • I then commit the file to the repo, and the new view-file is added.
  • If I check the repo, I can see the new view-file is there.
  • Once comitted to the repo, this triggers TeamCity´s build agent. I can see that TeamCity now know there is a new file in the repo - and it starts building.
  • BUT once the build has finished - with a "Success" message, I look for the new view-file on our server, and it can not be found. The file is not on the server!


I have attached a screenshot, showing that TeamCity is aware of files being added to the repo (see file: testControllerAdded_teamcity_is_aware.gif). Yes, I know this shows a controller being added, and not the view-file I used in my example - this is just for demonstration purposes.

Attachment(s):
testControllerAdded_teamcity_is_aware.gif
VCS_Root_settings.gif
SVN_log_fragment.gif
teamcity-vcs.log.zip
teamcity-server.log.zip
0
Comment actions Permalink

Hi,

TeamCity checks out all files on agent (not on server) in the checkout directory buildAgent/work/<VCS settings hash code>. Have you checked this folder?

The checkout directory can be cleaned automatically. There are two cases:

1. Checkout directory was not used for a specified period of time;

2. There not enough free disk space (3 Gb by default) for new builds - https://confluence.jetbrains.com/display/TCD8/Free+disk+space. To make sure a checkout directory is never deleted while freeing disk space, you can try to set system.teamcity.build.checkoutDir.expireHours property to "never" value.

0
Comment actions Permalink

I´ve now looked in the checkout directory folder, and I found all the newly added files there!

But they are not on the server...

Any ideas?

0
Comment actions Permalink

It works by design. All sources are checked out on agent because they build on agent machine. "Automatically on server" option means that server will export the sources and pass them to an agent before each build (checkout won't be performed directly from agent). For more details please read this section - https://confluence.jetbrains.com/display/TCD8/VCS+Checkout+Mode.

0
Comment actions Permalink

I´m not sure I fully understand....

The changes in the repo (added files) reach TeamCity (agent), and TeamCity checks them out on agent machine (in the "TeamCity > buildAgent > work > xxxx" folder). So far all new files are accounted for.

Then the agent starts a build process (MSBuild) and this build process "should" build a new solution/site from the agents repo folder, and therefor add the new files. The process finishes with a "Success" message, but the new files are nowhere to be found on the server. This must surely mean that something is not functioning as designed - right?

Is there some kind of seperation between TeamCity and the actual build-runner, that I don´t understand? Should the build-runner not build what ever is in the repo?

I just can´t understand why the new files - which are present in the repo, even all the way to the agent checkout - don´t get built on the server.

0
Comment actions Permalink

When the build is initiated (for example changes detected), TeamCity server select an agent to run this build. Once the build is assigned to a build agent, the build agent has to get the sources to run on. TeamCity checks files from the repository on agent machine to the  <Build agent home>/work/xxxx folder. When the Build Agent has all the required sources, it starts to execute Build steps in <Build agent home>/work/xxxx folder.

While the build steps are being executed, the build agent sends all the log messages, test reports, code coverage results and so on to the TeamCity server on the fly, so you can monitor the build process in real time.

After finishing the build, the build agent sends Build Artifacts to the server (see how to setup which files to store on server). These are the files produced by a build, for example, installers, WAR files, reports, log files, etc, when they become available for download.

0

Please sign in to leave a comment.