Skip to content

Commit f7ead60

Browse files
committed
Moving to latest core SDK and adding Queue VisibilityTimeout configurability
1 parent be7b649 commit f7ead60

File tree

19 files changed

+222
-205
lines changed

19 files changed

+222
-205
lines changed

sample/host.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,8 @@
99
},
1010
"tracing": {
1111
"fileLoggingMode": "always"
12+
},
13+
"queues": {
14+
"visibilityTimeout": "00:00:10"
1215
}
1316
}

schemas/json/function.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,8 +247,8 @@
247247
],
248248
"description": "The function HTTP authorization level."
249249
},
250-
"methods":{
251-
"type":"array",
250+
"methods": {
251+
"type": "array",
252252
"items": [
253253
{
254254
"type": "string",

schemas/json/host.json

Lines changed: 168 additions & 162 deletions
Original file line numberDiff line numberDiff line change
@@ -1,185 +1,191 @@
11
{
2-
"title": "JSON schema for Azure Functions host.json files",
3-
"$schema": "http://json-schema.org/draft-04/schema#",
4-
5-
"type": "object",
6-
7-
"properties": {
8-
"id": {
9-
"description": "The unique ID for this job host. Can be a lower case GUID with dashes removed",
10-
"type": "string",
11-
"minLength": 1
12-
},
13-
14-
"functions": {
15-
"description": "The list of functions the host should load.",
16-
"type": "array",
17-
18-
"items": {
19-
"type": "string",
20-
"uniqueItems": true
21-
}
22-
},
23-
24-
"functionTimeout": {
25-
"description": "Value indicating the timeout duration for all functions.",
26-
"oneOf": [
27-
{
28-
"type": "string",
29-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$"
30-
},
31-
{
32-
"enum": [ null ]
33-
}
34-
]
35-
},
36-
37-
"http": {
38-
"description": "Configuration settings for 'http' triggers.",
39-
"type": "object",
40-
"required": ["routePrefix"],
41-
42-
"properties": {
43-
"routePrefix": {
44-
"description": "Defines the default route prefix that applies to all routes. Use an empty string to remove the prefix.",
45-
"type": "string",
46-
"default": "api"
47-
}
48-
}
49-
},
50-
51-
"watchDirectories": {
52-
"description": "Set of shared code directories that should be monitored for changes to ensure that when code in these directories is changed, it is picked up by your functions",
53-
"type": "array",
54-
55-
"items": {
56-
"type": "string",
57-
"minLength": 1,
58-
"uniqueItems": true
59-
}
60-
},
61-
62-
"queues": {
63-
"description": "Configuration settings for 'queue' triggers.",
64-
"type": "object",
65-
66-
"properties": {
67-
"maxPollingInterval": {
68-
"description": "The maximum interval in milliseconds between queue polls.",
69-
"type": "integer",
70-
"default": 1000
71-
},
2+
"title": "JSON schema for Azure Functions host.json files",
3+
"$schema": "http://json-schema.org/draft-04/schema#",
4+
5+
"type": "object",
726

73-
"batchSize": {
74-
"description": "The number of queue messages to retrieve and process in parallel (per job function).",
75-
"type": "integer",
76-
"maximum": 32,
77-
"minimum": 1,
78-
"default": 16
7+
"properties": {
8+
"id": {
9+
"description": "The unique ID for this job host. Can be a lower case GUID with dashes removed",
10+
"type": "string",
11+
"minLength": 1
7912
},
8013

81-
"maxDequeueCount": {
82-
"description": "The number of times to try processing a message before moving it to the poison queue",
83-
"type": "integer",
84-
"default": 5
14+
"functions": {
15+
"description": "The list of functions the host should load.",
16+
"type": "array",
17+
18+
"items": {
19+
"type": "string",
20+
"uniqueItems": true
21+
}
8522
},
8623

87-
"newBatchThreshold": {
88-
"description": "The threshold at which a new batch of messages will be fetched. The default is batchSize/2.",
89-
"type": "integer"
90-
}
91-
}
92-
},
93-
94-
"serviceBus": {
95-
"description": "Configuration settings for 'serviceBus' triggers.",
96-
"type": "object",
97-
98-
"properties": {
99-
"maxConcurrentCalls": {
100-
"description": "The maximum number of concurrent calls to the callback the message pump should initiate.",
101-
"type": "integer",
102-
"default": 16
24+
"functionTimeout": {
25+
"description": "Value indicating the timeout duration for all functions.",
26+
"oneOf": [
27+
{
28+
"type": "string",
29+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$"
30+
},
31+
{
32+
"enum": [ null ]
33+
}
34+
]
10335
},
10436

105-
"prefetchCount": {
106-
"description": "The default PrefetchCount that will be used by the underlying MessageReceiver.",
107-
"type": "integer"
108-
}
109-
}
110-
},
111-
112-
"eventHub": {
113-
"description": "Configuration settings for 'eventHub' triggers.",
114-
"type": "object",
115-
116-
"properties": {
117-
"maxBatchSize": {
118-
"description": "The maximum event count received per receive loop.",
119-
"type": "integer",
120-
"default": 1000
37+
"http": {
38+
"description": "Configuration settings for 'http' triggers.",
39+
"type": "object",
40+
"required": [ "routePrefix" ],
41+
42+
"properties": {
43+
"routePrefix": {
44+
"description": "Defines the default route prefix that applies to all routes. Use an empty string to remove the prefix.",
45+
"type": "string",
46+
"default": "api"
47+
}
48+
}
12149
},
12250

123-
"prefetchCount": {
124-
"description": "The default PrefetchCount that will be used by the underlying EventProcessorHost.",
125-
"type": "integer"
126-
}
127-
}
128-
},
129-
130-
"tracing": {
131-
"description": "Configuration settings for logging/tracing behavior.",
132-
"type": "object",
133-
134-
"properties": {
135-
"consoleLevel": {
136-
"description": "The tracing level used for console logging.",
137-
"enum": [ "off", "error", "warning", "info", "verbose" ],
138-
"default": "verbose"
51+
"watchDirectories": {
52+
"description": "Set of shared code directories that should be monitored for changes to ensure that when code in these directories is changed, it is picked up by your functions",
53+
"type": "array",
54+
55+
"items": {
56+
"type": "string",
57+
"minLength": 1,
58+
"uniqueItems": true
59+
}
13960
},
14061

141-
"fileLoggingMode": {
142-
"description": "Value determining what level of file logging is enabled.",
143-
"enum": [ "never", "always", "debugOnly" ],
144-
"default": "debugOnly"
145-
}
146-
}
147-
},
148-
149-
"singleton": {
150-
"description": "Configuration settings for Singleton lock behavior.",
151-
"type": "object",
152-
153-
"properties": {
154-
"lockPeriod": {
155-
"description": "The period that function level locks are taken for (they will auto renew).",
156-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
157-
"default": "00:00:15"
62+
"queues": {
63+
"description": "Configuration settings for 'queue' triggers.",
64+
"type": "object",
65+
66+
"properties": {
67+
"maxPollingInterval": {
68+
"description": "The maximum interval in milliseconds between queue polls.",
69+
"type": "integer",
70+
"default": 1000
71+
},
72+
73+
"batchSize": {
74+
"description": "The number of queue messages to retrieve and process in parallel (per job function).",
75+
"type": "integer",
76+
"maximum": 32,
77+
"minimum": 1,
78+
"default": 16
79+
},
80+
81+
"maxDequeueCount": {
82+
"description": "The number of times to try processing a message before moving it to the poison queue",
83+
"type": "integer",
84+
"default": 5
85+
},
86+
87+
"newBatchThreshold": {
88+
"description": "The threshold at which a new batch of messages will be fetched. The default is batchSize/2.",
89+
"type": "integer"
90+
},
91+
92+
"visibilityTimeout": {
93+
"description": "The visibility timeout that will be applied to messages that fail processing.",
94+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
95+
"default": "00:00:00"
96+
}
97+
}
15898
},
15999

160-
"listenerLockPeriod": {
161-
"description": "The period that listener locks are taken for.",
162-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
163-
"default": "00:01:00"
100+
"serviceBus": {
101+
"description": "Configuration settings for 'serviceBus' triggers.",
102+
"type": "object",
103+
104+
"properties": {
105+
"maxConcurrentCalls": {
106+
"description": "The maximum number of concurrent calls to the callback the message pump should initiate.",
107+
"type": "integer",
108+
"default": 16
109+
},
110+
111+
"prefetchCount": {
112+
"description": "The default PrefetchCount that will be used by the underlying MessageReceiver.",
113+
"type": "integer"
114+
}
115+
}
164116
},
165117

166-
"listenerLockRecoveryPollingInterval": {
167-
"description": "The time interval used for listener lock recovery if a listener lock couldn't be acquired on startup.",
168-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
169-
"default": "00:01:00"
118+
"eventHub": {
119+
"description": "Configuration settings for 'eventHub' triggers.",
120+
"type": "object",
121+
122+
"properties": {
123+
"maxBatchSize": {
124+
"description": "The maximum event count received per receive loop.",
125+
"type": "integer",
126+
"default": 1000
127+
},
128+
129+
"prefetchCount": {
130+
"description": "The default PrefetchCount that will be used by the underlying EventProcessorHost.",
131+
"type": "integer"
132+
}
133+
}
170134
},
171135

172-
"lockAcquisitionTimeout": {
173-
"description": "The maximum amount of time the runtime will try to acquire a lock.",
174-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
175-
"default": "00:01:00"
136+
"tracing": {
137+
"description": "Configuration settings for logging/tracing behavior.",
138+
"type": "object",
139+
140+
"properties": {
141+
"consoleLevel": {
142+
"description": "The tracing level used for console logging.",
143+
"enum": [ "off", "error", "warning", "info", "verbose" ],
144+
"default": "verbose"
145+
},
146+
147+
"fileLoggingMode": {
148+
"description": "Value determining what level of file logging is enabled.",
149+
"enum": [ "never", "always", "debugOnly" ],
150+
"default": "debugOnly"
151+
}
152+
}
176153
},
177154

178-
"lockAcquisitionPollingInterval": {
179-
"description": "The interval between lock acquisition attempts.",
180-
"pattern": "^\\d\\d:\\d\\d:\\d\\d$"
155+
"singleton": {
156+
"description": "Configuration settings for Singleton lock behavior.",
157+
"type": "object",
158+
159+
"properties": {
160+
"lockPeriod": {
161+
"description": "The period that function level locks are taken for (they will auto renew).",
162+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
163+
"default": "00:00:15"
164+
},
165+
166+
"listenerLockPeriod": {
167+
"description": "The period that listener locks are taken for.",
168+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
169+
"default": "00:01:00"
170+
},
171+
172+
"listenerLockRecoveryPollingInterval": {
173+
"description": "The time interval used for listener lock recovery if a listener lock couldn't be acquired on startup.",
174+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
175+
"default": "00:01:00"
176+
},
177+
178+
"lockAcquisitionTimeout": {
179+
"description": "The maximum amount of time the runtime will try to acquire a lock.",
180+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$",
181+
"default": "00:01:00"
182+
},
183+
184+
"lockAcquisitionPollingInterval": {
185+
"description": "The interval between lock acquisition attempts.",
186+
"pattern": "^\\d\\d:\\d\\d:\\d\\d$"
187+
}
188+
}
181189
}
182-
}
183190
}
184-
}
185191
}

src/WebJobs.Script.Extensibility.NuGet/WebJobs.Script.Extensibility.nuspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<requireLicenseAcceptance>true</requireLicenseAcceptance>
1515
<tags>Microsoft Azure WebJobs Jobs Script Extensibility</tags>
1616
<dependencies>
17-
<dependency id="Microsoft.Azure.WebJobs" version="2.0.0-beta2-10477" />
17+
<dependency id="Microsoft.Azure.WebJobs" version="2.0.0-beta2-10485" />
1818
</dependencies>
1919
</metadata>
2020
</package>

src/WebJobs.Script.Extensibility/WebJobs.Script.Extensibility.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@
4343
<Private>True</Private>
4444
</Reference>
4545
<Reference Include="Microsoft.Azure.WebJobs, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
46-
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.Core.2.0.0-beta2-10477\lib\net45\Microsoft.Azure.WebJobs.dll</HintPath>
46+
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.Core.2.0.0-beta2-10485\lib\net45\Microsoft.Azure.WebJobs.dll</HintPath>
4747
<Private>True</Private>
4848
</Reference>
4949
<Reference Include="Microsoft.Azure.WebJobs.Host, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
50-
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.2.0.0-beta2-10477\lib\net45\Microsoft.Azure.WebJobs.Host.dll</HintPath>
50+
<HintPath>..\..\packages\Microsoft.Azure.WebJobs.2.0.0-beta2-10485\lib\net45\Microsoft.Azure.WebJobs.Host.dll</HintPath>
5151
<Private>True</Private>
5252
</Reference>
5353
<Reference Include="Microsoft.Bot.Connector.DirectLine, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">

0 commit comments

Comments
 (0)