docstr: Timing function for timing a rule function's duration
  
  Note: this function's timing aspect is a no-op if the RuleStatisticTracker
      is disabled, and instead the rule just runs without timing
  
  Args:
      rule (rule.Rule): The rule being ran
      record (dict): The record being processed
  
  Returns:
      bool: Result of rule processing
docstr_tok: ["Timing","function","for","timing","a","rule","function","'s","duration","Note",":","this","function","'s","timing","aspect","is","a","no-op","if","the","RuleStatisticTracker","is","disabled",",","and","instead","the","rule","just","runs","without","timing","Args",":","rule","(","rule.Rule",")",":","The","rule","being","ran","record","(","dict",")",":","The","record","being","processed","Returns",":","bool",":","Result","of","rule","processing"]
code: def run_rule(self, rule, record):
      """Timing function for timing a rule function's duration
  
      Note: this function's timing aspect is a no-op if the RuleStatisticTracker
          is disabled, and instead the rule just runs without timing
  
      Args:
          rule (rule.Rule): The rule being ran
          record (dict): The record being processed
  
      Returns:
          bool: Result of rule processing
      """
      if not self.enabled:
          return rule.process(record)
  
      time_start = time.time()
      result = rule.process(record)
      time_end = time.time()
  
      self.__class__.STATS[rule.name] += RuleStatistic(
          (time_end - time_start) * 1000
      )
  
      return result
  
file_path: streamalert/streamalert/shared/stats.py
imports: from collections import defaultdict
  import time
  from streamalert.shared.logger import get_logger
label_desc: Use image node_id 2 for calling the RuleStatisticTracker obj's underlying member method code with example usage: obj.run_rule(rule, record) and returns: result, rule