Azure Container Apps Revision Changes Not Propagating to Default Application URL

mardahacker 0 Reputation points
2024-12-24T06:45:18.7+00:00

I have recently launched an azure container app. I have done this by packaging a jar file with maven, and then deployed it through az containerapp up, as shown in the following article:

https://learn.microsoft.com/en-us/azure/container-apps/deploy-artifact?tabs=bash

Now, I want to make changes to the application as I continue to develop it. I have done so by again using the same CLI "up" command, simply using a new repackaged jar file. Everything shows as if it has deployed properly, and it shows up as a new revision. The revision-specific link works, and will direct me to the new version of the application. However, no matter how many times I do this, the changes do not propagate to the default URL for the container app. The main URL of the container app continues to show the original application, while I need the new one to show up. I do not know at all why this is happening and am very stuck. No errors are popping up.

Azure Container Apps
Azure Container Apps
An Azure service that provides a general-purpose, serverless container platform.
486 questions
Azure Spring Apps
Azure Spring Apps
An Azure platform as a service for running Spring Boot applications at cloud scale. Previously known as Azure Spring Cloud.
130 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sina Salam 14,551 Reputation points
    2024-12-24T13:21:40.28+00:00

    Hello mardahacker,

    Welcome to the Microsoft Q&A and thank you for posting your questions here.

    I understand that you are having issue Azure Container Apps Revision Changes Not Propagating to Default Application URL.

    Firstly, try to understand that Azure Container Apps do not automatically switch traffic to a new revision unless explicitly configured to do so. The best thing you can do is to manually or automatically update traffic settings to point to the latest revision after each deployment.

    # Update Traffic to Point to the Latest Revision:
    # Use the following command to inspect the current traffic distribution among revisions:
        az containerapp ingress traffic show --name <app-name> --resource-group <resource-group>
    
    # Set Traffic to the Latest Revision by identify the latest revision's name (visible in the above command) and update the traffic to route 100% to this revision:
     az containerapp ingress traffic set --name <app-name> --resource-group <resource-group> --revision-weight <latest-revision-name>=100
    
    # Set Revision Mode to Single (Optional) If you want to simplify management and ensure only one revision is active at any time:
       az containerapp update --name <app-name> --resource-group <resource-group> --revision-mode Single
    
    

    After updating the traffic, test the default URL again. It should now reflect the latest application changes.

    NOTE: If you are using automation tools or CI/CD pipelines, you might NEED to incorporate traffic management commands directly into deployment scripts.

    If the above steps don't resolve the issue, review the detailed documentation on Azure Container Apps revisions. - https://learn.microsoft.com/en-us/azure/container-apps/revisions and ingress configuration. - https://learn.microsoft.com/en-us/azure/container-apps/ingress-how-to

    I hope this is helpful! Do not hesitate to let me know if you have any other questions.


    Please don't forget to close up the thread here by upvoting and accept it as an answer if it is helpful.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.