code: def get_metrics_from_perfdata(self, service, perf_data):
          result = []
          metrics = PerfDatas(perf_data)
          for metric in metrics:
              logger.debug("service: %s, metric: %s (%s)", service, metric, metric.__dict__)
              if metric.name in ['time']:
                  metric.name = "duration"
              name = sanitize_name(metric.name)
              name = self.multiple_values.sub(r'.\1', name)
              if not name:
                  continue
              name_value = {
                  name: metric.value,
                  'uom_' + name: metric.uom
              }
              if metric.warning and self.send_warning:
                  name_value[name + '_warn'] = metric.warning
              if metric.critical and self.send_critical:
                  name_value[name + '_crit'] = metric.critical
              if metric.min and self.send_min:
                  name_value[name + '_min'] = metric.min
              if metric.max and self.send_max:
                  name_value[name + '_max'] = metric.max
              for key, value in name_value.items():
                  result.append((key, value, metric.uom))
          logger.debug("Metrics: %s - %s", service, result)
          return result