This Go application provides WebSocket endpoints for interacting with Kueue resources in a Kubernetes cluster. It uses the Gin framework for HTTP and WebSocket handling and the Kubernetes Go client for API interactions.
- Fetch and broadcast
localqueues
over WebSocket.
- A Kubernetes cluster
- Go 1.19+
kubectl
configured to access the cluster
- Clone this repository.
- Ensure Go is installed on your machine.
Run the following command to build the application:
CGO_ENABLED=0 go build -o kueue_ws_app
Run the application:
./kueue_ws_app
The application starts on port 8080
.
Endpoint | Description |
---|---|
/ws/local-queues |
Streams updates for local queues |
/ws/cluster-queues |
Streams updates for cluster queues |
/ws/workloads |
Streams updates for workloads |
/ws/resource-flavors |
Streams updates for resource flavors |
/ws/resource-flavor/{flavor_name} |
Streams updates for a specific flavor |
/ws/local-queue/{namespace}/{queue_name} |
Streams updates for a specific queue |
/ws/cohorts |
Streams updates for cohorts |
/ws/cohort/{cohort_name} |
Streams updates for a specific cohort |
/ws/workload/{namespace}/{workload_name} |
Streams updates for a specific workload |
/ws/workload/{namespace}/{workload_name}/events |
Streams events for a specific workload |