Lock acquires the lock for name, blocking until the lock can be obtained or an error is returned. Only one lock for the given name can exist at a time. A call to Lock for a name which already exists blocks until the named lock is released or becomes stale. If the named lock represents an idempotent
(ctx context.Context, name string)
| 141 | // |
| 142 | // Implementations should honor context cancellation. |
| 143 | Lock(ctx context.Context, name string) error |
| 144 | |
| 145 | // Unlock releases named lock. This method must ONLY be called |
| 146 | // after a successful call to Lock, and only after the critical |
no outgoing calls