You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Prevent clients from sticking to old pools after config update (postgresml#113)
* Re-acquire pool at the beginning of Protocol loop
* Fix query router + add tests for recycling behavior
* create a prometheus exporter on a standard http port (postgresml#107)
* create a hyper server and add option to enable it in config
* move prometheus stuff to its own file; update format
* create metric type and help lookup table
* finish the metric help type map
* switch to a boolean and a standard port
* dont emit unimplemented metrics
* fail if curl returns a non 200
* resolve conflicts
* move log out of config.show and into main
* terminating new line
* upgrade curl
* include unimplemented stats
* Validates pgcat is closed after shutdown python tests (postgresml#116)
* Validates pgcat is closed after shutdown python tests
* Fix pgrep logic
* Moves sigterm step to after cleanup to decouple
* Replace subprocess with os.system for running pgcat
* fix docker compose port allocation for local dev (postgresml#117)
change docker compose port to right prometheus port
* Update CONTRIBUTING.md
* Health check delay (postgresml#118)
* initial commit of server check delay implementation
* fmt
* spelling
* Update name to last_healthcheck and some comments
* Moved server tested stat to after require_healthcheck check
* Make health check delay configurable
* Rename to last_activity
* Fix typo
* Add debug log for healthcheck
* Add address to debug log
* Speed up CI a bit (postgresml#119)
* Sleep for 1s
* use premade image
* quicker
* revert shutdown timeout
* Fix debug log (postgresml#120)
* Make prometheus port configurable (postgresml#121)
* Make prometheus port configurable
* Update circleci config
* Statement timeout + replica imbalance fix (postgresml#122)
* Statement timeout
* send error message too
* Correct error messages
* Fix replica inbalance
* disable stmt timeout by default
* Redundant mark_bad
* revert healthcheck delay
* tests
* set it to 0
* reload config again
* pgcat toml
Co-authored-by: Nicholas Dujay <3258756+dat2@users.noreply.github.com>
Co-authored-by: zainkabani <77307340+zainkabani@users.noreply.github.com>
Co-authored-by: Lev Kokotov <levkk@users.noreply.github.com>
Co-authored-by: Pradeep Chhetri <30620077+chhetripradeep@users.noreply.github.com>
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+1-7Lines changed: 1 addition & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,10 +10,4 @@ Happy hacking!
10
10
11
11
## TODOs
12
12
13
-
A non-exhaustive list of things that would be useful to implement:
14
-
15
-
#### Client authentication
16
-
MD5 is probably sufficient, but maybe others too.
17
-
18
-
#### Admin
19
-
Admin database for stats collection and pooler administration. PgBouncer gives us a nice example on how to do that, specifically how to implement `RowDescription` and `DataRow` messages, [example here](https://github.com/pgbouncer/pgbouncer/blob/4f9ced8e63d317a6ff45c8b0efa876b32161f6db/src/admin.c#L813).
13
+
See [Issues]([url](https://github.com/levkk/pgcat/issues)).
|`host`| The pooler will run on this host, 0.0.0.0 means accessible from everywhere. |`0.0.0.0`|
54
-
|`port`| The pooler will run on this port. |`6432`|
55
-
|`pool_size`| Maximum allowed server connections per pool. Pools are separated for each user/shard/server role. The connections are allocated as needed. |`15`|
56
-
|`pool_mode`| The pool mode to use, i.e. `session` or `transaction`. |`transaction`|
57
-
|`connect_timeout`| Maximum time to establish a connection to a server (milliseconds). If reached, the server is banned and the next target is attempted. |`5000`|
58
-
|`healthcheck_timeout`| Maximum time to pass a health check (`SELECT 1`, milliseconds). If reached, the server is banned and the next target is attempted. |`1000`|
59
-
|`shutdown_timeout`| Maximum time to give clients during shutdown before forcibly killing client connections (ms). |`60000`|
60
-
|`ban_time`| Ban time for a server (seconds). It won't be allowed to serve transactions until the ban expires; failover targets will be used instead. |`60`|
61
-
||||
62
-
|**`user`**|||
63
-
|`name`| The user name. |`sharding_user`|
64
-
|`password`| The user password in plaintext. |`hunter2`|
65
-
||||
66
-
|**`shards`**| Shards are numerically numbered starting from 0; the order in the config is preserved by the pooler to route queries accordingly. |`[shards.0]`|
67
-
|`servers`| List of servers to connect to and their roles. A server is: `[host, port, role]`, where `role` is either `primary` or `replica`. |`["127.0.0.1", 5432, "primary"]`|
68
-
|`database`| The name of the database to connect to. This is the same on all servers that are part of one shard. ||
69
-
|**`query_router`**|||
70
-
|`default_role`| Traffic is routed to this role by default (round-robin), unless the client specifies otherwise. Default is `any`, for any role available. |`any`, `primary`, `replica`|
71
-
|`query_parser_enabled`| Enable the query parser which will inspect incoming queries and route them to a primary or replicas. |`false`|
72
-
|`primary_reads_enabled`| Enable this to allow read queries on the primary; otherwise read queries are routed to the replicas. |`true`|
|`host`| The pooler will run on this host, 0.0.0.0 means accessible from everywhere. |`0.0.0.0`|
54
+
|`port`| The pooler will run on this port. |`6432`|
55
+
|`enable_prometheus_exporter`| Enable prometheus exporter which will export metrics in prometheus exposition format. |`true`|
56
+
|`prometheus_exporter_port`| Port at which prometheus exporter listens on. |`9930`|
57
+
|`pool_size`| Maximum allowed server connections per pool. Pools are separated for each user/shard/server role. The connections are allocated as needed. |`15`|
58
+
|`pool_mode`| The pool mode to use, i.e. `session` or `transaction`. |`transaction`|
59
+
|`connect_timeout`| Maximum time to establish a connection to a server (milliseconds). If reached, the server is banned and the next target is attempted. |`5000`|
60
+
|`healthcheck_timeout`| Maximum time to pass a health check (`SELECT 1`, milliseconds). If reached, the server is banned and the next target is attempted. |`1000`|
61
+
|`shutdown_timeout`| Maximum time to give clients during shutdown before forcibly killing client connections (ms). |`60000`|
62
+
|`healthcheck_delay`| How long to keep connection available for immediate re-use, without running a healthcheck query on it |`30000`|
63
+
|`ban_time`| Ban time for a server (seconds). It won't be allowed to serve transactions until the ban expires; failover targets will be used instead. |`60`|
64
+
|`autoreload`| Enable auto-reload of config after fixed time-interval. |`false`|
65
+
||||
66
+
|**`user`**|||
67
+
|`name`| The user name. |`sharding_user`|
68
+
|`password`| The user password in plaintext. |`hunter2`|
69
+
||||
70
+
|**`shards`**| Shards are numerically numbered starting from 0; the order in the config is preserved by the pooler to route queries accordingly. |`[shards.0]`|
71
+
|`servers`| List of servers to connect to and their roles. A server is: `[host, port, role]`, where `role` is either `primary` or `replica`. |`["127.0.0.1", 5432, "primary"]`|
72
+
|`database`| The name of the database to connect to. This is the same on all servers that are part of one shard. ||
73
+
||||
74
+
|**`query_router`**|||
75
+
|`default_role`| Traffic is routed to this role by default (round-robin), unless the client specifies otherwise. Default is `any`, for any role available. |`any`, `primary`, `replica`|
76
+
|`query_parser_enabled`| Enable the query parser which will inspect incoming queries and route them to a primary or replicas. |`false`|
77
+
|`primary_reads_enabled`| Enable this to allow read queries on the primary; otherwise read queries are routed to the replicas. |`true`|
73
78
74
79
## Local development
75
80
@@ -261,6 +266,7 @@ The config can be reloaded by sending a `kill -s SIGHUP` to the process or by qu
0 commit comments