code: public synchronized GlobalMetadata processMetadata(GlobalMetadata metadata) {
      GlobalMetadata recordToAdd = getRecordToAdd(metadata);
      if (recordToAdd != null) {
        boolean isNew = addRecordAndEvictIfNecessary(recordToAdd);
        return isNew ? recordToAdd : null;
      }
  
      return null;
    }
docs: Process a metadata record, merging it with default metadata.
  <p>
  If the combined (metadata + defaultMetadata) record is not present in the Collector's cache,
  then the new metadata record will be stored in cache and returned. The oldest record in the cache will be evicted
  if necessary.
  <p>>
  If the new record already exists in the cache, then the LRU time will be updated but this method will return null.