Skip to content

Commit b88e777

Browse files
Expose retry context to custom handlers (#7768)
1 parent c3a1d06 commit b88e777

File tree

10 files changed

+583
-1
lines changed

10 files changed

+583
-1
lines changed

azure-pipelines.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,7 @@ jobs:
349349
inputs:
350350
targetType: 'inline'
351351
script: 'Install-Module -Name Az.Storage -RequiredVersion 1.11.0 -Scope CurrentUser -Force -AllowClobber'
352+
352353
- task: AzureKeyVault@1
353354
inputs:
354355
# Note: This is actually a Service Connection in DevOps, not an Azure subscription name
@@ -410,6 +411,11 @@ jobs:
410411
inputs:
411412
targetType: 'inline'
412413
script: 'Install-Module -Name Az.Storage -RequiredVersion 1.11.0 -Scope CurrentUser -Force -AllowClobber'
414+
- task: Npm@1
415+
displayName: 'npm ci'
416+
inputs:
417+
command: ci
418+
workingDir: sample/CustomHandlerRetry
413419
- task: AzureKeyVault@1
414420
inputs:
415421
# Note: This is actually a Service Connection in DevOps, not an Azure subscription name
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
{
2+
"bindings": [
3+
{
4+
"authLevel": "anonymous",
5+
"type": "httpTrigger",
6+
"direction": "in",
7+
"name": "req",
8+
"methods": [
9+
"get",
10+
"post"
11+
]
12+
},
13+
{
14+
"type": "http",
15+
"direction": "out",
16+
"name": "res"
17+
}
18+
]
19+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"version": "2.0",
3+
"customHandler": {
4+
"enableForwardingHttpRequest": false,
5+
"description": {
6+
"defaultExecutablePath": "node",
7+
"arguments": [ "server.js" ]
8+
}
9+
},
10+
"retry": {
11+
"strategy": "fixedDelay",
12+
"maxRetryCount": 2,
13+
"delayInterval": "00:00:00"
14+
}
15+
}

0 commit comments

Comments
 (0)