log_min_messages shows debug instead of debug2 - Mailing list pgsql-hackers

From Ideriha, Takeshi
Subject log_min_messages shows debug instead of debug2
Date
Msg-id 4E72940DA2BF16479384A86D54D0988A5678EC03@G01JPEXMBKW04
Whole thread Raw
Responses Re: log_min_messages shows debug instead of debug2
List pgsql-hackers

Hi,

 

I noticed that if log_min_messages is set to ‘debug2’, it shows ‘debug’ instead of debug2.

Showing other debug options like debug1 work normally.

This is same for client_min_messages.

 

According to a033daf56 and baaad2330, debug is an alias for debug2 and for backward-compatibility.

And also these debug options are mainly used for PostgreSQL hackers, so I think this is a trivial issue.

 

Patch attached.

The output of ‘show log_min_messages’ becomes ‘debug2’ if it’s set to either debug or debug2.

It passed make installcheck.

 

I just changed the order of server_message_level_options[]

because in this case SHOW command linearly searches GUC option by config_enum_lookup_by_value().

 

What do you think about it?

If it’s worth committing, do I need test? I couldn’t find the relevant test set.

 

====================

Takeshi Ideriha

Fujitsu Limited

 

Attachment

pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: Postgres 11 release notes
Next
From: Dmitry Dolgov
Date:
Subject: Re: libpq compression