-
Notifications
You must be signed in to change notification settings - Fork 0
introduce 'log_connection_messages' GUC setting #7
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
base: master
Are you sure you want to change the base?
Conversation
355a9f6
to
471f295
Compare
src/backend/commands/variable.c
Outdated
|
||
*extra = (void *) myextra; | ||
|
||
if (log_connection_messages == NULL || log_connection_messages[0] == '\0') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SplitIdentifierString
already considers empty strings as ok, can't we get rid of this string?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've decided to keep it for now for the sake of being explicit in the code
+ tests should be extended to check the new GUC values, I guess |
yes, but let's wait with that untl the 1st round of feedback from the community |
471f295
to
7531ac9
Compare
0a20d43
to
2dca2c6
Compare
aea7a4c
to
efafdb4
Compare
b85e0e4
to
4bf99bc
Compare
what's about https://github.com/sdudoladov/postgres/blob/make-logging-connections-fine-grained/src/backend/utils/misc/guc_tables.c#L90? |
if (pg_strcasecmp(*newval, "all") == 0) | ||
{ | ||
newlogconnect |= LOG_CONNECTION_ALL; | ||
myextra = (int *) guc_malloc(ERROR, sizeof(int)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't we check if myextra
is NULL
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
obviously not. Thank you ! |
This patch removes 'log_connections' and 'log_disconnections' in favor of 'log_connection_messages', thereby introducing incompatibility Author: Sergey Dudoladov Reviewed-by: Justin Pryzby Discussion: https://www.postgresql.org/message-id/flat/CAA8Fd-qCB96uwfgMKrzfNs32mqqysi53yZFNVaRNJ6xDthZEgA%40mail.gmail.com
4bf99bc
to
49a2ea5
Compare
this patch removes 'log_connections' and 'log_disconnections' in favor
of 'log_connection_messages', thereby introducing incompatibility
Author: Sergey Dudoladov
Reviewed-by:
Discussion:
https://www.postgresql.org/message-id/flat/CAA8Fd-qCB96uwfgMKrzfNs32mqqysi53yZFNVaRNJ6xDthZEgA%40mail.gmail.com