Skip to content

Commit f2e6897

Browse files
JustreblDamien Aicheh
and
Damien Aicheh
authored
Feat/Docs Evolution to v2 with a FastTrack Path
--------- Co-authored-by: Julien Strebler <[email protected]> Co-authored-by: Damien Aicheh <[email protected]>
1 parent eb4fc14 commit f2e6897

24 files changed

+570
-227
lines changed

.devcontainer/devcontainer.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,15 @@
4141
"ms-vscode.vscode-node-azure-pack",
4242
// Azurite : Storage Account Emulator for local Azure Function Debug
4343
"azurite.azurite",
44-
//Language related extensions
44+
// Language related extensions
4545
"ms-dotnettools.csharp",
4646
"ms-python.python",
47+
// Mardown helpers :
48+
"davidanson.vscode-markdownlint",
49+
"valentjn.vscode-ltex",
4750
// Terraform
4851
"hashicorp.terraform"
52+
4953
]
5054
}
5155
},

.gitignore

+7-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,7 @@
1-
*.zip
1+
*.zip
2+
3+
# Local Dev Tools : Azurite
4+
__blobstorage__*
5+
__queuestorage__*
6+
__azurite_*
7+
*.bkp
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,36 @@
11
{
2-
"folders": [
3-
{
4-
"path": ".."
5-
}
6-
]
2+
"folders": [
3+
{
4+
"path": "..",
5+
},
6+
{
7+
"path": "../src/webapp",
8+
"name": "Lab 0 - Azure Static Web App "
9+
},
10+
{
11+
"path": "../src/solutions/dotnet",
12+
"name": "Lab 1 - Dotnet - Az Function (Solution)"
13+
},
14+
{
15+
"path": "../src/solutions/nodejs",
16+
"name": "Lab 1 - NodeJs - Az Function (Solution)"
17+
},
18+
{
19+
"path": "../src/solutions/python",
20+
"name": "Lab 1 - Python - Az Function (Solution)"
21+
},
22+
{
23+
"path": "../docs",
24+
"name": "Documentation"
25+
}
26+
],
27+
"settings": {
28+
"debug.internalConsoleOptions": "neverOpen",
29+
"azurite.location": "/tmp",
30+
"ltex.checkFrequency": "save",
31+
"ltex.additionalRules.motherTongue": "en-US",
32+
"ltex.dictionary": {
33+
"en-US":[":../docs/ltex.dictionary.en-US.txt"]
34+
}
35+
}
736
}

README.md

+8-7
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,13 @@ This Hands On Lab will let you discover and practice the Azure serverless servic
44

55
## Prerequisites
66

7-
To start this Hands On Lab you will need :
7+
You will find all the prerequisites at : [ [MOAW] Product Hands-on Lab : Azure Serverless Architecture > Prerequisites][moaw-prereq-link]
88

9-
- An Azure Subscription with the `Contributor` role to create and manage the labs' resources
10-
- A dedicated resource group for this lab to ease the cleanup at the end.
11-
- The [Azure CLI][az-cli-install] installed on your machine
12-
- The [Azure Functions Core Tools][az-func-core-tools] installed, this will be useful for creating the scaffold of your Azure Functions using command line.
13-
- If you are using VS Code, you can also install the [Azure Function extension][azure-function-vs-code-extension]
14-
- Register the Azure providers on your Azure Subscription if not done yet: `Microsoft.CognitiveServices`, `Microsoft.DocumentDB`, `Microsoft.EventGrid`, `Microsoft.KeyVault`, `Microsoft.Logic`, `Microsoft.SignalRService`, `Microsoft.Web`
9+
Different Development Environment Options will also be offered :
10+
11+
- Locally with the tools required
12+
- Devcontainer on your machine
13+
- Codespace directly from your browser
1514

1615
## Contributing
1716

@@ -34,3 +33,5 @@ trademarks or logos is subject to and must follow
3433
[Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
3534
Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
3635
Any use of third-party trademarks or logos are subject to those third-party's policies.
36+
37+
[moaw-prereq-link]: https://moaw.dev/workshop/gh:microsoft/hands-on-lab-serverless/main/docs/#prerequisites

docs/.markdownlint.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"MD033":false
3+
}

docs/assets/architecture-lab2.svg

+2-2
Loading

docs/assets/codespace-configure.png

19.5 KB
Loading

docs/assets/codespace-new.png

19.5 KB
Loading
9.04 KB
Loading
19.4 KB
Loading

docs/assets/codespace-workspace.png

34.7 KB
Loading

docs/assets/devcontainer-reopen.png

4.98 KB
Loading
Loading
-3.61 KB
Loading

docs/assets/logic-app-http-action.png

-18.5 KB
Loading
-32.2 KB
Loading

docs/assets/logic-app-run-history.png

53.6 KB
Loading

docs/assets/logic-app-run-result.png

36.7 KB
Loading

docs/ltex.dictionary.en-US.txt

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
PubSub
2+
PUBSUB

docs/workshop.md

+409-211
Large diffs are not rendered by default.
+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"version": "0.2.0",
3+
"configurations": [
4+
{
5+
"name": "Attach to .NET Functions",
6+
"type": "coreclr",
7+
"request": "attach",
8+
"processId": "${command:azureFunctions.pickProcess}"
9+
}
10+
]
11+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"azureFunctions.projectSubpath": ".",
3+
"azureFunctions.deploySubpath": "bin/Release/net7.0/publish",
4+
"azureFunctions.projectLanguage": "C#",
5+
"azureFunctions.projectRuntime": "~4",
6+
"azureFunctions.preDeployTask": "publish (functions)"
7+
}
+81
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
{
2+
"version": "2.0.0",
3+
"tasks": [
4+
{
5+
"label": "clean (functions)",
6+
"command": "dotnet",
7+
"args": [
8+
"clean",
9+
"/property:GenerateFullPaths=true",
10+
"/consoleloggerparameters:NoSummary"
11+
],
12+
"type": "process",
13+
"problemMatcher": "$msCompile",
14+
"options": {
15+
"cwd": "${workspaceFolder}"
16+
}
17+
},
18+
{
19+
"label": "build (functions)",
20+
"command": "dotnet",
21+
"args": [
22+
"build",
23+
"/property:GenerateFullPaths=true",
24+
"/consoleloggerparameters:NoSummary"
25+
],
26+
"type": "process",
27+
"dependsOn": "clean (functions)",
28+
"group": {
29+
"kind": "build",
30+
"isDefault": true
31+
},
32+
"problemMatcher": "$msCompile",
33+
"options": {
34+
"cwd": "${workspaceFolder}"
35+
}
36+
},
37+
{
38+
"label": "clean release (functions)",
39+
"command": "dotnet",
40+
"args": [
41+
"clean",
42+
"--configuration",
43+
"Release",
44+
"/property:GenerateFullPaths=true",
45+
"/consoleloggerparameters:NoSummary"
46+
],
47+
"type": "process",
48+
"problemMatcher": "$msCompile",
49+
"options": {
50+
"cwd": "${workspaceFolder}"
51+
}
52+
},
53+
{
54+
"label": "publish (functions)",
55+
"command": "dotnet",
56+
"args": [
57+
"publish",
58+
"--configuration",
59+
"Release",
60+
"/property:GenerateFullPaths=true",
61+
"/consoleloggerparameters:NoSummary"
62+
],
63+
"type": "process",
64+
"dependsOn": "clean release (functions)",
65+
"problemMatcher": "$msCompile",
66+
"options": {
67+
"cwd": "${workspaceFolder}"
68+
}
69+
},
70+
{
71+
"type": "func",
72+
"dependsOn": "build (functions)",
73+
"options": {
74+
"cwd": "${workspaceFolder}/bin/Debug/net7.0"
75+
},
76+
"command": "host start",
77+
"isBackground": true,
78+
"problemMatcher": "$func-dotnet-watch"
79+
}
80+
]
81+
}

src/solutions/dotnet/CosmosToWebPubSub.cs

+1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ public CosmosToWebPubSub(ILoggerFactory loggerFactory)
2222
databaseName: "%COSMOS_DB_DATABASE_NAME%",
2323
collectionName: "%COSMOS_DB_CONTAINER_ID%",
2424
ConnectionStringSetting = "COSMOS_DB_CONNECTION_STRING_SETTING",
25+
CreateLeaseCollectionIfNotExists = true,
2526
LeaseCollectionName = "leases")
2627
] IReadOnlyList<Transcription> input
2728
)

0 commit comments

Comments
 (0)