store: add missin LazyConnect option
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
		| @@ -134,6 +134,13 @@ func Timeout(td time.Duration) Option { | |||||||
| 	} | 	} | ||||||
| } | } | ||||||
|  |  | ||||||
|  | // LazyConnect initialize connection only when needed | ||||||
|  | func LazyConnect(b bool) Option { | ||||||
|  | 	return func(o *Options) { | ||||||
|  | 		o.LazyConnect = b | ||||||
|  | 	} | ||||||
|  | } | ||||||
|  |  | ||||||
| // Addrs contains the addresses or other connection information of the backing storage. | // Addrs contains the addresses or other connection information of the backing storage. | ||||||
| // For example, an etcd implementation would contain the nodes of the cluster. | // For example, an etcd implementation would contain the nodes of the cluster. | ||||||
| // A SQL implementation could contain one or more connection strings. | // A SQL implementation could contain one or more connection strings. | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user