use of com.hazelcast.security.permission.CachePermission in project hazelcast by hazelcast.
the class StreamEventJournalP method streamRemoteCacheSupplier.
@SuppressWarnings("unchecked")
public static <K, V, T> ProcessorMetaSupplier streamRemoteCacheSupplier(@Nonnull String cacheName, @Nonnull String clientXml, @Nonnull PredicateEx<? super EventJournalCacheEvent<K, V>> predicate, @Nonnull FunctionEx<? super EventJournalCacheEvent<K, V>, ? extends T> projection, @Nonnull JournalInitialPosition initialPos, @Nonnull EventTimePolicy<? super T> eventTimePolicy) {
checkSerializable(predicate, "predicate");
checkSerializable(projection, "projection");
return new ClusterMetaSupplier<>(clientXml, SecuredFunctions.cacheEventJournalReaderFn(cacheName), predicate, projection, initialPos, eventTimePolicy, () -> new CachePermission(cacheName, ACTION_CREATE, ACTION_READ));
}
use of com.hazelcast.security.permission.CachePermission in project hazelcast by hazelcast.
the class StreamEventJournalP method streamCacheSupplier.
@SuppressWarnings("unchecked")
public static <K, V, T> ProcessorMetaSupplier streamCacheSupplier(@Nonnull String cacheName, @Nonnull PredicateEx<? super EventJournalCacheEvent<K, V>> predicate, @Nonnull FunctionEx<? super EventJournalCacheEvent<K, V>, ? extends T> projection, @Nonnull JournalInitialPosition initialPos, @Nonnull EventTimePolicy<? super T> eventTimePolicy) {
checkSerializable(predicate, "predicate");
checkSerializable(projection, "projection");
return new ClusterMetaSupplier<>(null, SecuredFunctions.cacheEventJournalReaderFn(cacheName), predicate, projection, initialPos, eventTimePolicy, () -> new CachePermission(cacheName, ACTION_CREATE, ACTION_READ));
}
Aggregations