File tree Expand file tree Collapse file tree 4 files changed +8
-0
lines changed Expand file tree Collapse file tree 4 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -121,6 +121,9 @@ def metrics_to_hash(report)
121121    end 
122122    # fix for Puppet non-resource errors (i.e. failed catalog fetches before falling back to cache) 
123123    report_status [ "failed" ]  += report . logs . find_all  { |l | l . source  =~ /Puppet$/  && l . level . to_s  == 'err'  } . count 
124+     unless  SETTINGS [ :report_ignore_facter_errors ] 
125+       report_status [ "failed" ]  += report . logs . count  { |l | l . source  == 'Facter'  && l . level . to_s  == 'err'  } 
126+     end 
124127
125128    return  report_status 
126129  end 
Original file line number Diff line number Diff line change 3636#    The timeout to use on HTTP calls in the report processor
3737#  @param report_retry_limit
3838#    The number of times to retry HTTP calls in the report processor
39+ #  @param report_ignore_facter_errors
40+ #    Whether to exclude facter errors from report metrics
3941#  @param puppet_basedir
4042#    The directory used to install the report processor to
4143#  @param use_client_tls_certs
5456  Boolean $reports = true ,
5557  Integer[0] $reports_timeout = 60,
5658  Integer[0] $report_retry_limit = 1,
59+   Boolean $report_ignore_facter_errors = false ,
5760  Variant[Enum[' ' 
5861  Variant[Enum[' ' 
5962  Variant[Enum[' ' 
Original file line number Diff line number Diff line change 129129            ':timeout: 60' , 
130130            ':report_timeout: 60' , 
131131            ':report_retry_limit: 1' , 
132+             ':report_ignore_facter_errors: false' , 
132133            ':threads: null' , 
133134          ] ) 
134135        end 
Original file line number Diff line number Diff line change 1212:timeout: <%=  @enc_timeout %> 
1313:report_timeout: <%=  @reports_timeout %> 
1414:report_retry_limit: <%=  @report_retry_limit %> 
15+ :report_ignore_facter_errors: "<%=  @report_ignore_facter_errors %> 
1516:threads: null
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments