- Reference >
mongoShell Methods >- Sharding Methods >
- sh.waitForDLock()
sh.waitForDLock()¶
On this page
Definition¶
-
sh.waitForDLock(lockname, wait, timeout, interval)¶ Waits until the specified distributed lock changes state.
sh.waitForDLock()is an internal method that takes the following arguments:Parameter Type Description locknamestring The name of the distributed lock. waitboolean Optional. Set to trueto ensure the balancer is now active. Set tofalseto wait until balancing stops and becomes inactive.timeoutinteger Milliseconds to wait. intervalinteger Milliseconds to sleep in each waiting cycle.