public void run() {
// I always succeed.
try {
// Create the necessary disk structures so this node's partition is promoted to Hazelcast
getLocalStorageFolder("t1", 0, version).mkdirs();
ThriftWriter writer = new ThriftWriter(getLocalMetadataFile("t1", 0, version));
PartitionMetadata metadata = new PartitionMetadata();
// we need to set expected replication factor, otherwise replica balancing will not trigger for this test
metadata.setNReplicas(2);
writer.write(metadata);
writer.close();
new File(getLocalStorageFolder("t1", 0, version), "0.db").createNewFile();
// promote info to Hazelcast
getDnodesRegistry().changeInfo(new DNodeInfo(config));
} catch(IOException e) {
e.printStackTrace();