Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChangePauseState ¶
func ChangePauseState(desiredState types.PauseState, pauseType types.PauseType) func(c *gin.Context)
ChangePauseState builds a handler that moves one pause kind into one state. The state and pause kind are bound at route registration time, so each of the four pause/unpause paths is this same handler with different arguments.
@Summary Pause or unpause the competition
@Description Moves one of the two independent pauses into the requested state. A scoring pause leaves checks running but stops results counting toward team totals; a check pause stops checks being handed to agents entirely. The target state and pause kind are fixed by the path, so there is no request body. Requesting a state the competition is already in changes nothing and returns 418.
@Tags comp
@Produce json
@Success 200 {object} object
@Failure 418 {object} object
@Failure 500 {object} object
@Failure 501 {object} object
@Router /comp/pause-checks [post]
@Router /comp/unpause-checks [post]
@Router /comp/pause-scoring [post]
@Router /comp/unpause-scoring [post]
func PauseStatus ¶
PauseStatus reports the current state of both competition pauses.
@Summary Get competition pause status
@Description Reports both pause kinds at once — whether scoring is paused and whether checks are paused — each with the moment it entered its current state.
@Tags comp
@Produce json
@Success 200 {object} types.PauseRecord
@Failure 500 {object} object
@Failure 501 {object} object
@Router /comp/pause-status [get]
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.