Search in sources :

Example 6 with ProxyService

use of com.hazelcast.spi.ProxyService in project hazelcast by hazelcast.

the class LocalMapStatsProvider method addStatsOfNoDataIncludedMaps.

/**
     * Some maps may have a proxy but no data has been put yet. Think of one created a proxy but not put any data in it.
     * By calling this method we are returning an empty stats object for those maps. This is helpful to monitor those kind
     * of maps.
     */
private void addStatsOfNoDataIncludedMaps(Map statsPerMap) {
    ProxyService proxyService = nodeEngine.getProxyService();
    Collection<String> mapNames = proxyService.getDistributedObjectNames(SERVICE_NAME);
    for (String mapName : mapNames) {
        if (!statsPerMap.containsKey(mapName)) {
            statsPerMap.put(mapName, EMPTY_LOCAL_MAP_STATS);
        }
    }
}
Also used : ProxyService(com.hazelcast.spi.ProxyService)

Example 7 with ProxyService

use of com.hazelcast.spi.ProxyService in project hazelcast by hazelcast.

the class AddDistributedObjectListenerMessageTask method call.

@Override
protected Object call() throws Exception {
    final ProxyService proxyService = clientEngine.getProxyService();
    final String registrationId = proxyService.addProxyListener(this);
    endpoint.addDestroyAction(registrationId, new Callable() {

        @Override
        public Boolean call() {
            return proxyService.removeProxyListener(registrationId);
        }
    });
    return registrationId;
}
Also used : ProxyService(com.hazelcast.spi.ProxyService) Callable(java.util.concurrent.Callable)

Example 8 with ProxyService

use of com.hazelcast.spi.ProxyService in project hazelcast by hazelcast.

the class DestroyProxyMessageTask method call.

@Override
protected Object call() throws Exception {
    ProxyService proxyService = nodeEngine.getProxyService();
    proxyService.destroyDistributedObject(parameters.serviceName, parameters.name);
    return null;
}
Also used : ProxyService(com.hazelcast.spi.ProxyService)

Aggregations

ProxyService (com.hazelcast.spi.ProxyService)8 QueueContainer (com.hazelcast.collection.impl.queue.QueueContainer)1 DistributedObject (com.hazelcast.core.DistributedObject)1 ConnectionManagerDTO (com.hazelcast.internal.management.dto.ConnectionManagerDTO)1 EventServiceDTO (com.hazelcast.internal.management.dto.EventServiceDTO)1 MXBeansDTO (com.hazelcast.internal.management.dto.MXBeansDTO)1 ManagedExecutorDTO (com.hazelcast.internal.management.dto.ManagedExecutorDTO)1 OperationServiceDTO (com.hazelcast.internal.management.dto.OperationServiceDTO)1 PartitionServiceBeanDTO (com.hazelcast.internal.management.dto.PartitionServiceBeanDTO)1 ProxyServiceDTO (com.hazelcast.internal.management.dto.ProxyServiceDTO)1 InternalPartitionService (com.hazelcast.internal.partition.InternalPartitionService)1 MapService (com.hazelcast.map.impl.MapService)1 MapServiceContext (com.hazelcast.map.impl.MapServiceContext)1 MapProxyImpl (com.hazelcast.map.impl.proxy.MapProxyImpl)1 ConnectionManager (com.hazelcast.nio.ConnectionManager)1 EventService (com.hazelcast.spi.EventService)1 ExecutionService (com.hazelcast.spi.ExecutionService)1 NodeEngine (com.hazelcast.spi.NodeEngine)1 InternalOperationService (com.hazelcast.spi.impl.operationservice.InternalOperationService)1 ManagedExecutorService (com.hazelcast.util.executor.ManagedExecutorService)1