File tree Expand file tree Collapse file tree 2 files changed +15
-6
lines changed
gateway-ha/src/main/java/io/trino/gateway/ha/clustermonitor Expand file tree Collapse file tree 2 files changed +15
-6
lines changed Original file line number Diff line number Diff line change @@ -134,6 +134,21 @@ condition: 'request.getHeader("X-Trino-Client-Tags") contains "label=foo"'
134134
135135If no rules match, then request is routed to adhoc.
136136
137+ # ## TrinoState
138+
139+ This class attempts to track the current state of Trino cluster. It is updated per every healthcheck.
140+ There are three possible states
141+
142+ * PENDING
143+ * A Trino cluster will show this state when it is still starting up. It will be treated as
144+ unhealthy by RoutingManager, and therefore requests will not be routed to PENDING clusters
145+ * HEALTHY
146+ * A Trino cluster will show this state when healthchecks report clusters as healthy and ready.
147+ RoutingManager will only route requests to healthy clusters
148+ * UNHEALTHY
149+ * A Trino cluster will show this state when healthchecks report clusters as unhealthy. RoutingManager
150+ will not route requests to unhealthy clusters.
151+
137152# ## TrinoRequestUser
138153
139154This class attempts to extract the user from a request. In order, it attempts
Original file line number Diff line number Diff line change 1313 */
1414package io .trino .gateway .ha .clustermonitor ;
1515
16- /**
17- * PENDING is for ui/observability purpose and functionally it's unhealthy
18- * We should use PENDING when Trino clusters are still spinning up
19- * HEALTHY is when health checks report clusters as up
20- * UNHEALTHY is when health checks report clusters as down
21- */
2216public enum TrinoStatus
2317{
2418 PENDING ,
You can’t perform that action at this time.
0 commit comments