Skip to content

Instantly share code, notes, and snippets.

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
public class Main {
public static void main(String[] args) throws InterruptedException {
int numberOfIterationInOuterLoop = Integer.parseInt(args[0]);
int port = Integer.parseInt(args[1]);
long duration = 0;
@HaoyuHuang
HaoyuHuang / 2PL_metrics.py
Last active January 30, 2016 07:27
2PL metrics calculation
# number of distinct objects in the database
db_size = pow(10, 10)
# number of nodes: each nodes replicate all objects
nodes = 10
# transaction per second at one node
tps = pow(10, 6)
# number of actions per transaction
actions = 4
# time to perform an actions (second)
action_time = 0.05