code: private static String formatServiceType(final CouchbaseRequest request) {
          if (request instanceof BinaryRequest) {
              return ThresholdLogReporter.SERVICE_KV;
          } else if (request instanceof QueryRequest) {
              return ThresholdLogReporter.SERVICE_N1QL;
          } else if (request instanceof ViewRequest) {
              return ThresholdLogReporter.SERVICE_VIEW;
          } else if (request instanceof AnalyticsRequest) {
              return ThresholdLogReporter.SERVICE_ANALYTICS;
          } else if (request instanceof SearchRequest) {
              return ThresholdLogReporter.SERVICE_FTS;
          } else if (request instanceof ConfigRequest) {
              // Shouldn't be user visible, but just for completeness sake.
              return "config";
          } else {
              return "unknown";
          }
      }
docs: Helper method to turn the request into the proper string service type.