X-Git-Url: http://git.onelab.eu/?p=distributedratelimiting.git;a=blobdiff_plain;f=drl%2Fraterouter.h;h=5e89e89eadaca33cf630e58660c07ce04a687c82;hp=789cd95f8d0fcb2b52d72fb1019c688bed8eb7ac;hb=c9d6255f0c06ee41eb2c06a5f74a957ec7be3223;hpb=da2e1847da1c3ece4b1a8685de49d972aed48178 diff --git a/drl/raterouter.h b/drl/raterouter.h index 789cd95..5e89e89 100644 --- a/drl/raterouter.h +++ b/drl/raterouter.h @@ -34,7 +34,10 @@ enum policies { POLICY_GRD = 1, POLICY_FPS = 2 }; enum commfabrics { COMM_MESH = 1, COMM_GOSSIP = 2 }; -enum accountings { ACT_STANDARD = 1, ACT_SAMPLEHOLD = 2, ACT_SIMPLE = 3 }; +enum accountings { ACT_STANDARD = 1, ACT_SAMPLEHOLD = 2, ACT_SIMPLE = 3, ACT_MULTIPLE = 4 }; +enum dampenings { DAMPEN_NONE = 0, DAMPEN_TEST = 1, DAMPEN_FAILED = 2, DAMPEN_PASSED = 3, DAMPEN_SKIP = 4 }; +enum memberships { SWIM = 1, ZOOKEEPER = 2 }; +enum failure_behaviors { PANIC = 1, QUORUM = 2 }; /* The comm library also has definitions for comfabrics. This prevents us * from defining them twice. */ @@ -59,7 +62,9 @@ enum accountings { ACT_STANDARD = 1, ACT_SAMPLEHOLD = 2, ACT_SIMPLE = 3 }; */ #define FLOW_START_THRESHOLD (6000) -#define CLOSE_ENOUGH (0.99) +#define CLOSE_ENOUGH (0.90) + +#define GRD_BIG_DROP (0.90) /** * All fields come from the ip protocol header. @@ -74,6 +79,16 @@ enum accountings { ACT_STANDARD = 1, ACT_SAMPLEHOLD = 2, ACT_SIMPLE = 3 }; */ #define FLOWKEYSIZE (13) +/* Causes each identity to track every flow in two tables. One table is as + * specified in the config file. The second is a standard table with + * "perfect" accounting so that we can compare the two. Turn this off for + * any type of production setting. */ +//#define SHADOW_ACCTING + +/* Turn this on to simulate network partitions. + * Turn off for production settings. */ +#define ALLOW_PARTITION + /* forward declare some structs */ struct limiter; struct identity;