Open mdevan opened 3 years ago
The columns port and local_port are declared as integers in the console commands "show servers" and "show clients". See:
port
local_port
https://github.com/yandex/odyssey/blob/master/sources/console.c#L1040
https://github.com/yandex/odyssey/blob/master/sources/console.c#L1192
but they can return a string sometimes: <unix socket>
<unix socket>
This confuses the database driver (at least Golang lib/pq) which tries to parse it as an integer.
The port should be a valid number, even for unix sockets, as it is relevant for Postgres.
Thanks for reporting this! Probably, we need a fallback for unix socket here https://github.com/yandex/odyssey/blob/master/sources/console.c#L966
The columns
port
andlocal_port
are declared as integers in the console commands "show servers" and "show clients". See:https://github.com/yandex/odyssey/blob/master/sources/console.c#L1040
https://github.com/yandex/odyssey/blob/master/sources/console.c#L1192
but they can return a string sometimes:
<unix socket>
This confuses the database driver (at least Golang lib/pq) which tries to parse it as an integer.
The port should be a valid number, even for unix sockets, as it is relevant for Postgres.