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

Method handleGetRevTree

rest/admin_api.go:1501–1511  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1499}
1500
1501func (h *handler) handleGetRevTree() error {
1502 h.assertAdminOnly()
1503 docid := h.PathVar("docid")
1504 doc, err := h.collection.GetDocument(h.ctx(), docid, db.DocUnmarshalAll)
1505
1506 if doc != nil {
1507 h.writeText([]byte(doc.History.RenderGraphvizDot()))
1508 base.Audit(h.ctx(), base.AuditIDDocumentMetadataRead, base.AuditFields{base.AuditFieldDocID: docid})
1509 }
1510 return err
1511}
1512
1513func (h *handler) handleGetLogging() error {
1514 base.WarnfCtx(h.ctx(), "Using deprecated /_logging endpoint. Use /_config endpoints instead.")

Callers

nothing calls this directly

Calls 7

assertAdminOnlyMethod · 0.95
PathVarMethod · 0.95
ctxMethod · 0.95
writeTextMethod · 0.95
AuditFunction · 0.92
RenderGraphvizDotMethod · 0.80
GetDocumentMethod · 0.65

Tested by

no test coverage detected