code: private List<Versioned<byte[]>> filterExpiredEntries(ByteArray key, List<Versioned<byte[]>> vals) {
          Iterator<Versioned<byte[]>> valsIterator = vals.iterator();
          while(valsIterator.hasNext()) {
              Versioned<byte[]> val = valsIterator.next();
              VectorClock clock = (VectorClock) val.getVersion();
              // omit if expired
              if(clock.getTimestamp() < (time.getMilliseconds() - this.retentionTimeMs)) {
                  valsIterator.remove();
                  // delete stale value if configured
                  if(deleteExpiredEntries) {
                      getInnerStore().delete(key, clock);
                  }
              }
          }
          return vals;
      }
docs: Performs the filtering of the expired entries based on retention time.
  Optionally, deletes them also
  
  @param key the key whose value is to be deleted if needed
  @param vals set of values to be filtered out
  @return filtered list of values which are currently valid