Skip to content

Commit 2d5da1c

Browse files
Merge pull request #150 from mspnp/dev
Drone Delivery 0.1.0 - scalability, ingress and networking
2 parents 69a8f63 + c38b065 commit 2d5da1c

File tree

88 files changed

+2329
-530
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+2329
-530
lines changed

README.md

Lines changed: 16 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,22 @@ Microsoft patterns & practices
33

44
This reference implementation shows a set of best practices for building and running a microservices architecture on Microsoft Azure, using Kubernetes.
55

6+
| | [Basic](https://github.com/mspnp/microservices-reference-implementation/tree/basic) | [Advanced](https://github.com/mspnp/microservices-reference-implementation/) |
7+
|-----------------------------------------|-------|----------|
8+
| Distributed Monitoring |||
9+
| Ingress Controller |||
10+
| Azure Active Directory Pod Identity |||
11+
| CI/CD using Azure Pipelines |||
12+
| Helm charts |||
13+
| Resource Limits |||
14+
| Readiness/Liveness Probes |||
15+
| Horizontal Pod Autoscaling |||
16+
| Cluster Autoscaling |||
17+
| Advanced Networking |||
18+
| Service Endpoints |||
19+
| Network Policies |||
20+
| Egress restriction using Azure Firewall |||
21+
622
## Guidance
723

824
This project has a companion set of articles that describe challenges, design patterns, and best practices for building microservices architecture. You can find these articles on the Azure Architecture Center:
@@ -29,31 +45,6 @@ The Drone Delivery application is a sample application that consists of several
2945

3046
![](./architecture.png)
3147

32-
## Test results and metrics
33-
The Drone Delivery application has been tested up to 2000 messages/sec:
34-
35-
36-
| | Replicas | ~Max CPU (mc) | ~Max Mem (MB) | Avg. Throughput*  | Max. Throughput* | Avg (ms) | 50<sup>th</sup> (ms) | 95<sup>th</sup> (ms) | 99<sup>th</sup> (ms) |
37-
|------------------------------------------|----------|---------------|---------------|-------------------------|-------------------------|----------|-----------|-----------|-----------|
38-
| Nginx | 1 | N/A | N/A | serve: 1595 reqs/sec | serve: 1923 reqs/sec | N/A | N/A | N/A | N/A |
39-
| Ingestion | 10 | 474 | 488 | ingest: 1275 msgs/sec | ingest: 1710 msgs/sec | 251 | 50.1 | 1560 | 2540 |
40-
| Workflow (receive messages) | 35 | 1445 | 79 | egress: 1275 msgs/sec | egress: 1710 msgs/sec | 81.5 | 0 | 25.7 | 121 |
41-
| Workflow (call backend services + mark message as complete) | 35 | 1445 | 79 | complete: 1100 msgs/sec | complete: 1322 msgs/sec | 561.8 | 447 | 1350 | 2540 |
42-
| Package | 50 | 213 | 78 | N/A | N/A | 67.5 | 53.9 | 165 | 306 |
43-
| Delivery | 50 | 328 | 334 | N/A | N/A | 93.8 | 82.4 | 200 | 304 |
44-
| Dronescheduler | 50 | 402 | 301 | N/A | N/A | 85.9 | 72.6 | 203 | 308 |
45-
46-
47-
48-
*sources:
49-
1. Serve: Visual Studio Load Test Throughout Request/Sec
50-
2. Ingest: Azure Service Bus metrics Incoming Messages/Sec
51-
3. Egress: Azure Service Bus metrics Outgoing Messages/Sec
52-
4. Complete: AI Service Bus Complete dependencies
53-
5. Avg/50<sup>th</sup>/95<sup>th</sup>/99<sup>th</sup>: AI dependencies
54-
6. CPU/Mem: Azure Monitor for Containers
55-
56-
5748
## Deployment
5849

5950
To deploy the solution, follow the steps listed [here](./deployment.md).

azuredeploy-firewall.json

Lines changed: 464 additions & 0 deletions
Large diffs are not rendered by default.

azuredeploy-prereqs.json

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,24 +28,28 @@
2828
"deliveryIdName": "dev-d",
2929
"workflowIdName": "dev-wf",
3030
"droneSchedulerIdName": "dev-ds",
31+
"appGatewayControllerIdName": "dev-ag",
3132
"acrResourceGroupName": "[variables('acrResourceGroupNamePrefix')]"
3233
},
3334
"qa": {
3435
"deliveryIdName": "qa-d",
3536
"workflowIdName": "qa-wf",
3637
"droneSchedulerIdName": "qa-ds",
38+
"appGatewayControllerIdName": "qa-ag",
3739
"acrResourceGroupName": "[variables('acrResourceGroupNamePrefix')]"
3840
},
3941
"staging": {
4042
"deliveryIdName": "staging-d",
4143
"workflowIdName": "staging-wf",
4244
"droneSchedulerIdName": "staging-ds",
45+
"appGatewayControllerIdName": "staging-ag",
4346
"acrResourceGroupName": "[variables('acrResourceGroupNamePrefix')]"
4447
},
4548
"prod": {
4649
"deliveryIdName": "prod-d",
4750
"workflowIdName": "prod-wf",
4851
"droneSchedulerIdName": "prod-ds",
52+
"appGatewayControllerIdName": "prod-ag",
4953
"acrResourceGroupName": "[concat(variables('acrResourceGroupNamePrefix'),'-',parameters('environmentName'))]"
5054
}
5155
}
@@ -121,6 +125,18 @@
121125
"app": "fabrikam-dronescheduler",
122126
"[parameters('environmentName')]": true
123127
}
128+
},
129+
{
130+
"type": "Microsoft.ManagedIdentity/userAssignedIdentities",
131+
"name": "[variables('environmentSettings')[parameters('environmentName')].appGatewayControllerIdName]",
132+
"apiVersion": "2015-08-31-preview",
133+
"location": "[parameters('resourceGroupLocation')]",
134+
"tags": {
135+
"displayName": "app gateway controller managed identity",
136+
"what": "rbac",
137+
"reason": "aad-pod-identity",
138+
"[parameters('environmentName')]": true
139+
}
124140
}
125141
],
126142
"outputs": {
@@ -148,6 +164,14 @@
148164
"value": "[concat(subscription().id, '/resourceGroups/',parameters('resourceGroupName'),'/providers/Microsoft.ManagedIdentity/userAssignedIdentities/',variables('environmentSettings')[parameters('environmentName')].workflowIdName)]",
149165
"type": "string"
150166
},
167+
"appGatewayControllerIdName": {
168+
"value": "[variables('environmentSettings')[parameters('environmentName')].appGatewayControllerIdName]",
169+
"type": "string"
170+
},
171+
"appGatewayControllerPrincipalResourceId": {
172+
"value": "[concat(subscription().id, '/resourceGroups/',parameters('resourceGroupName'),'/providers/Microsoft.ManagedIdentity/userAssignedIdentities/',variables('environmentSettings')[parameters('environmentName')].appGatewayControllerIdName)]",
173+
"type": "string"
174+
},
151175
"acrResourceGroupName": {
152176
"value": "[variables('environmentSettings')[parameters('environmentName')].acrResourceGroupName]",
153177
"type": "string"

0 commit comments

Comments
 (0)