MCPcopy Create free account
hub / github.com/TalkingData/owl / queueStatus

Function queueStatus

controller/health.go:46–56  ·  view source on GitHub ↗
(c *gin.Context)

Source from the content-addressed store, hash-verified

44}
45
46func queueStatus(c *gin.Context) {
47 qs := make([]gin.H, 0)
48 controller.eventQueuesMutex.RLock()
49 defer controller.eventQueuesMutex.RUnlock()
50 for _, product := range mydb.GetProducts() {
51 if queue, ok := controller.eventQueues[product.ID]; ok {
52 qs = append(qs, gin.H{"id": product.ID, "name": product.Name, "count": queue.len(), "mute": queue.mute})
53 }
54 }
55 c.JSON(http.StatusOK, gin.H{"queues": qs})
56}
57
58func queueClean(c *gin.Context) {
59 id := c.Param("id")

Callers

nothing calls this directly

Calls 2

GetProductsMethod · 0.80
lenMethod · 0.80

Tested by

no test coverage detected