schema-registry icon indicating copy to clipboard operation
schema-registry copied to clipboard

All errors should be logged

Open mausch opened this issue 4 years ago • 9 comments

The title might seem a bit vague but I don't know how to describe it any better tbh :-)

Anyway this is what happened: I got some 500 responses from the schema registry and all I could see in the logs was :

[2020-04-02 16:03:35,048] INFO 100.96.14.58 - - [02/Apr/2020:16:03:34 +0000] "PUT /config/some-topic-value HTTP/1.1" 500 69  502 (io.confluent.rest-utils.requests)

The logs did not have any stack trace or anything pointing to what caused the error, so there's nothing I can do to start investigating its cause. All errors should be logged with a stack trace, do you agree? I'm on version 5.3.3, deployed with the helm chart.

mausch avatar Apr 02 '20 17:04 mausch

500 is an internal server error. It's bad practice to return internal errors to clients.

OneCricketeer avatar Apr 06 '20 21:04 OneCricketeer

@OneCricketeer Yes, but it's good practise to log them.

haf avatar Oct 25 '20 13:10 haf

How do we know they aren't? Has trace logging been enabled?

OneCricketeer avatar Oct 25 '20 14:10 OneCricketeer

Errors are not trace level logs. They are error level logs.

haf avatar Oct 25 '20 15:10 haf

@mausch - do you have steps to reproduce issue? As in I know you got 500 error so exact steps might not be available but just wondering what was your case when you got 500?

dhruv-bansal avatar May 15 '24 03:05 dhruv-bansal

@dhruv-bansal You know this a four year old thread, right?

haf avatar May 15 '24 12:05 haf

If nothing has been done about this explicitly then most likely this is still an issue. This doesn't really need steps to reproduce, it's not a specific bug. It just needs someone to review the code to ensure that errors get logged appropriately.

mausch avatar May 15 '24 13:05 mausch

@dhruv-bansal You know this a four year old thread, right?

@haf - yes I can see that, but it is still open, right?

dhruv-bansal avatar May 15 '24 13:05 dhruv-bansal

If nothing has been done about this explicitly then most likely this is still an issue. This doesn't really need steps to reproduce, it's not a specific bug. It just needs someone to review the code to ensure that errors get logged appropriately.

yes thats what I thought @mausch .. but thanks for the quick update.

@tusharnt - with all these inputs do you still think the good first issue is a write label for this issue?

dhruv-bansal avatar May 15 '24 21:05 dhruv-bansal