private static Predicate<CachedHashedDataFeedKey> createKeyOwnerFilter(final CIKey keyOwnerMetaKey,
                                                                           final String ownerFromAttrMap) {
        Predicate<CachedHashedDataFeedKey> filter;
        if (CIKey.isNonBlank(keyOwnerMetaKey)) {
            filter = (CachedHashedDataFeedKey key) -> {
                final String ownerFromKey = key.getStreamMetaValue(keyOwnerMetaKey);
                final boolean result = Objects.equals(ownerFromKey, ownerFromAttrMap);
                LOGGER.debug("keyOwnerMetaKey: {}, ownerFromAttrMap: {}, ownerFromKey: {}, result: {}",
                        keyOwnerMetaKey, ownerFromAttrMap, ownerFromKey, result);
                return result;
            };
        } else {
            filter = key -> true;
        }
        return filter;
    }
@return A populated {@link Optional} if the key is known to use and is valid, else empty.
stroom-receive/stroom-receive-common/src/main/java/stroom/receive/common/DataFeedKeyServiceImpl.java