Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-12908

TFS errors during get operation do not fail the build

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major Major
    • tfs-plugin
    • None
    • Windows XP

      We had a build that got several TFS errors when getting the full set of latest code (due to moving to a new Jenkins machine). However, these errors did not cause the build to fail. This is troubling, as the files in question were not downloaded (or in some cases were left writable, meaning that subsequent builds failed). It seems like the plugin should fail the build anytime an error occurs when getting code.

      Here are the errors we got. I'm sure there are other possible errors one could get, too.

      ---- Summary: 0 conflicts, 0 warnings, 6 errors ----
      F:\Hudson\jobs\checkpoint\workspace\CPWar\src\com\tta\checkpoint\servlet\CPHelpService.java: The server returned content type text/html, which is not supported.
      F:\Hudson\jobs\checkpoint\workspace\CPWar\src\com\tta\checkpoint\servlet\CPToolItemServlet.java: TF246017: Team Foundation Server could not connect to the database. Verify that the server that is hosting the database is operational, and that network problems are not blocking communication with the server.
      F:\Hudson\jobs\checkpoint\workspace\CPWar\src\com\tta\checkpoint\uiData\CPCodificationItem.java: TF246017: Team Foundation Server could not connect to the database. Verify that the server that is hosting the database is operational, and that network problems are not blocking communication with the server.
      F:\Hudson\jobs\checkpoint\workspace\CPWar\src\com\tta\checkpoint\utils\CPQueueWriter.java: TF246017: Team Foundation Server could not connect to the database. Verify that the server that is hosting the database is operational, and that network problems are not blocking communication with the server.
      F:\Hudson\jobs\checkpoint\workspace\CPWar\web\basic\secCompForm.jsp: TF246017: Team Foundation Server could not connect to the database. Verify that the server that is hosting the database is operational, and that network problems are not blocking communication with the server.
      F:\Hudson\jobs\checkpoint\workspace\CPWar\web\basic\css\srchAdvQry.css: The server returned content type text/html, which is not supported.

          [JENKINS-12908] TFS errors during get operation do not fail the build

          redsolo added a comment -

          What kind of problems did it miss? If I have the incorrect server/auth then it will fail the build. But i guess there could be a problem with the TFS workspace if it has been moved to a new server...

          redsolo added a comment - What kind of problems did it miss? If I have the incorrect server/auth then it will fail the build. But i guess there could be a problem with the TFS workspace if it has been moved to a new server...

          jeffolson added a comment -

          Hi Erik,

          The specific errors are in the initial description. In this case they were all either "TF246017: Team Foundation Server could not connect to the database" errors, or "The server returned content type text/html, which is not supported." errors.

          Thanks,
          Jeff

          jeffolson added a comment - Hi Erik, The specific errors are in the initial description. In this case they were all either "TF246017: Team Foundation Server could not connect to the database" errors, or "The server returned content type text/html, which is not supported." errors. Thanks, Jeff

          redsolo added a comment -

          The code behind the execution of the TFS command line will check if the tf tool returns with 1 or 0, and those are marked as success. My guess is that the tf command line tool returned either 1 or 0 regardless of the errors. That makes it somewhat difficult for the jenkins plugin to know if there was a problem or not. If the authentication fails, then tf returns with the code 100 and thus the plugin fails the build.

          I reccon I could do some parsing of the console output that the TFS tool generates and fail the build if it finds anything resembling such a problem. But that would not be possible for the history command, because if someone checks in a comment resembling the text the plugin will look for then the plugin would fail the build for no good reason.

          Does this happen a lot for you?

          redsolo added a comment - The code behind the execution of the TFS command line will check if the tf tool returns with 1 or 0, and those are marked as success. My guess is that the tf command line tool returned either 1 or 0 regardless of the errors. That makes it somewhat difficult for the jenkins plugin to know if there was a problem or not. If the authentication fails, then tf returns with the code 100 and thus the plugin fails the build. I reccon I could do some parsing of the console output that the TFS tool generates and fail the build if it finds anything resembling such a problem. But that would not be possible for the history command, because if someone checks in a comment resembling the text the plugin will look for then the plugin would fail the build for no good reason. Does this happen a lot for you?

          jeffolson added a comment -

          Thanks, Erik. No, this is very infrequent, thankfully. It sounds like this probably can't be fixed, then, so you can close this issue.

          Thanks for investigating it!
          Jeff

          jeffolson added a comment - Thanks, Erik. No, this is very infrequent, thankfully. It sounds like this probably can't be fixed, then, so you can close this issue. Thanks for investigating it! Jeff

          evernat added a comment -

          And so resolving as Won't fix as suggested by comments.

          evernat added a comment - And so resolving as Won't fix as suggested by comments.

            redsolo redsolo
            jeffolson jeffolson
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: