I'm still struggling with this issue and did not found the solution yet. I use wildfly10 for deploying javaee application to k8s everything is okie but one problem about logging level.
When exception happend the stackdriver show log like the following picture.
As you can see in that picture it throw error exception but the icon is still info.
Anyone has idea how to overcome this or workaround? Thank you very much
Your logs are not being identified correctly that's why !!
is not showing and you are getting Information
icon instead.
Error is shown if LogEntry.severity
has value of ERROR
(which is provided by the client that wrote the entry). Entries that land in Error Reporting need to meet a few other criteria: https://cloud.google.com/error-reporting/docs/formatting-error-messages
You should check Reviewing logs with the Cloud Logging Logs Viewer Beta and Setting Up Error Reporting for Java.
You can also take advantage of Advanced logs queries.
An advanced logs query is a Boolean expression that specifies a subset of all the log entries in your project. It can be used to do any of the following:
- Choose log entries from specific logs or log services.
- Choose log entries within a time range.
- Choose log entries that satisfy conditions on metadata or user-defined fields.
- Choose a sampling percentage of all log entries.