question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Language worker "User" logs are ignored after execution is complete

See original GitHub issue

Back when @yojagad added a LogCategory for language workers to pass either System or User in this PR to the node worker, @pragnagopa said

With in the execution context, we should not be logging system logs

However, some of the logs in question are like this:

Error: ‘done’ has already been called. Please check your script for extraneous calls to ‘done’.

Which actually happens after execution completes. As of today, those logs are silently ignored by the host here (nothing in app insights, nothing in the console, etc.). Which leads me to a few questions:

  • What exactly is the difference between System and User logs? (We might want to document in the protobuf definition)
  • How should language workers categorize logs that are related to an execution, but after an execution?
  • Should the host really be ignoring these logs? These logs could be coming directly from the user, and perhaps they don’t realize they log after execution completes because they never see the logs.

cc @alrod

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
ejizbacommented, Mar 10, 2022

Logs between invocation request and invocation complete should be considered user logs

If the language worker is crafting the message itself, can’t we consider it system logs regardless of when it happens? There’s no risk of PII as long as it’s a simple hard-coded string, which is why I assume it’s okay for the host to write system logs during this time. Having those worker logs in our telemetry would be very helpful for supportability of language workers.

0reactions
fabiocavcommented, Jun 29, 2022

@AnatoliB it would be good to sync on this to make sure we’re not duplicating anything you’re already planning for this area.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Azure Function Node.js Failed to start a new language ...
After digging into the kudu logs, I found the following - Failed to start a new language worker for runtime: node. Microsoft.Azure.WebJobs.
Read more >
Configure monitoring for Azure Functions
Learn how to connect your function app to Application Insights for monitoring and how to configure data collection.
Read more >
App settings reference for Azure Functions
Reference documentation for the Azure Functions app settings or environment variables used to configure functions apps.
Read more >
Log4j2 Example Tutorial - Configuration, Levels, Appenders
Log4j2 implementation assumes that there is a System variable called log4j.configurationFile to point the location of log4j2 configuration file.
Read more >
Solving Your Logging Problems with Logback
In this post, we'll outline its features and how to use it to its full potential. Logback's Core Features & Advantages. faster execution...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found