restRequest, restChannel) {
@Override
protected void handleRiverResponse(NodeFullUpdateResponse nodeInfo) throws Exception {
if (actionRequest.isSpaceKeyRequest() && !nodeInfo.spaceFound) {
restChannel.sendResponse(new BytesRestResponse(RestStatus.NOT_FOUND, buildMessageDocument(
restRequest, "Space '" + spaceKey + "' is not indexed by RemoteRiver with name: " + riverName)));
} else {
restChannel.sendResponse(new BytesRestResponse(OK, buildMessageDocument(restRequest,
"Scheduled full reindex for Spaces: " + nodeInfo.reindexedSpaces)));
}
}
});