Skip to content

Commit f066eee

Browse files
committed
Update function gradle document
1 parent f921d73 commit f066eee

File tree

2 files changed

+9
-8
lines changed

2 files changed

+9
-8
lines changed

articles/azure-functions/functions-create-first-java-gradle.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ Open `build.gradle` and change the `appName` in the following section to a uniqu
4242
```gradle
4343
azurefunctions {
4444
resourceGroup = 'java-functions-group'
45-
appName = 'azure-functions-sample-demo'
45+
appName = 'azure-functions-sample-doc'
4646
pricingTier = 'Consumption'
4747
region = 'westus'
4848
runtime {
@@ -88,10 +88,11 @@ curl -w "\n" http://localhost:7071/api/HttpExample --data AzureFunctions
8888
The expected output is the following:
8989

9090
<pre>
91-
Hello AzureFunctions!
91+
Hello, AzureFunctions
9292
</pre>
9393

94-
The [function key](functions-bindings-http-webhook-trigger.md#authorization-keys) isn't required when running locally.
94+
> Note: If you set authLevel to `FUNCTION` or `ADMIN`, the [function key](functions-bindings-http-webhook-trigger.md#authorization-keys) isn't required when running locally.
95+
9596
Use `Ctrl+C` in the terminal to stop the function code.
9697

9798
> [!div class="nextstepaction"]
@@ -123,7 +124,7 @@ This creates the following resources in Azure, based on the values in the build.
123124

124125
The deployment also packages the project files and deploys them to the new function app using [zip deployment](functions-deployment-technologies.md#zip-deploy), with run-from-package mode enabled.
125126

126-
Because the HTTP trigger we published uses `authLevel = AuthorizationLevel.FUNCTION`, you need to get the function key to call the function endpoint over HTTP. The easiest way to get the function key is from the [Azure portal].
127+
The authLevel for HTTP Trigger in sample proejct is `ANONYMOUS`, which will skip the authentication. However, if you uses other authLevel like `FUNCTION` or `ADMIN`, you need to get the function key to call the function endpoint over HTTP. The easiest way to get the function key is from the [Azure portal].
127128

128129
> [!div class="nextstepaction"]
129130
> [I ran into an issue](https://www.research.net/r/javae2e?tutorial=functions-maven-quickstart&step=deploy)
@@ -134,9 +135,9 @@ You can get the URL required to trigger your function, with the function key, fr
134135

135136
1. Browse to the [Azure portal], sign in, type the _appName_ of your function app into **Search** at the top of the page, and press enter.
136137

137-
1. In your function app, expand **Functions (Read Only)**, choose your function, then select **</> Get function URL** at the top right.
138+
1. In your function app, set **Functions**, choose your function, then click **</> Get Function Url** at the top right.
138139

139-
![Copy the function URL from the Azure portal](./media/functions-create-java-maven/get-function-url-portal.png)
140+
:::image type="content" source="./media/functions-create-first-java-gradle/get-function-url-portal.png" alt-text="Copy the function URL from the Azure portal":::
140141

141142
1. Choose **default (Function key)** and select **Copy**.
142143

@@ -147,13 +148,13 @@ You can now use the copied URL to access your function.
147148
To verify the function app running on Azure using `cURL`, replace the URL from the sample below with the URL that you copied from the portal.
148149

149150
```console
150-
curl -w "\n" https://fabrikam-functions-20190929094703749.azurewebsites.net/api/HttpExample?code=zYRohsTwBlZ68YF.... --data AzureFunctions
151+
curl -w "\n" http://azure-functions-sample-doc.azurewebsites.net/api/HttpExample --data AzureFunctions
151152
```
152153

153154
This sends a POST request to the function endpoint with `AzureFunctions` in the body of the request. You see the following response.
154155

155156
<pre>
156-
Hello AzureFunctions!
157+
Hello, AzureFunctions
157158
</pre>
158159

159160
> [!div class="nextstepaction"]
15.8 KB
Loading

0 commit comments

Comments
 (0)