protected void removeAllInternal() {
   final int partitionCount = clientContext.getPartitionService().getPartitionCount();
   final int completionId = nextCompletionId();
   registerCompletionLatch(completionId, partitionCount);
   ClientMessage request = CacheRemoveAllCodec.encodeRequest(nameWithPrefix, completionId);
   try {
     invoke(request);
     waitCompletionLatch(completionId, null);
     if (statisticsEnabled) {
       statistics.setLastUpdateTime(System.currentTimeMillis());
       // We don't support count stats of removing all entries.
     }
   } catch (Throwable t) {
     deregisterCompletionLatch(completionId);
     throw ExceptionUtil.rethrowAllowedTypeFirst(t, CacheException.class);
   }
 }
 @Override
 protected ClientMessage encodeResponse(Object response) {
   return CacheRemoveAllCodec.encodeResponse();
 }
 @Override
 protected CacheRemoveAllCodec.RequestParameters decodeClientMessage(ClientMessage clientMessage) {
   return CacheRemoveAllCodec.decodeRequest(clientMessage);
 }