Stream Manager 2.0 NodeGroupConfig Example – Multiple Regions in a Hierarchy of GeoZones
Scheduled Overlay
This example is a scheduled overlay. It overlays the “All-in-One” example given earlier (first example). This overlay is active per schedule, on weekends. Note that in the base config (the “All-in-One” example) the scale rule defines min and max servers as 1. Also note that in the overlay config, the min and max servers is 2. Therefore, on the weekends, the system will ensure 2 active servers but during the week, 1 active server.
"baseNodeGroupName": "allinone-oci-1",
"schedules": {
"main": {
"name": "main",
"startAt": "0 0 0 ? * SAT *",
"durationS": 172800
}
}
Complete Example:
{
"name": "allinone-overlay-1",
"description": "This is an OCI example.",
"cloudPlatform": "OCI",
"cloudProperties": "environment=testing;subnet=red5-ci-deployments-multiregion-subnet-public;security_group=red5-ci-deployments-multiregion-node-nsg;volume_size=50",
"shuffleSizeExpression": "1",
"maxPublishers": "100",
"maxSubscribers": "200",
"baseNodeGroupName": "allinone-oci-1",
"propertyOverrides": [
{
"fileName": "conf/autoscale.properties",
"properties": {
"reportingSpeed": "500"
}
}
],
"images": {
"BaseImage": {
"name": "BaseImage",
"image": "as-node-12-2-4-b156",
"cloudProperties": "instance_type=VM.Standard.E4.Flex-1-4"
}
},
"roles": {
"allinone": {
"name": "allinone",
"imageName": "BaseImage",
"capabilities": [
"PUBLISH",
"SUBSCRIBE",
"TRANSCODE"
]
}
},
"groups": {
"ashburn": {
"subGroupName": "ashburn",
"groupType": "main",
"cloudProperties": "region=us-ashburn-1",
"rulesByRole": {
"allinone": {
"nodeRoleName": "allinone",
"min": 2,
"max": 2,
"increment": 1,
"outExpression": "min(connections.client) > 75",
"inExpression": "avg(connections.client) < 1",
"capacityRankingExpression": "connections.client",
"capacityLimitExpression": "100"
}
}
}
},
"schedules": {
"main": {
"name": "main",
"startAt": "0 0 0 ? * SAT *",
"durationS": 172800
}
}
}