Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow Java loggers outputs to be displayed in the function instance console log #10485

Open
anotherRedbeard opened this issue Sep 19, 2024 · 0 comments

Comments

@anotherRedbeard
Copy link

What problem would the feature you're requesting solve? Please describe.

I have created a Java function app using the VSCode template for a Queue Based Trigger and we use Logback to handle all of our logging. I followed this doc to set this up. This seems to log things to the console as expected when running locally; however, when I push this to an Azure Function these logs don't show up in the Function Instance log. The do show up in the Function App Host Log Stream but there is a lot of noise there they I have to filter through. I have enabled distributed tracing so it seems to tie the invocationId to each log in the traces table in app insights, but they don't seem to be showing up in the log stream.

Describe the solution you'd like

I'd like to be able to see these logs in the Function Instance Log Stream so I can get a real-time view of what is going on with my function instance.

Describe alternatives you've considered

I could get these logs from the function host log, but there is too much noise to filter out. I can also get these logs from the traces table in application insights, but I have to wait on the delay before they get out there.

Additional context

I've setup an example where I've used the default logger and my logback logger to see if I could tell the difference between the logs. From an App Insight perspective these appear the same having all of the properties I would expect. When I do a network trace and watch the queryLogs api calls I can see the log in the payload, but it is missing the Content.OperationName and in the Content.Properties array isn't missing the InvocationId key.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants