export type RequestRelease = () => Promise<void> | void


export interface Locker {
  newLock(id: string): Lock
}


export interface Lock {
  lock(cancelReq: RequestRelease): Promise<void>
  unlock(): Promise<void>
}