Search in sources :

Example 1 with SnapshotCommand

use of org.apache.cassandra.db.SnapshotCommand in project cassandra by apache.

the class SnapshotVerbHandler method doVerb.

public void doVerb(MessageIn<SnapshotCommand> message, int id) {
    SnapshotCommand command = message.payload;
    if (command.clear_snapshot) {
        Keyspace.clearSnapshot(command.snapshot_name, command.keyspace);
    } else
        Keyspace.open(command.keyspace).getColumnFamilyStore(command.column_family).snapshot(command.snapshot_name);
    logger.debug("Enqueuing response to snapshot request {} to {}", command.snapshot_name, message.from);
    MessagingService.instance().sendReply(new MessageOut(MessagingService.Verb.INTERNAL_RESPONSE), id, message.from);
}
Also used : SnapshotCommand(org.apache.cassandra.db.SnapshotCommand) MessageOut(org.apache.cassandra.net.MessageOut)

Aggregations

SnapshotCommand (org.apache.cassandra.db.SnapshotCommand)1 MessageOut (org.apache.cassandra.net.MessageOut)1