Skip to content

Commit d7fdff8

Browse files
committed
Fix code fences and highlight ranges
1 parent 69140cb commit d7fdff8

File tree

2 files changed

+12
-12
lines changed

2 files changed

+12
-12
lines changed

articles/azure-functions/functions-add-output-binding-storage-queue-python.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,15 @@ Although a function can have only one trigger, it can have multiple input and ou
3434
3535
From the previous quickstart, your *function.json* file in the *HttpExample* folder contains two bindings in the `bindings` collection:
3636
37-
:::code language="python" source="snippets/http-trigger-basics.md" range="90-109":::
37+
:::code language="json" source="snippets/http-trigger-basics.md" range="90-109":::
3838
3939
Each binding has at least a type, a direction, and a name. In the example above, the first binding is of type `httpTrigger` with the direction `in`. For the `in` direction, `name` specifies the name of an input parameter that's sent to the function when invoked by the trigger.
4040
4141
The second binding is of type `http` with the direction `out`, in which case the special `name` of `$return` indicates that this binding uses the function's return value rather than providing an input parameter.
4242
4343
To write to an Azure Storage queue from this function, add an `out` binding of type `queue` with the name `msg`, as shown in the code below:
4444
45-
:::code language="python" source="snippets/storage-binding-use-queue.md" range="178-204" highlight="195-202":::
45+
:::code language="json" source="snippets/storage-binding-use-queue.md" range="178-204" highlight="18-25":::
4646
4747
In this case, `msg` is given to the function as an output argument. For a `queue` type, you must also specify the name of the queue in `queueName` and provide the *name* of the Azure Storage connection (from *local.settings.json*) in `connection`.
4848
@@ -54,7 +54,7 @@ With the queue binding specified in *function.json*, you can now update your fun
5454
5555
Update *HttpExample\\\_\_init\_\_.py* to match the following code, adding the `msg` parameter to the function definition and `msg.set(name)` under the `if name:` statement.
5656
57-
:::code language="python" source="snippets/storage-binding-use-queue.md" range="210-233" highlight="215,227":::
57+
:::code language="python" source="snippets/storage-binding-use-queue.md" range="210-233" highlight="6,18":::
5858
5959
The `msg` parameter is an instance of the [`azure.functions.InputStream class`](/python/api/azure-functions/azure.functions.httprequest). Its `set` method writes a string message to the queue, in this case the name passed to the function in the URL query string.
6060

articles/azure-functions/functions-create-function-linux-custom-image.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -556,31 +556,31 @@ The `msg` parameter is an `ICollector<T>` type, which represents a collection of
556556
557557
Update *function.json* to match the following by adding the queue binding:
558558
559-
:::code language="json" source="snippets/storage-binding-use-queue.md" range="51-76" highlight="67-74":::
559+
:::code language="json" source="snippets/storage-binding-use-queue.md" range="51-76" highlight="17-24":::
560560
561561
::: zone-end
562562
563563
::: zone pivot="programming-language-powershell"
564564
565565
Update *function.json* to match the following by adding the queue binding:
566566
567-
:::code language="json" source="snippets/storage-binding-use-queue.md" range="109-134" highlight="125-132":::
567+
:::code language="json" source="snippets/storage-binding-use-queue.md" range="109-134" highlight="17-24":::
568568
569569
::: zone-end
570570
571571
::: zone pivot="programming-language-python"
572572
573573
Update *function.json* to match the following by adding the queue binding:
574574
575-
:::code language="json" source="snippets/storage-binding-use-queue.md" range="178-204" highlight="195-202":::
575+
:::code language="json" source="snippets/storage-binding-use-queue.md" range="178-204" highlight="18-25":::
576576
577577
::: zone-end
578578
579579
::: zone pivot="programming-language-typescript"
580580
581581
Update *function.json* to match the following by adding the queue binding:
582582
583-
:::code language="json" source="snippets/storage-binding-use-queue.md" range="241-266" highlight="257-264":::
583+
:::code language="json" source="snippets/storage-binding-use-queue.md" range="241-266" highlight="17-24":::
584584
585585
::: zone-end
586586
@@ -589,23 +589,23 @@ Update *function.json* to match the following by adding the queue binding:
589589
After the binding is defined, the name of the binding, in this case `msg`, appears in the function code as an argument (or in the `context` object in JavaScript and TypeScript). You can then use that variable to write messages to the queue. You need to write any code for authentication, getting a queue reference, or writing data. All these integration tasks are conveniently handled in the Azure Functions runtime and queue output binding.
590590
591591
::: zone pivot="programming-language-csharp"
592-
:::code language="cs" source="snippets/storage-binding-use-queue.md" range="21-43" highlight="24,34-38":::
592+
:::code language="cs" source="snippets/storage-binding-use-queue.md" range="21-43" highlight="4,14-18":::
593593
::: zone-end
594594
595595
::: zone pivot="programming-language-javascript"
596-
:::code language="javascript" source="snippets/storage-binding-use-queue.md" range="82-101" highlight="86-88":::
596+
:::code language="javascript" source="snippets/storage-binding-use-queue.md" range="82-101" highlight="5-7":::
597597
::: zone-end
598598
599599
::: zone pivot="programming-language-powershell"
600-
:::code language="powershell" source="snippets/storage-binding-use-queue.md" range="140-170" highlight="155-156":::
600+
:::code language="powershell" source="snippets/storage-binding-use-queue.md" range="140-170" highlight="16-17":::
601601
::: zone-end
602602
603603
::: zone pivot="programming-language-python"
604-
:::code language="python" source="snippets/storage-binding-use-queue.md" range="210-233" highlight="215,227":::
604+
:::code language="python" source="snippets/storage-binding-use-queue.md" range="210-233" highlight="6,18":::
605605
::: zone-end
606606
607607
::: zone pivot="programming-language-typescript"
608-
:::code language="typescript" source="snippets/storage-binding-use-queue.md" range="272-296" highlight="279-281":::
608+
:::code language="typescript" source="snippets/storage-binding-use-queue.md" range="272-296" highlight="8-10":::
609609
::: zone-end
610610
611611
### Update the image in the registry

0 commit comments

Comments
 (0)