You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`X-MS-CLIENT-PRINCIPAL`| A Base64 encoded JSON representation of available claims. For more information, see [Decoding the client principal header](#decoding-the-client-principal-header). |
22
22
|`X-MS-CLIENT-PRINCIPAL-ID`| An identifier for the caller set by the identity provider. |
23
-
|`X-MS-CLIENT-PRINCIPAL-NAME`| A human-readable name for the caller set by the identity provider, e.g. Email Address, User Principal Name. |
23
+
|`X-MS-CLIENT-PRINCIPAL-NAME`| A human-readable name for the caller set by the identity provider, such as email address or user principal name. |
24
24
|`X-MS-CLIENT-PRINCIPAL-IDP`| The name of the identity provider used by App Service Authentication. |
25
25
26
26
Provider tokens are also exposed through similar headers. For example, Microsoft Entra also sets `X-MS-TOKEN-AAD-ACCESS-TOKEN` and `X-MS-TOKEN-AAD-ID-TOKEN` as appropriate.
27
27
28
28
> [!NOTE]
29
-
> Different language frameworks may present these headers to the app code in different formats, such as lowercase or title case.
29
+
> Different language frameworks might present these headers to the app code in different formats, such as lowercase or title case.
30
30
31
-
Code that is written in any language or framework can get the information that it needs from these headers. [Decoding the client principal header](#decoding-the-client-principal-header) covers this process. For some frameworks, the platform also provides extra options that may be more convenient.
31
+
Code that is written in any language or framework can get the information that it needs from these headers. [Decoding the client principal header](#decoding-the-client-principal-header) covers this process. For some frameworks, the platform also provides extra options that might be more convenient.
32
32
33
33
### Decoding the client principal header
34
34
35
-
`X-MS-CLIENT-PRINCIPAL` contains the full set of available claims as Base64 encoded JSON. These claims go through a default claims-mapping process, so some may have different names than you would see if processing the token directly. The decoded payload is structured as follows:
35
+
`X-MS-CLIENT-PRINCIPAL` contains the full set of available claims as Base64 encoded JSON. These claims go through a default claims-mapping process, so some might have different names than you would see if processing the token directly. The decoded payload is structured as follows:
36
36
37
37
```json
38
38
{
@@ -52,12 +52,12 @@ Code that is written in any language or framework can get the information that i
|`auth_typ`| string | The name of the identity provider used by App Service Authentication. |
54
54
|`claims`| array of objects | An array of objects representing the available claims. Each object contains `typ` and `val` properties. |
55
-
|`typ`| string | The name of the claim. This may have been subject to default claims mapping and could be different from the corresponding claim contained in a token. |
55
+
|`typ`| string | The name of the claim. It might be subject to default claims mapping and could be different from the corresponding claim contained in a token. |
56
56
|`val`| string | The value of the claim. |
57
57
|`name_typ`| string | The name claim type, which is typically a URI providing scheme information about the `name` claim if one is defined. |
58
58
|`role_typ`| string | The role claim type, which is typically a URI providing scheme information about the `role` claim if one is defined. |
59
59
60
-
To process this header, your app will need to decode the payload and iterate through the `claims` array to find the claims of interest. It may be convenient to convert these into a representation used by the app's language framework. Here's an example of this process in C# that constructs a [ClaimsPrincipal](/dotnet/api/system.security.claims.claimsprincipal) type for the app to use:
60
+
To process this header, your app needs to decode the payload and iterate through the `claims` array to find the claims of interest. It it be convenient to convert them into a representation used by the app's language framework. Here's an example of this process in C# that constructs a [ClaimsPrincipal](/dotnet/api/system.security.claims.claimsprincipal) type for the app to use:
Copy file name to clipboardExpand all lines: articles/app-service/configure-language-java-apm.md
+11-7Lines changed: 11 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -99,7 +99,7 @@ To enable via the Azure CLI, you need to create an Application Insights resource
99
99
100
100
1. Create a NewRelic account at [NewRelic.com](https://newrelic.com/signup)
101
101
2. Download the Java agent from NewRelic. It has a file name similar to *newrelic-java-x.x.x.zip*.
102
-
3. Copy your license key, you'll need it to configure the agent later.
102
+
3. Copy your license key, you need it to configure the agent later.
103
103
4. [SSH into your App Service instance](configure-linux-open-ssh-session.md) and create a new directory */home/site/wwwroot/apm*.
104
104
5. Upload the unpacked NewRelic Java agent files into a directory under */home/site/wwwroot/apm*. The files for your agent should be in */home/site/wwwroot/apm/newrelic*.
105
105
6. Modify the YAML file at */home/site/wwwroot/apm/newrelic/newrelic.yml* and replace the placeholder license value with your own license key.
@@ -187,18 +187,22 @@ To enable via the Azure CLI, you need to create an Application Insights resource
187
187
## Configure Datadog
188
188
189
189
# [Windows](#tab/windows)
190
-
* The configuration options are different depending on which Datadog site your organization is using. Therefore please reference and follow the steps here in the official [Datadog Integration for Azure Documentation](https://docs.datadoghq.com/integrations/azure/)
190
+
* The configuration options are different depending on which Datadog site your organization is using. See the official [Datadog Integration for Azure Documentation](https://docs.datadoghq.com/integrations/azure/)
191
+
192
+
# [Linux](#tab/linux)
193
+
* The configuration options are different depending on which Datadog site your organization is using. See the official [Datadog Integration for Azure Documentation](https://docs.datadoghq.com/integrations/azure/)
191
194
192
-
# [Linux](#tab/windows)
193
-
* The configuration options are different depending on which Datadog site your organization is using. Therefore please reference and follow the steps here in the official [Datadog Integration for Azure Documentation](https://docs.datadoghq.com/integrations/azure/)
195
+
---
194
196
195
197
## Configure Dynatrace
196
198
197
199
# [Windows](#tab/windows)
198
-
* Dynatrace provides an [Azure Native Dynatrace Service](https://www.dynatrace.com/monitoring/technologies/azure-monitoring/). To monitor Azure App Services using Dynatrace, please follow the steps in the official [Dynatrace for Azure documentation](https://docs.datadoghq.com/integrations/azure/)
200
+
* Dynatrace provides an [Azure Native Dynatrace Service](https://www.dynatrace.com/monitoring/technologies/azure-monitoring/). To monitor Azure App Services using Dynatrace, see the official [Dynatrace for Azure documentation](https://docs.datadoghq.com/integrations/azure/)
199
201
200
-
# [Linux](#tab/windows)
201
-
* Dynatrace provides an [Azure Native Dynatrace Service](https://www.dynatrace.com/monitoring/technologies/azure-monitoring/). To monitor Azure App Services using Dynatrace, please follow the steps in the official [Dynatrace for Azure documentation](https://docs.datadoghq.com/integrations/azure/)
202
+
# [Linux](#tab/linux)
203
+
* Dynatrace provides an [Azure Native Dynatrace Service](https://www.dynatrace.com/monitoring/technologies/azure-monitoring/). To monitor Azure App Services using Dynatrace, see the official [Dynatrace for Azure documentation](https://docs.datadoghq.com/integrations/azure/)
<!-- #customer intent: As a developer, I want to learn how to deploy my web applications to Azure App Service so that I can take advantage of its managed platform and easily scale my applications. -->
Copy file name to clipboardExpand all lines: articles/app-service/includes/deploy-intelligent-apps/deploy-intelligent-apps-linux-java-pivot.md
+11-15Lines changed: 11 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,11 +17,7 @@ You can use Azure App Service to create applications using Azure OpenAI and Open
17
17
18
18
### Set up web app
19
19
20
-
<<<<<<< HEAD
21
-
For this Spring Boot application, we're building off the [quickstart](../../quickstart-java.md?tabs=springboot&pivots=java-maven-javase) app and adding an extra feature to make a request to an Azure OpenAI or OpenAI service. Add the following code to your application:
22
-
=======
23
20
For this Spring Boot application, we're building off the [quickstart](../../quickstart-java.md?tabs=springboot&pivots=java-javase) app and adding an extra feature to make a request to an Azure OpenAI or OpenAI service. Add the following code to your application:
24
-
>>>>>>> 186f85b0178b (acrolinx and template errors)
25
21
26
22
```bash
27
23
@RequestMapping("/")
@@ -35,9 +31,9 @@ For this Spring Boot application, we're building off the [quickstart](../../quic
35
31
36
32
### Secure your app with managed identity
37
33
38
-
Although optional, it's highly recommended to secure your application using [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. Skip this step if you are not using Azure OpenAI. This enables your application to access the Azure OpenAI resource without needing to manage API keys.
34
+
Although optional, it's highly recommended to secure your application using [managed identity](../../overview-managed-identity.md) to authenticate your app to your Azure OpenAI resource. Skip this step if you're not using Azure OpenAI. This enables your application to access the Azure OpenAI resource without needing to manage API keys.
39
35
40
-
Follow the steps below to secure your application:
36
+
To secure your application:
41
37
42
38
Add the Azure OpenAI dependency package. This package enables using Azure credentials in your app.
43
39
@@ -60,16 +56,16 @@ OpenAIClient client = new OpenAIClientBuilder()
60
56
.buildClient();
61
57
```
62
58
63
-
Once the credentials are added to the application, you�ll then need to enable managed identity in your application and grant access to the resource.
59
+
Once the credentials are added to the application, you need to enable managed identity in your application and grant access to the resource.
64
60
65
-
1. In your web app resource, navigate to the **Identity** page and turn on **System assigned** and click**Save**
66
-
2. Once System assigned identity is turned on, it will register the web app with Microsoft Entra ID and the web app can be granted permissions to access protected resources.
61
+
1. In your web app resource, navigate to the **Identity** page and turn on **System assigned** and select**Save**.
62
+
2. Once System assigned identity is turned on, it registers the web app with Microsoft Entra ID and the web app can be granted permissions to access protected resources.
67
63
3. Go to your Azure OpenAI resource and navigate to the **Access control (IAM)** page on the left pane.
68
-
4. Find the Grant access to this resource card and click on **Add role assignment**
69
-
5. Search for the **Cognitive Services OpenAI User** role and click**Next**
70
-
6. On the **Members** tab, find **Assign access to** and choose the **Managed identity** option
71
-
7. Next, click on **+Select Members** and find your web app
72
-
8.Click**Review + assign**
64
+
4. Find the Grant access to this resource card and select **Add role assignment**.
65
+
5. Search for the **Cognitive Services OpenAI User** role and select**Next**.
66
+
6. On the **Members** tab, find **Assign access to** and choose the **Managed identity** option.
67
+
7. Next, select **+Select Members** and find your web app.
68
+
8.Select**Review + assign**.
73
69
74
70
Your web app is now added as a cognitive service OpenAI user and can communicate to your Azure OpenAI resource.
75
71
@@ -291,7 +287,7 @@ public class Application {
291
287
292
288
If you completed the steps above, you can deploy to App Service as you normally would. If you run into any issues, remember that you need to complete the following steps: grant your app access to your Key Vault, and add the app settings with key vault references as your values. App Service resolves the app settings in your application that match what you added in the portal.
293
289
294
-
Once the app is deployed, you can visit your site URL and you're greeted with the text that contains the response from your chat message prompt.
290
+
Once the app is deployed, you can visit your site URL and see the text that contains the response from your chat message prompt.
Copy file name to clipboardExpand all lines: articles/app-service/includes/quickstart-java/quickstart-java-linux-maven-pivot.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -58,7 +58,7 @@ mvn clean install
58
58
cd booty-duke-app-service
59
59
```
60
60
61
-
If you see a message about being in **detached HEAD** state, this message is safe to ignore. Because you will not be making any commits, detached HEAD state is appropriate.
61
+
If you see a message about being in **detached HEAD** state, this message is safe to ignore. Because you won't make any commits, detached HEAD state is appropriate.
62
62
63
63
# [Tomcat](#tab/tomcat)
64
64
@@ -94,7 +94,7 @@ cd petstore-ee7
94
94
mvn clean install
95
95
```
96
96
97
-
If you see a message about being in **detached HEAD** state, this message is safe to ignore. Because you will not be making any commits, detached HEAD state is appropriate.
97
+
If you see a message about being in **detached HEAD** state, this message is safe to ignore. Because you won't making any commits, detached HEAD state is appropriate.
98
98
99
99
---
100
100
@@ -103,7 +103,7 @@ If you see a message about being in **detached HEAD** state, this message is saf
103
103
> [!TIP]
104
104
> The Maven plugin supports **Java 17** and **Tomcat 10.0**. For more information about latest support, see [Java 17 and Tomcat 10.0 are available on Azure App Service](https://devblogs.microsoft.com/java/java-17-and-tomcat-10-0-available-on-azure-app-service/).
105
105
106
-
The deployment process to Azure App Service uses your Azure credentials from the Azure CLI automatically. If the Azure CLI isn't installed locally, then the Maven plugin authenticates with Oauth or device login. For more information, see [authentication with Maven plugins](https://github.com/microsoft/azure-maven-plugins/wiki/Authentication).
106
+
The deployment process to Azure App Service uses your Azure credentials from the Azure CLI automatically. If the Azure CLI isn't installed locally, then the Maven plugin authenticates with Oauth or device sign-in. For more information, see [authentication with Maven plugins](https://github.com/microsoft/azure-maven-plugins/wiki/Authentication).
107
107
108
108
Run the Maven command shown next to configure the deployment. This command helps you to set up the App Service operating system, Java version, and Tomcat version.
After you've confirmed your choices, the plugin adds the above plugin element and requisite settings to your project's `pom.xml` file that configure your web app to run in Azure App Service.
209
+
After you confirm your choices, the plugin adds the above plugin element and requisite settings to your project's `pom.xml` file that configure your web app to run in Azure App Service.
210
210
211
211
The relevant portion of the `pom.xml` file should look similar to the following example.
212
212
@@ -228,7 +228,7 @@ The relevant portion of the `pom.xml` file should look similar to the following
228
228
</build>
229
229
```
230
230
231
-
You can modify the configurations for App Service directly in your `pom.xml`. Some common configurations are listed below:
231
+
You can modify the configurations for App Service directly in your `pom.xml`. Some common configurations are listed in the following table:
For the complete list of configurations, see the plugin reference documentation. All the Azure Maven Plugins share a common set of configurations. For these configurations see [Common Configurations](https://github.com/microsoft/azure-maven-plugins/wiki/Common-Configuration). For configurations specific to App Service, see [Azure Web App: Configuration Details](https://github.com/microsoft/azure-maven-plugins/wiki/Azure-Web-App:-Configuration-Details).
245
245
246
-
Be careful about the values of `<appName>` and `<resourceGroup>` (`helloworld-1590394316693` and `helloworld-1590394316693-rg` accordingly in the demo), they are used later.
246
+
Be careful about the values of `<appName>` and `<resourceGroup>` (`helloworld-1590394316693` and `helloworld-1590394316693-rg` accordingly in the demo). They're used later.
247
247
248
248
## 4 - Deploy the app
249
249
@@ -282,7 +282,7 @@ Once deployment is completed, your application is ready at `http://<appName>.azu
282
282
283
283
---
284
284
285
-
**Congratulations!** You've deployed your first Java app to App Service.
285
+
**Congratulations!** You deployed your first Java app to App Service.
286
286
287
287
## 5 - Clean up resources
288
288
@@ -292,4 +292,4 @@ In the preceding steps, you created Azure resources in a resource group. If you
292
292
az group delete --name <your resource group name; for example: helloworld-1558400876966-rg> --yes
0 commit comments