WithDriver instructs the Providers to accept a leader election driver different from the default one. This option supersedes the WithDriverConstructor option.
(driver Driver)
| 12 | // different from the default one. This option supersedes the |
| 13 | // WithDriverConstructor option. |
| 14 | func WithDriver(driver Driver) ProvidersOptionFunc { |
| 15 | return func(options *providersOption) { |
| 16 | options.driver = driver |
| 17 | } |
| 18 | } |
| 19 | |
| 20 | // WithDriverConstructor instructs the Providers to accept an alternative constructor for election driver. |
| 21 | // If the WithDriver option is set, this option becomes an no-op. |
no outgoing calls