@@ -155,21 +155,25 @@ type Greeting struct {
155
155
156
156
// Opts is a way to configure Connection
157
157
type Opts struct {
158
- // Timeout is requests timeout.
158
+ // Timeout is a timeout for any particular request. If Timeout is
159
+ // zero request, any request may block infinitely.
159
160
// Also used to setup net.TCPConn.Set(Read|Write)Deadline
160
161
Timeout time.Duration
161
- // Reconnect is a pause between reconnection attempts.
162
+ // Reconnect is a timeout between reconnect attempts. If Reconnect is
163
+ // zero, no reconnects will be performed.
162
164
// If specified, then when Tarantool is not reachable or disconnected,
163
165
// new connect attempt is performed after pause.
164
166
// By default, no reconnection attempts are performed,
165
167
// so once disconnected, connection becomes Closed.
166
168
Reconnect time.Duration
167
- // MaxReconnects is a maximum reconnect attempts.
169
+ // MaxReconnects is a maximal number of reconnect failures; after that
170
+ // we give it up. If MaxReconnects is zero, the client will try to
171
+ // reconnect endlessly.
168
172
// After MaxReconnects attempts Connection becomes closed.
169
173
MaxReconnects uint
170
- // User name for authorization
174
+ // User is user name to log into Tarantool.
171
175
User string
172
- // Pass is password for authorization
176
+ // Pass is a user password to log into Tarantool.
173
177
Pass string
174
178
// RateLimit limits number of 'in-fly' request, i.e. already put into
175
179
// requests queue, but not yet answered by server or timeouted.
0 commit comments