Skip to content

Commit cace8d1

Browse files
Rename property
- from autoRenewTimeout to maxAutoRenewDuration for v2 in functions-bindings-servicebus.md - moves v1 content into function-host-json-v1.md - deletes include file since content is no longer shared
1 parent f7f81c5 commit cace8d1

File tree

3 files changed

+41
-35
lines changed

3 files changed

+41
-35
lines changed

articles/azure-functions/functions-bindings-service-bus.md

+26-12
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ This example is for Azure Functions version 1.x. To make this code work for 2.x:
7474
- [omit the access rights parameter](#trigger---configuration)
7575
- change the type of the log parameter from `TraceWriter` to `ILogger`
7676
- change `log.Info` to `log.LogInformation`
77-
77+
7878
### Trigger - C# script example
7979

8080
The following example shows a Service Bus trigger binding in a *function.json* file and a [C# script function](functions-reference-csharp.md) that uses the binding. The function reads [message metadata](#trigger---message-metadata) and logs a Service Bus queue message.
@@ -157,7 +157,7 @@ The following Java function uses the `@ServiceBusQueueTrigger` annotation from t
157157
) {
158158
context.getLogger().info(message);
159159
}
160-
```
160+
```
161161

162162
Java functions can also be triggered when a message is added to a Service Bus topic. The following example uses the `@ServiceBusTopicTrigger` annotation to describe the trigger configuration.
163163

@@ -174,7 +174,7 @@ Java functions can also be triggered when a message is added to a Service Bus to
174174
) {
175175
context.getLogger().info(message);
176176
}
177-
```
177+
```
178178

179179
### Trigger - JavaScript example
180180

@@ -276,7 +276,7 @@ The following table explains the binding configuration properties that you set i
276276
|---------|---------|----------------------|
277277
|**type** | n/a | Must be set to "serviceBusTrigger". This property is set automatically when you create the trigger in the Azure portal.|
278278
|**direction** | n/a | Must be set to "in". This property is set automatically when you create the trigger in the Azure portal. |
279-
|**name** | n/a | The name of the variable that represents the queue or topic message in function code. Set to "$return" to reference the function return value. |
279+
|**name** | n/a | The name of the variable that represents the queue or topic message in function code. Set to "$return" to reference the function return value. |
280280
|**queueName**|**QueueName**|Name of the queue to monitor. Set only if monitoring a queue, not for a topic.
281281
|**topicName**|**TopicName**|Name of the topic to monitor. Set only if monitoring a topic, not for a queue.|
282282
|**subscriptionName**|**SubscriptionName**|Name of the subscription to monitor. Set only if monitoring a topic, not for a queue.|
@@ -337,7 +337,21 @@ See [code examples](#trigger---example) that use these properties earlier in thi
337337

338338
The [host.json](functions-host-json.md#servicebus) file contains settings that control Service Bus trigger behavior.
339339

340-
[!INCLUDE [functions-host-json-event-hubs](../../includes/functions-host-json-service-bus.md)]
340+
```json
341+
{
342+
"serviceBus": {
343+
"maxConcurrentCalls": 16,
344+
"prefetchCount": 100,
345+
"maxAutoRenewDuration": "00:05:00"
346+
}
347+
}
348+
```
349+
350+
|Property |Default | Description |
351+
|---------|---------|---------|
352+
|maxConcurrentCalls|16|The maximum number of concurrent calls to the callback that the message pump should initiate. By default, the Functions runtime processes multiple messages concurrently. To direct the runtime to process only a single queue or topic message at a time, set `maxConcurrentCalls` to 1. |
353+
|prefetchCount|n/a|The default PrefetchCount that will be used by the underlying MessageReceiver.|
354+
|maxAutoRenewDuration|00:05:00|The maximum duration within which the message lock will be renewed automatically.|
341355

342356
## Output
343357

@@ -469,7 +483,7 @@ public String pushToQueue(
469483
result.setValue(message + " has been sent.");
470484
return message;
471485
}
472-
```
486+
```
473487

474488
In the [Java functions runtime library](/java/api/overview/azure/functions/runtime), use the `@QueueOutput` annotation on function parameters whose value would be written to a Service Bus queue. The parameter type should be `OutputBinding<T>`, where T is any native Java type of a POJO.
475489

@@ -580,7 +594,7 @@ The following table explains the binding configuration properties that you set i
580594
|---------|---------|----------------------|
581595
|**type** | n/a | Must be set to "serviceBus". This property is set automatically when you create the trigger in the Azure portal.|
582596
|**direction** | n/a | Must be set to "out". This property is set automatically when you create the trigger in the Azure portal. |
583-
|**name** | n/a | The name of the variable that represents the queue or topic in function code. Set to "$return" to reference the function return value. |
597+
|**name** | n/a | The name of the variable that represents the queue or topic in function code. Set to "$return" to reference the function return value. |
584598
|**queueName**|**QueueName**|Name of the queue. Set only if sending queue messages, not for a topic.
585599
|**topicName**|**TopicName**|Name of the topic to monitor. Set only if sending topic messages, not for a queue.|
586600
|**connection**|**Connection**|The name of an app setting that contains the Service Bus connection string to use for this binding. If the app setting name begins with "AzureWebJobs", you can specify only the remainder of the name. For example, if you set `connection` to "MyServiceBus", the Functions runtime looks for an app setting that is named "AzureWebJobsMyServiceBus." If you leave `connection` empty, the Functions runtime uses the default Service Bus connection string in the app setting that is named "AzureWebJobsServiceBus".<br><br>To obtain a connection string, follow the steps shown at [Get the management credentials](../service-bus-messaging/service-bus-dotnet-get-started-with-queues.md#get-the-connection-string). The connection string must be for a Service Bus namespace, not limited to a specific queue or topic.|
@@ -639,11 +653,11 @@ This section describes the global configuration settings available for this bind
639653
```
640654

641655
|Property |Default | Description |
642-
|---------|---------|---------|
643-
|maxAutoRenewDuration|00:05:00|The maximum duration within which the message lock will be renewed automatically.|
644-
|autoComplete|true|Whether the trigger should immediately mark as complete (autocomplete) or wait for processing to call complete.|
645-
|maxConcurrentCalls|16|The maximum number of concurrent calls to the callback that the message pump should initiate. By default, the Functions runtime processes multiple messages concurrently. To direct the runtime to process only a single queue or topic message at a time, set `maxConcurrentCalls` to 1. |
646-
|prefetchCount|n/a|The default PrefetchCount that will be used by the underlying MessageReceiver.|
656+
|---------|---------|---------|
657+
|maxAutoRenewDuration|00:05:00|The maximum duration within which the message lock will be renewed automatically.|
658+
|autoComplete|true|Whether the trigger should immediately mark as complete (autocomplete) or wait for processing to call complete.|
659+
|maxConcurrentCalls|16|The maximum number of concurrent calls to the callback that the message pump should initiate. By default, the Functions runtime processes multiple messages concurrently. To direct the runtime to process only a single queue or topic message at a time, set `maxConcurrentCalls` to 1. |
660+
|prefetchCount|n/a|The default PrefetchCount that will be used by the underlying MessageReceiver.|
647661

648662

649663
## Next steps

articles/azure-functions/functions-host-json-v1.md

+15-1
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,21 @@ Configuration settings for [Storage queue triggers and bindings](functions-bindi
239239

240240
Configuration setting for [Service Bus triggers and bindings](functions-bindings-service-bus.md).
241241

242-
[!INCLUDE [functions-host-json-service-bus](../../includes/functions-host-json-service-bus.md)]
242+
```json
243+
{
244+
"serviceBus": {
245+
"maxConcurrentCalls": 16,
246+
"prefetchCount": 100,
247+
"autoRenewTimeout": "00:05:00"
248+
}
249+
}
250+
```
251+
252+
|Property |Default | Description |
253+
|---------|---------|---------|
254+
|maxConcurrentCalls|16|The maximum number of concurrent calls to the callback that the message pump should initiate. By default, the Functions runtime processes multiple messages concurrently. To direct the runtime to process only a single queue or topic message at a time, set `maxConcurrentCalls` to 1. |
255+
|prefetchCount|n/a|The default PrefetchCount that will be used by the underlying MessageReceiver.|
256+
|autoRenewTimeout|00:05:00|The maximum duration within which the message lock will be renewed automatically.|
243257

244258
## singleton
245259

includes/functions-host-json-service-bus.md

-22
This file was deleted.

0 commit comments

Comments
 (0)