Debug the titan server
(ctx *Context, txn *db.Transaction)
| 211 | |
| 212 | // Debug the titan server |
| 213 | func Debug(ctx *Context, txn *db.Transaction) (OnCommit, error) { |
| 214 | switch strings.ToLower(ctx.Args[0]) { |
| 215 | case "object": |
| 216 | return debugObject(ctx, txn) |
| 217 | default: |
| 218 | return nil, errors.New("ERR not supported") |
| 219 | } |
| 220 | } |
| 221 | func debugObject(ctx *Context, txn *db.Transaction) (OnCommit, error) { |
| 222 | key := []byte(ctx.Args[1]) |
| 223 | obj, err := txn.Object(key) |
nothing calls this directly
no test coverage detected