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

Quiet all Perforce output when quiet:true.

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: p4-plugin
    • Labels:
    • Environment:
      p4-plugin 1.10.4
      Jenkins 1.176.1
    • Similar Issues:

      Description

      When 'quiet' is set to true 'p4 reconcile' and preferably other commands also need to have the file list quashed.

      For example hide the 'refreshed' below :

      P4 Task: cleaning workspace to match have list.
      ... p4 reconcile -f -w /var/lib/jenkins/workspace/Pipeline_Quiet_True/... -p4 reconcile -f -w /var/lib/jenkins/workspace/Pipeline_Quiet_True/...
      
      //depot/Project1/sub1/f564#1 - /var/lib/jenkins/workspace/Pipeline_Quiet_True/sub1/f564 refreshed
      duration: (2ms)
      
      P4 Task: syncing files at change: 565
      ... p4 sync -q /var/lib/jenkins/workspace/Pipeline_Quiet_True/...@565 -p4 sync -q /var/lib/jenkins/workspace/Pipeline_Quiet_True/...@565
      duration: (2ms)
      

      Code:

      pipeline {
        agent { label 'master' }
        stages {
          stage("Repro") {
            steps {
      	p4sync charset: 'none', credential: 'JenkinsMaster', populate: autoClean(delete: true, modtime: false, parallel: [enable: false, minbytes: '1024', minfiles: '1', threads: '4'], pin: '', quiet: true, replace: true, tidy: false), source: depotSource('//depot/Project1/...')
            }
          }
        }
      

      When there are a few files to be reconciled it's not a problem but when there are 1000's this overloads the logs making them difficult to work with and diagnose problems.

       

        Attachments

          Activity

          Hide
          abinitio_user Heather Mardis added a comment -

          In my 100's of job configurations and with the size of my source code, the '-q' on p4 reconcile puts 43,156 lines in EVERY jenkins log file.

          Show
          abinitio_user Heather Mardis added a comment - In my 100's of job configurations and with the size of my source code, the '-q' on p4 reconcile puts 43,156 lines in EVERY jenkins log file.
          Hide
          p4karl Karl Wirth added a comment -

          In addition the output in 'p4 changes -m1' can trip up log analyzers which fail builds when error messages are detected. Would be good if this was also hidden from the log. For example this is from a standard polled freestyle job:

          Started by an SCM change
          Running as SYSTEM
          [EnvInject] - Loading node environment variables.
          Building on master in workspace /var/lib/jenkins/workspace/00640681_Polling_Exclude_User
          Executor number at runtime: 0
          (p4):cmd:... p4 login -s
          p4 login -sUser super ticket expires in 5 hours 15 minutes.(p4):stop:3
          (p4):cmd:... p4 client -o jenkins-master-00640681_Polling_Exclude_User-3
          p4 client -o jenkins-master-00640681_Polling_Exclude_User-3(p4):stop:4
          (p4):cmd:... p4 info
          p4 info(p4):stop:5
          (p4):cmd:... p4 info
          p4 info(p4):stop:6
          (p4):cmd:... p4 client -o jenkins-master-00640681_Polling_Exclude_User-3
          p4 client -o jenkins-master-00640681_Polling_Exclude_User-3(p4):stop:7
          (p4):cmd:... p4 counter change
          p4 counter change(p4):stop:8
          (p4):cmd:... p4 changes -m1 -ssubmitted //jenkins-master-00640681_Polling_Exclude_User-3/...
          p4 changes -m1 -ssubmitted //jenkins-master-00640681_Polling_Exclude_User-3/...Change 89712 on 2020/04/15 by super@test_ws 'Fix Error Message: FATAL ERROR at line 1234'
          

          The above 'FATAL ERROR' in the changelist description would fool the paser.

           

           

          Show
          p4karl Karl Wirth added a comment - In addition the output in 'p4 changes -m1' can trip up log analyzers which fail builds when error messages are detected. Would be good if this was also hidden from the log. For example this is from a standard polled freestyle job: Started by an SCM change Running as SYSTEM [EnvInject] - Loading node environment variables. Building on master in workspace / var /lib/jenkins/workspace/00640681_Polling_Exclude_User Executor number at runtime: 0 (p4):cmd:... p4 login -s p4 login -sUser super ticket expires in 5 hours 15 minutes.(p4):stop:3 (p4):cmd:... p4 client -o jenkins-master-00640681_Polling_Exclude_User-3 p4 client -o jenkins-master-00640681_Polling_Exclude_User-3(p4):stop:4 (p4):cmd:... p4 info p4 info(p4):stop:5 (p4):cmd:... p4 info p4 info(p4):stop:6 (p4):cmd:... p4 client -o jenkins-master-00640681_Polling_Exclude_User-3 p4 client -o jenkins-master-00640681_Polling_Exclude_User-3(p4):stop:7 (p4):cmd:... p4 counter change p4 counter change(p4):stop:8 (p4):cmd:... p4 changes -m1 -ssubmitted //jenkins-master-00640681_Polling_Exclude_User-3/... p4 changes -m1 -ssubmitted //jenkins-master-00640681_Polling_Exclude_User-3/...Change 89712 on 2020/04/15 by super @test_ws 'Fix Error Message: FATAL ERROR at line 1234' The above 'FATAL ERROR' in the changelist description would fool the paser.    
          Hide
          barnish Andrew Barnish added a comment -

          Please can something be done about this soon as it is causing a lot of issues with the log parser falsely detecting error conditions?

          Show
          barnish Andrew Barnish added a comment - Please can something be done about this soon as it is causing a lot of issues with the log parser falsely detecting error conditions?
          Hide
          p4karl Karl Wirth added a comment -

          FYI Paul Allen - Please review this in your current sprint planning cycle.

          Show
          p4karl Karl Wirth added a comment - FYI Paul Allen - Please review this in your current sprint planning cycle.
          Hide
          barnish Andrew Barnish added a comment -

          The main issue for us is that the changelist descriptions can contain random strings that trigger the log parser.
          Things like "Test Failed" or "ERROR".

          So we would like an option to turn off Perforce changelist descriptions at least.
          But making all information output quiet would would suffice as this issue is requesting.

          Show
          barnish Andrew Barnish added a comment - The main issue for us is that the changelist descriptions can contain random strings that trigger the log parser. Things like "Test Failed" or "ERROR". So we would like an option to turn off Perforce changelist descriptions at least. But making all information output quiet would would suffice as this issue is requesting.
          Hide
          p4paul Paul Allen added a comment -

          Release in 1.10.13

          Show
          p4paul Paul Allen added a comment - Release in 1.10.13

            People

            Assignee:
            p4paul Paul Allen
            Reporter:
            p4karl Karl Wirth
            Votes:
            3 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: