Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-19597

Stopping build does not remove file locks

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Medium
    • None
    • 5.13.2
    • Windows

    Description

      Summary

      When a build is Stopped during Source Code Checkout, file locks are not removed, requiring a Bamboo restart to rerun builds

      Environment

      • Windows

      Steps to Reproduce

      1. Start a build
      2. Stop it during checkout
      3. Try to rerun the build

      Expected Results

      Build runs successfully

      Actual Results

      The below exception is thrown in the atlassian-bamboo.log file:

      2017-09-22 09:47:39,216 WARN [16-BAM::Default Agent::Agent:pool-31-thread-1] [VcsCheckoutTask] PROJ-PLAN-JOB1-123: Unable to clean source directory '<build-working-directory>' <build-working-directory>\src
      java.nio.file.DirectoryNotEmptyException: <build-working-directory>\src
      	at sun.nio.fs.WindowsFileSystemProvider.implDelete(Unknown Source)
      	at sun.nio.fs.AbstractFileSystemProvider.delete(Unknown Source)
      	at java.nio.file.Files.delete(Unknown Source)
      	at com.atlassian.bamboo.utils.BambooFiles.delete(BambooFiles.java:43)
      ...
      Caused by: com.atlassian.bamboo.repository.RepositoryException: Unable to clean source directory '<build-working-directory>\' <build-working-directory>\src
      ...
      Caused by: java.nio.file.DirectoryNotEmptyException: <build-working-directory>\src
      ...
      

      Workaround

      Restart Bamboo to clear file locks

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ezeidan Elias Zeidan (they/them)
              Votes:
              13 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated: