forked from agroal/pgagroal
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[agroal#335] Disambiguate connection errors from data errors in commands
This commit introduces a few constants to indicate if the communication over the management socket has failed due to a connection error or because the data received is not valid. So far, only `config-get` returns a different value to indicate invalid data over the socket, but other commands can take advanatge of this too. The `pgagroal-cli` main loop has been refactored to distinguish the new cases, and now it prints the "connection error" message only when the low level function reports such an error. All the functions now return a specific value among those defined. Close agroal#335
- Loading branch information
Showing
3 changed files
with
59 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters