log.warn("Cache named [{0}] exists but isn't in a state to handle invocations. Its state is {1}.", cacheName, cr.getStatus());
return RequestIgnoredResponse.INSTANCE;
}
}
InvocationContextContainer icc = cr.getLocalComponent(InvocationContextContainer.class);
CommandsFactory commandsFactory = cr.getLocalComponent(CommandsFactory.class);
// initialize this command with components specific to the intended cache instance
commandsFactory.initializeReplicableCommand(cmd);
try {
Object retval = cmd.perform(icc.get());
return cr.getComponent(ResponseGenerator.class).getResponse(cmd, retval);
} catch (Exception e) {
return new ExceptionResponse(e);
}
}