MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / handleSGCollectStatus

Method handleSGCollectStatus

rest/admin_api.go:1638–1647  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1636}
1637
1638func (h *handler) handleSGCollectStatus() error {
1639 status := "stopped"
1640 if h.server.SGCollect.IsRunning() {
1641 status = "running"
1642 }
1643
1644 h.writeRawJSONStatus(http.StatusOK, []byte(`{"status":"`+status+`"}`))
1645 base.Audit(h.ctx(), base.AuditIDSyncGatewayCollectInfoStatus, nil)
1646 return nil
1647}
1648
1649func (h *handler) handleSGCollectCancel() error {
1650 err := h.server.SGCollect.Stop()

Callers

nothing calls this directly

Calls 4

writeRawJSONStatusMethod · 0.95
ctxMethod · 0.95
AuditFunction · 0.92
IsRunningMethod · 0.80

Tested by

no test coverage detected