Created
April 20, 2020 19:37
-
-
Save bonedaddy/211396e6781452f8207fe2df41815f48 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p2plab | |
// defines a set of nodes of size 1 or higher | |
// a "node" is simply an EC2 instance provisioned of the given type | |
Nodes :: { | |
// must be greater than or equal to 1 | |
// default value of this field is 1 | |
size: >=1 | *1 | |
instanceType: string | |
region: string | |
// labels is an optional field | |
labels?: [...string] | |
} | |
// a cluster is a collection of 1 or more groups of nodes | |
Cluster :: { | |
groups: [...Nodes] | |
} | |
object: [Name=_]: { | |
type: string | |
source: string | |
} | |
Scenario :: { | |
objects: [...object] | |
seed: { ... } | |
// enable any fields for benchmark | |
benchmark: { ... } | |
} | |
Experiment :: { | |
cluster: Cluster | |
scenario: Scenario | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package p2plab | |
object: "golang": { | |
type: "oci" | |
source: "docker.io/library/golang:latest" | |
} | |
object: "mysql": { | |
type: "oci" | |
source: "docker.io/library/mysql:latest" | |
} | |
experiment: Experiment & { | |
cluster: Cluster & { | |
groups: [ | |
Nodes & { | |
size: 10 | |
instanceType: "t3.micro" | |
region: "us-west-1" | |
}, | |
Nodes & { | |
size: 2 | |
instanceType: "t3.medium" | |
region: "us-east-1" | |
labels: [ "neighbors" ] | |
} | |
] | |
} | |
scenario: Scenario & { | |
objects: [ object ] | |
seed: { | |
"neighbors": "golang" | |
} | |
benchmark: { | |
"(not neighbors)": "golang" | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment