Skip to content

Commit 1bccc12

Browse files
committed
readme: move description of options to inline comment
1 parent 4e57c54 commit 1bccc12

File tree

2 files changed

+9
-17
lines changed

2 files changed

+9
-17
lines changed

README.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ faster than other packages according to public benchmarks.
2525
* [API reference](#api-reference)
2626
* [Help](#help)
2727
* [Usage](#usage)
28-
* [Options](#options)
2928
* [Tests](#tests)
3029
* [Alternative connectors](#alternative-connectors)
3130

@@ -120,17 +119,6 @@ will also be happy to provide advice or receive feedback.
120119
To enable support of UUID in msgpack with [google/uuid](https://github.com/google/uuid),
121120
import tarantool/uuid submodule.
122121

123-
## Options
124-
125-
* `Timeout` - timeout for any particular request. If `Timeout` is zero request,
126-
any request may block infinitely.
127-
* `Reconnect` - timeout between reconnect attempts. If `Reconnect` is zero, no
128-
reconnects will be performed.
129-
* `MaxReconnects` - maximal number of reconnect failures; after that we give it
130-
up. If `MaxReconnects` is zero, the client will try to reconnect endlessly.
131-
* `User` - user name to log into Tarantool.
132-
* `Pass` - user password to log into Tarantool.
133-
134122
## Multi connections
135123

136124
You can use multiple connections config with tarantool/multi.

connection.go

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -155,21 +155,25 @@ type Greeting struct {
155155

156156
// Opts is a way to configure Connection
157157
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.
159160
// Also used to setup net.TCPConn.Set(Read|Write)Deadline
160161
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.
162164
// If specified, then when Tarantool is not reachable or disconnected,
163165
// new connect attempt is performed after pause.
164166
// By default, no reconnection attempts are performed,
165167
// so once disconnected, connection becomes Closed.
166168
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.
168172
// After MaxReconnects attempts Connection becomes closed.
169173
MaxReconnects uint
170-
// User name for authorization
174+
// User is user name to log into Tarantool.
171175
User string
172-
// Pass is password for authorization
176+
// Pass is a user password to log into Tarantool.
173177
Pass string
174178
// RateLimit limits number of 'in-fly' request, i.e. already put into
175179
// requests queue, but not yet answered by server or timeouted.

0 commit comments

Comments
 (0)