From 2e3bd10fa7e55ae4934c5ec97ab54059a29fdaa1 Mon Sep 17 00:00:00 2001 From: Oleg Jukovec Date: Fri, 5 Aug 2022 16:21:37 +0300 Subject: [PATCH] code health: run gofmt from GoLang 1.19 golangci-lint on GitHub Actions uses a latest gofmt from GoLang 1.19. The patch contains changes from gofmt 1.19 run to fix golangci-lint check on CI. --- connection_pool/const.go | 24 ++++++++++++------------ decimal/bcd.go | 8 ++++---- future.go | 3 +-- queue/queue.go | 2 +- schema.go | 2 +- ssl_test.go | 28 ++++++++++++++-------------- uuid/uuid.go | 2 +- 7 files changed, 34 insertions(+), 35 deletions(-) diff --git a/connection_pool/const.go b/connection_pool/const.go index eb41a47ea..334806437 100644 --- a/connection_pool/const.go +++ b/connection_pool/const.go @@ -17,18 +17,18 @@ Mode parameter: - PREFER_RW (prefer write only instance (master)) - if there is one, otherwise fallback to a read only one (replica). - Request Default mode - ---------- -------------- - | call | no default | - | eval | no default | - | ping | no default | - | insert | RW | - | delete | RW | - | replace | RW | - | update | RW | - | upsert | RW | - | select | ANY | - | get | ANY | + Request Default mode + ---------- -------------- + | call | no default | + | eval | no default | + | ping | no default | + | insert | RW | + | delete | RW | + | replace | RW | + | update | RW | + | upsert | RW | + | select | ANY | + | get | ANY | */ const ( ANY = iota diff --git a/decimal/bcd.go b/decimal/bcd.go index 4cc57aa45..cf95ccf7c 100644 --- a/decimal/bcd.go +++ b/decimal/bcd.go @@ -9,15 +9,15 @@ // The first byte of the BCD array contains the first digit of the number, // represented as follows: // -// | 4 bits | 4 bits | -// = 0x = the 1st digit +// | 4 bits | 4 bits | +// = 0x = the 1st digit // // (The first nibble contains 0 if the decimal number has an even number of // digits). The last byte of the BCD array contains the last digit of the // number and the final nibble, represented as follows: // -// | 4 bits | 4 bits | -// = the last digit = nibble +// | 4 bits | 4 bits | +// = the last digit = nibble // // The final nibble represents the number's sign: 0x0a, 0x0c, 0x0e, 0x0f stand // for plus, 0x0b and 0x0d stand for minus. diff --git a/future.go b/future.go index e34bc2f65..a512d244c 100644 --- a/future.go +++ b/future.go @@ -210,10 +210,9 @@ func (fut *Future) GetTyped(result interface{}) error { // and a response. Push messages and the response will contain deserialized // result in Data field as for the Get() function. // -// See also +// # See also // // * box.session.push() https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_session/push/ -// func (fut *Future) GetIterator() (it TimeoutResponseIterator) { futit := &asyncResponseIterator{ fut: fut, diff --git a/queue/queue.go b/queue/queue.go index ef40154b0..c40b8a0df 100644 --- a/queue/queue.go +++ b/queue/queue.go @@ -3,7 +3,7 @@ // // Since: 1.5. // -// See also +// # See also // // * Tarantool queue module https://github.com/tarantool/queue package queue diff --git a/schema.go b/schema.go index ecf565762..35f65eb28 100644 --- a/schema.go +++ b/schema.go @@ -5,7 +5,7 @@ import ( "fmt" ) -//nolint: varcheck,deadcode +// nolint: varcheck,deadcode const ( maxSchemas = 10000 spaceSpId = 280 diff --git a/ssl_test.go b/ssl_test.go index 3bf9d8ba3..36ce4905f 100644 --- a/ssl_test.go +++ b/ssl_test.go @@ -198,20 +198,20 @@ type test struct { } /* - Requirements from Tarantool Enterprise Edition manual: - https://www.tarantool.io/ru/enterprise_doc/security/#configuration - - For a server: - KeyFile - mandatory - CertFile - mandatory - CaFile - optional - Ciphers - optional - - For a client: - KeyFile - optional, mandatory if server.CaFile set - CertFile - optional, mandatory if server.CaFile set - CaFile - optional, - Ciphers - optional +Requirements from Tarantool Enterprise Edition manual: +https://www.tarantool.io/ru/enterprise_doc/security/#configuration + +For a server: +KeyFile - mandatory +CertFile - mandatory +CaFile - optional +Ciphers - optional + +For a client: +KeyFile - optional, mandatory if server.CaFile set +CertFile - optional, mandatory if server.CaFile set +CaFile - optional, +Ciphers - optional */ var tests = []test{ { diff --git a/uuid/uuid.go b/uuid/uuid.go index a35f33faf..a72785c0e 100644 --- a/uuid/uuid.go +++ b/uuid/uuid.go @@ -4,7 +4,7 @@ // // Since: 1.6.0. // -// See also +// # See also // // * Tarantool commit with UUID support https://github.com/tarantool/tarantool/commit/d68fc29246714eee505bc9bbcd84a02de17972c5 //