flutterisbae
flutterisbae

Reputation: 345

Azure App Service Log Stream - Indefinite 'Welcome, you are now connected to log-streaming service'

Has anyone had an issue with the Log Streams in Azure where the message 'Welcome, you are now connected to log-streaming service.' is just spammed 10 times a second constantly? I am unable to see my logs now.

2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:40  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:39  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:38  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:37  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:36  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:36  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:36  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.
2022-07-07T12:48:35  Welcome, you are now connected to log-streaming service.

Upvotes: 3

Views: 1609

Answers (2)

Ben Davis
Ben Davis

Reputation: 13810

Apparently you have to actually hit your website's URL in order to trigger a re-start. Simply pressing restart or stopping and starting the app does nothing.

Upvotes: 2

mdworld
mdworld

Reputation: 83

In my experience, this happens when the app is hanging in the start phase. Below some information about how I tackled this problem.

I had the same issue. In fact not only do I have this issue in the Log Stream view, but when I run az webapp log tail I get a Python error relating to azure-cli, with urllib3.exceptions.ProtocolError: ("Connection broken: InvalidChunkLength in it.

I debugged it by:

  • stripping my NodeJS app down to a "Hello, World" express app.
  • deploying
  • Log Streams loops like in the question
  • calling the test endpoint until I get a response
  • now Log Streams logs something useful

To be complete, this post describes a way to try to fix it by changing the logging settings: https://learn.microsoft.com/en-us/answers/questions/918228/app-service-log-stream-prints-the-welcome-message.html

The exact steps I tried from this post:

  • restarting the app
  • under monitoring > App Service Logs, disable logs and set retention to 0 and back
  • restarting the app again
  • repeating the last two steps several times

It had no effect. I expect these steps can help for some people because it takes enough time for the app to get out of the warm-up phase.

Deploying under different app names/resource groups also did not help for me, which in my opinion indicates that the problem lies with the code, not the environment.

Upvotes: 1

Related Questions