Worker represents a 2PC worker who implements Prepare, Commit, and Rollback.
| 38 | |
| 39 | // Worker represents a 2PC worker who implements Prepare, Commit, and Rollback. |
| 40 | type Worker interface { |
| 41 | Prepare(ctx context.Context, wb WriteBatch) error |
| 42 | Commit(ctx context.Context, wb WriteBatch) (interface{}, error) |
| 43 | Rollback(ctx context.Context, wb WriteBatch) error |
| 44 | } |
| 45 | |
| 46 | // WriteBatch is an empty interface which will be passed to Worker methods. |
| 47 | type WriteBatch interface{} |
no outgoing calls
no test coverage detected