File tree Expand file tree Collapse file tree 4 files changed +21
-1
lines changed Expand file tree Collapse file tree 4 files changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -142,7 +142,7 @@ type Options struct {
142142 // Enables read only queries on slave/follower nodes.
143143 readOnly bool
144144
145- // // Disable set-lib on connect. Default is false.
145+ // Disable set-lib on connect. Default is false.
146146 DisableIndentity bool
147147}
148148
Original file line number Diff line number Diff line change @@ -84,6 +84,8 @@ type RingOptions struct {
8484 WriteTimeout time.Duration
8585 ContextTimeoutEnabled bool
8686
87+ ContextTimeoutEnabled bool
88+
8789 // PoolFIFO uses FIFO mode for each node connection pool GET/PUT (default LIFO).
8890 PoolFIFO bool
8991
@@ -97,6 +99,8 @@ type RingOptions struct {
9799
98100 TLSConfig * tls.Config
99101 Limiter Limiter
102+
103+ DisableIndentity bool
100104}
101105
102106func (opt * RingOptions ) init () {
@@ -151,6 +155,8 @@ func (opt *RingOptions) clientOptions() *Options {
151155 WriteTimeout : opt .WriteTimeout ,
152156 ContextTimeoutEnabled : opt .ContextTimeoutEnabled ,
153157
158+ ContextTimeoutEnabled : opt .ContextTimeoutEnabled ,
159+
154160 PoolFIFO : opt .PoolFIFO ,
155161 PoolSize : opt .PoolSize ,
156162 PoolTimeout : opt .PoolTimeout ,
@@ -162,6 +168,8 @@ func (opt *RingOptions) clientOptions() *Options {
162168
163169 TLSConfig : opt .TLSConfig ,
164170 Limiter : opt .Limiter ,
171+
172+ DisableIndentity : opt .DisableIndentity ,
165173 }
166174}
167175
Original file line number Diff line number Diff line change @@ -79,6 +79,8 @@ type FailoverOptions struct {
7979 ConnMaxLifetime time.Duration
8080
8181 TLSConfig * tls.Config
82+
83+ DisableIndentity bool
8284}
8385
8486func (opt * FailoverOptions ) clientOptions () * Options {
@@ -113,6 +115,8 @@ func (opt *FailoverOptions) clientOptions() *Options {
113115 ConnMaxLifetime : opt .ConnMaxLifetime ,
114116
115117 TLSConfig : opt .TLSConfig ,
118+
119+ DisableIndentity : opt .DisableIndentity ,
116120 }
117121}
118122
Original file line number Diff line number Diff line change @@ -65,6 +65,8 @@ type UniversalOptions struct {
6565 // Only failover clients.
6666
6767 MasterName string
68+
69+ DisableIndentity bool
6870}
6971
7072// Cluster returns cluster options created from the universal options.
@@ -108,6 +110,8 @@ func (o *UniversalOptions) Cluster() *ClusterOptions {
108110 ConnMaxLifetime : o .ConnMaxLifetime ,
109111
110112 TLSConfig : o .TLSConfig ,
113+
114+ DisableIndentity : o .DisableIndentity ,
111115 }
112116}
113117
@@ -151,6 +155,8 @@ func (o *UniversalOptions) Failover() *FailoverOptions {
151155 ConnMaxLifetime : o .ConnMaxLifetime ,
152156
153157 TLSConfig : o .TLSConfig ,
158+
159+ DisableIndentity : o .DisableIndentity ,
154160 }
155161}
156162
@@ -191,6 +197,8 @@ func (o *UniversalOptions) Simple() *Options {
191197 ConnMaxLifetime : o .ConnMaxLifetime ,
192198
193199 TLSConfig : o .TLSConfig ,
200+
201+ DisableIndentity : o .DisableIndentity ,
194202 }
195203}
196204
You can’t perform that action at this time.
0 commit comments