private static String processAttributeValue(String value) {
   String trimmedValue = StringUtil.clipString(value, MAX_EVENT_ATTRIBUTE_VALUE_LENGTH, false);
   if (trimmedValue.length() < value.length()) {
     log.warn(
         "The attribute value has been trimmed to a length of "
             + MAX_EVENT_ATTRIBUTE_VALUE_LENGTH
             + " characters");
   }
   return trimmedValue;
 }
 private static String processAttributeMetricKey(String key) {
   String trimmedKey = StringUtil.clipString(key, MAX_EVENT_ATTRIBUTE_METRIC_KEY_LENGTH, false);
   if (trimmedKey.length() < key.length()) {
     log.warn(
         "The attribute key has been trimmed to a length of "
             + MAX_EVENT_ATTRIBUTE_METRIC_KEY_LENGTH
             + " characters");
   }
   return trimmedKey;
 }