|
| 1 | +--- |
| 2 | +title: How to turn on Java Stack in Azure Container Apps |
| 3 | +description: How to turn on Java Stack feature to use Java-optimized support in Azure Container Apps |
| 4 | +services: container-apps |
| 5 | +author: hangwang |
| 6 | +ms.service: azure-container-apps |
| 7 | +ms.custom: ignite-2024, devx-track-azurecli, devx-track-extended-java |
| 8 | +ms.topic: how-to |
| 9 | +ms.date: 02/27/2024 |
| 10 | +ms.author: hangwan |
| 11 | +--- |
| 12 | + |
| 13 | +# Turn on Java Features in Azure Container Apps |
| 14 | + |
| 15 | +This guide provides step-by-step instructions for enabling key Java features in Azure Container Apps. By activating these features, you can optimize your Java applications for performance, monitoring and ease of development. |
| 16 | + |
| 17 | +## Java Virtual Machine (JVM) metrics |
| 18 | +Java Virtual Machine (JVM) metrics are essential for tracking the performance and health of your Java applications. These metrics offer insights into memory consumption, garbage collection, and thread activity within the JVM. By enabling Java Metrics in Azure Container Apps, you can access these detailed metrics in Azure Monitor to optimize application performance and address potential issues proactively. |
| 19 | + |
| 20 | +::: zone pivot="azure-cli" |
| 21 | +To turn on Java Virtual Machine (JVM) metrics on CLI, refer to [Metrics Configuration on CLI](java-metrics.md?tabs=create&pivots=azure-cli#configuration). |
| 22 | + |
| 23 | +::: zone-end |
| 24 | + |
| 25 | +::: zone pivot="azure-portal" |
| 26 | +To turn on Java Virtual Machine (JVM) metrics on portal, refer to [Metrics Configuration on Portal](java-metrics.md?tabs=create&pivots=azure-portal#configuration). |
| 27 | + |
| 28 | +::: zone-end |
| 29 | + |
| 30 | +## Automatic memory fitting |
| 31 | +The JVM conservatively manages memory, but with Java automatic memory fitting, your container app can optimize usage by making more memory available, boosting performance by 10-20% without requiring code changes. |
| 32 | + |
| 33 | +Automatic memory fitting is **enabled by default**, but you can disable manually. |
| 34 | + |
| 35 | +::: zone pivot="azure-cli" |
| 36 | +To turn off Automatic memory fitting on CLI, refer to [Disable memory fitting](java-memory-fit.md?tabs=create#disable-memory-fitting). |
| 37 | + |
| 38 | +::: zone-end |
| 39 | + |
| 40 | +## Diagnostics |
| 41 | +Azure Container Apps provides a built-in diagnostics tool designed specifically for Java developers, enabling easier and more efficient debugging and troubleshooting of Java applications deployed on the platform. |
| 42 | + |
| 43 | +### Dynamic logger level |
| 44 | + |
| 45 | +::: zone pivot="azure-cli" |
| 46 | +To turn on Dynamic logger level on CLI, refer to [Enable JVM diagnostics for your Java applications](java-dynamic-log-level.md?enable-jvm-diagnostics-for-your-java-applications). |
| 47 | +::: zone-end |
| 48 | + |
| 49 | +## Spring Components |
| 50 | +Azure Container Apps supports various Spring Components as managed services, allowing you to leverage these components without deploying additional code. |
| 51 | + |
| 52 | +### Eureka Server for Spring |
| 53 | +Eureka Server for Spring is a service registry that allows microservices to register themselves and discover other services. Available as an Azure Container Apps component, you can bind your container app to a Eureka Server for Spring for automatic registration with the Eureka server. |
| 54 | + |
| 55 | +::: zone pivot="azure-cli" |
| 56 | +To use Eureka Server for Spring on CLI, refer to [Create the Eureka Server for Spring Java component on CLI](java-eureka-server.md?tabs=azure-cli#create-the-eureka-server-for-spring-java-component). |
| 57 | + |
| 58 | +::: zone-end |
| 59 | + |
| 60 | +::: zone pivot="azure-portal" |
| 61 | +To use Eureka Server for Spring on portal, refer to [Create the Eureka Server for Spring Java component on Portal](java-eureka-server.md?tabs=azure-portal#create-the-eureka-server-for-spring-java-component). |
| 62 | + |
| 63 | +::: zone-end |
| 64 | + |
| 65 | + |
| 66 | + |
| 67 | +### Config Server for Spring |
| 68 | +Config Server for Spring provides a centralized location to make configuration data available to multiple applications. |
| 69 | + |
| 70 | +::: zone pivot="azure-cli" |
| 71 | +To use Config Server for Spring on CLI, refer to [Create the Config Server for Spring Java component on CLI](java-config-server.md?tabs=azure-cli#create-the-config-server-for-spring-java-component). |
| 72 | + |
| 73 | +::: zone-end |
| 74 | + |
| 75 | +::: zone pivot="azure-portal" |
| 76 | +To use Config Server for Spring on portal, refer to [Create the Config Server for Spring Java component on Portal](java-config-server.md?tabs=azure-portal#create-the-config-server-for-spring-java-component). |
| 77 | + |
| 78 | +::: zone-end |
| 79 | + |
| 80 | + |
| 81 | +### Admin for Spring |
| 82 | +The Admin for Spring managed component offers an administrative interface for Spring Boot web applications that expose actuator endpoints. |
| 83 | + |
| 84 | +::: zone pivot="azure-cli" |
| 85 | +To use Admin for Spring on CLI, refer to [Use the componentt on CLI](java-admin?tabs=azure-cli). |
| 86 | + |
| 87 | +::: zone-end |
| 88 | + |
| 89 | +::: zone pivot="azure-portal" |
| 90 | +To use Admin for Spring on portal, refer to [Use the component on Portal](java-admin?tabs=azure-portal). |
| 91 | + |
| 92 | +::: zone-end |
| 93 | + |
| 94 | + |
| 95 | +## Next steps |
| 96 | + |
| 97 | +> [!div class="nextstepaction"] |
| 98 | +> [Launch your first Java app](java-get-started.md) |
0 commit comments