use of com.hazelcast.client.cp.internal.datastructures.semaphore.SessionAwareSemaphoreProxy in project hazelcast by hazelcast.
the class ClientRaftProxyFactory method createSemaphore.
private ISemaphore createSemaphore(RaftGroupId groupId, String proxyName, String objectName) {
ClientMessage request = SemaphoreGetSemaphoreTypeCodec.encodeRequest(proxyName);
ClientMessage response = new ClientInvocation(client, request, objectName).invoke().join();
boolean jdkCompatible = SemaphoreGetSemaphoreTypeCodec.decodeResponse(response);
return jdkCompatible ? new SessionlessSemaphoreProxy(context, groupId, proxyName, objectName) : new SessionAwareSemaphoreProxy(context, groupId, proxyName, objectName);
}
Aggregations