Is there anyway in Hazelcast client to get the list of AtomicLongs present in the cluster. I might need to know the counter names to clear it, since there is no TTL for AtomicCounter.
Thanks in advance.
Is there anyway in Hazelcast client to get the list of AtomicLongs present in the cluster. I might need to know the counter names to clear it, since there is no TTL for AtomicCounter.
Thanks in advance.
you can list all distributed objects and filter AtomicLongs
Collection<DistributedObject> distributedObjects = instance.getDistributedObjects();
List<DistributedObject> atomicLongList = distributedObjects
.stream()
.filter(o -> o.getServiceName().equals(AtomicLongService.SERVICE_NAME))
.collect(Collectors.toList());