private void sendSnapshotTxnId ( SnapshotInfo toRestore ) { long txnId = toRestore != null ? toRestore . txnId : 0 ; String jsonData = toRestore != null ? toRestore . toJSONObject ( ) . toString ( ) : "{}" ; LOG . debug ( "Sending snapshot ID " + txnId + " for restore to other nodes" ) ; try { m_zk . create ( VoltZK . restore_snapshot_id , jsonData . getBytes ( Constants . UTF8ENCODING ) , Ids . OPEN_ACL_UNSAFE , CreateMode . EPHEMERAL ) ; } catch ( Exception e ) { VoltDB . crashGlobalVoltDB ( "Failed to create Zookeeper node: " + e . getMessage ( ) , false , e ) ; } }
Send the txnId of the snapshot that was picked to restore from to the other hosts . If there was no snapshot to restore from send 0 .