@Override
protected ModelNode invokeCommand(Cache<?, ?> cache, ModelNode operation) throws Exception {
final PathAddress address = PathAddress.pathAddress(operation.require(OP_ADDR));
final String site = address.getLastElement().getValue();
XSiteAdminOperations xsiteAdminOperations = SecurityActions.getComponentRegistry(cache.getAdvancedCache()).getComponent(XSiteAdminOperations.class);
return toOperationResult(xsiteAdminOperations.bringSiteOnline(site));
}
}
public static class BackupTakeSiteOfflineCommand extends CacheCommands {
public static final BackupTakeSiteOfflineCommand INSTANCE = new BackupTakeSiteOfflineCommand();