Skip to content

Commit 4eb89d9

Browse files
committed
Merge branch 'master' of github.com:go-mysql-org/go-mysql into fixMySQL8Index
2 parents 62abae6 + 0bb0b8d commit 4eb89d9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+3780
-1619
lines changed

.github/workflows/ci.yml

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: runTestsAndLinters
2+
on: [push, pull_request]
3+
4+
jobs:
5+
test:
6+
strategy:
7+
matrix:
8+
go: [ 1.16, 1.15 ]
9+
name: Tests Go ${{ matrix.go }}
10+
runs-on: ubuntu-18.04
11+
12+
steps:
13+
- name: Setup MySQL
14+
run: |
15+
echo -n "mysql -V: " ; mysql -V
16+
echo -n "mysqldump -V: " ; mysqldump -V
17+
18+
echo -e '[mysqld]\nserver-id=1\nlog-bin=mysql\nbinlog-format=row\ngtid-mode=ON\nenforce_gtid_consistency=ON\n' | sudo tee /etc/mysql/conf.d/replication.cnf
19+
sudo service mysql start
20+
sudo mysql -h 127.0.0.1 -uroot -proot -e "use mysql; update user set authentication_string=PASSWORD('') where User='root'; update user set plugin='mysql_native_password'; FLUSH PRIVILEGES;"
21+
# create ssl/rsa files for mysql ssl support
22+
sudo mysql_ssl_rsa_setup --uid=mysql
23+
mysql -e "CREATE DATABASE IF NOT EXISTS test;" -uroot
24+
mysql -e "SHOW VARIABLES LIKE 'log_bin'" -uroot
25+
- name: Prepare for Go
26+
run: |
27+
sudo apt-get install -y make gcc
28+
- name: Install Go
29+
uses: actions/setup-go@v2
30+
with:
31+
go-version: ${{ matrix.go }}
32+
- name: Checkout code
33+
uses: actions/checkout@v1
34+
- name: Run tests
35+
run: go test ./...
36+
37+
golangci:
38+
name: golangci
39+
runs-on: ubuntu-latest
40+
steps:
41+
- uses: actions/checkout@v2
42+
- name: golangci-lint
43+
uses: golangci/golangci-lint-action@v2
44+
with:
45+
version: latest

.golangci.yml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
linters:
2+
disable-all: true
3+
enable:
4+
# All code is ready for:
5+
- deadcode
6+
- errcheck
7+
- staticcheck
8+
- structcheck
9+
- typecheck
10+
- unused
11+
- varcheck
12+
- misspell
13+
- nolintlint
14+
- goimports
15+
- nakedret
16+
- unconvert
17+
- whitespace
18+
# ToDo:
19+
#- gosimple
20+
#- govet
21+
#- ineffassign
22+
#- gocritic
23+
#- golint
24+
linters-settings:
25+
nolintlint:
26+
allow-unused: false
27+
allow-leading-space: false
28+
require-specific: true

.travis.yml

-47
This file was deleted.

CHANGELOG.md

+72
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
### Tag v1.4.0 (2021-12-15)
2+
* Fix that forget to readOK after writing. [#652](https://github.com/go-mysql-org/go-mysql/pull/652) ([lance6716](https://github.com/lance6716))
3+
* Packet: memory optimization for reading network packet. [#651](https://github.com/go-mysql-org/go-mysql/pull/651) ([zr-hebo](https://github.com/zr-hebo))
4+
* Add test for Conn.ExecuteSelectStreaming. [#649](https://github.com/go-mysql-org/go-mysql/pull/649) ([atercattus](https://github.com/atercattus))
5+
* Fix(server):java jdbc connect "Access denied for user 'root'@'127.0.0.1:3306' (using password: Yes). [#646](https://github.com/go-mysql-org/go-mysql/pull/646) ([pretty66](https://github.com/pretty66))
6+
* Reuse BytesBuffer in BinlogParser. [#644](https://github.com/go-mysql-org/go-mysql/pull/644) ([D3Hunter](https://github.com/D3Hunter))
7+
* Add ConnectWithDialer. [#643](https://github.com/go-mysql-org/go-mysql/pull/643) ([bakins](https://github.com/bakins))
8+
* Read auth_data_len from InitialHandshake packet instead of hard code. [#640](https://github.com/go-mysql-org/go-mysql/pull/640) ([guoyuanchao1202](https://github.com/guoyuanchao1202))
9+
* Fix: return error if error in packet. [#637](https://github.com/go-mysql-org/go-mysql/pull/637) ([btoonk](https://github.com/btoonk))
10+
* Fix ast.TruncateTableStmt node name assignment. [#630](https://github.com/go-mysql-org/go-mysql/pull/630) ([daledude](https://github.com/daledude))
11+
* Support insert argument type json.RawMessage. [#627](https://github.com/go-mysql-org/go-mysql/pull/627) ([domyway](https://github.com/domyway))
12+
* Adds parsing of IntVarEvents. [#624](https://github.com/go-mysql-org/go-mysql/pull/624) ([IvoGoman](https://github.com/IvoGoman))
13+
* Allow to set certain client-side capabilities. [#616](https://github.com/go-mysql-org/go-mysql/pull/616) ([skoef](https://github.com/skoef))
14+
* Add GTID-based replication to example. [#615](https://github.com/go-mysql-org/go-mysql/pull/615) ([lance6716](https://github.com/lance6716))
15+
* Support MYSQL_TYPE_JSON. [#614](https://github.com/go-mysql-org/go-mysql/pull/614) ([domyway](https://github.com/domyway))
16+
* Adds documentation for row-based replication flags. [#611](https://github.com/go-mysql-org/go-mysql/pull/611) ([IvoGoman](https://github.com/IvoGoman))
17+
* Add scheme/Index NoneUnique. [#610](https://github.com/go-mysql-org/go-mysql/pull/610) ([afocus](https://github.com/afocus))
18+
* Hidden mysql password in log. [#608](https://github.com/go-mysql-org/go-mysql/pull/608) ([elonzh](https://github.com/elonzh))
19+
* Fix error when trying to check binlog settings. [#602](https://github.com/go-mysql-org/go-mysql/pull/602) ([cr1sp1n](https://github.com/cr1sp1n))
20+
* Use constant and add comment for magic number 9. [#599](https://github.com/go-mysql-org/go-mysql/pull/599) ([lance6716](https://github.com/lance6716))
21+
* Extended ExecuteSelectStreaming. [#596](https://github.com/go-mysql-org/go-mysql/pull/596) ([skoef](https://github.com/skoef))
22+
* Fixed access denied error messages. [#595](https://github.com/go-mysql-org/go-mysql/pull/595) ([skoef](https://github.com/skoef))
23+
* Replaced all %lu, %ld and %u to %d for correct formatting of errors. [#594](https://github.com/go-mysql-org/go-mysql/pull/594) ([skoef](https://github.com/skoef))
24+
* Connection status flag manipulation. [#593](https://github.com/go-mysql-org/go-mysql/pull/593) ([skoef](https://github.com/skoef))
25+
* Return EOF response on COM_SET_OPTION commands. [#590](https://github.com/go-mysql-org/go-mysql/pull/590) ([skoef](https://github.com/skoef))
26+
* Improved access denied error messages. [#589](https://github.com/go-mysql-org/go-mysql/pull/589) ([skoef](https://github.com/skoef))
27+
* Expose capability and charset of connections to server. [#588](https://github.com/go-mysql-org/go-mysql/pull/588) ([skoef](https://github.com/skoef))
28+
* Fix a bug that values of time(1),time(3),time(5) will generate 00:00:00. [#529](https://github.com/go-mysql-org/go-mysql/pull/529) ([hamburgerbox](https://github.com/hamburgerbox))
29+
30+
### Tag v1.3.0 (2021.06.10)
31+
* Init Resultset in Result when handling ddl statement. [#578](https://github.com/go-mysql-org/go-mysql/pull/578) ([romberli](https://github.com/romberli))
32+
* Add pool for client connections. [#584](https://github.com/go-mysql-org/go-mysql/pull/584) ([atercattus](https://github.com/atercattus))
33+
34+
### Tag v1.2.1 (2021.05.27)
35+
* Prevent panic on malformed auth data. [#557](https://github.com/go-mysql-org/go-mysql/pull/557) ([timvaillancourt](https://github.com/timvaillancourt))
36+
37+
### Tag v1.2.0 (2021.05.16)
38+
* Fix a rare bug in Conn.readResultStreaming. [#573](https://github.com/go-mysql-org/go-mysql/pull/573) ([atercattus](https://github.com/atercattus))
39+
* Fix tag. [#575](https://github.com/go-mysql-org/go-mysql/pull/575) ([atercattus](https://github.com/atercattus))
40+
* Update dependency. [#576](https://github.com/go-mysql-org/go-mysql/pull/576) ([Ehco1996](https://github.com/Ehco1996))
41+
42+
### Tag v1.1.2 (2021.04.20)
43+
* Fix canal test in readme. [#516](https://github.com/go-mysql-org/go-mysql/pull/516) ([gaojijun](https://github.com/gaojijun))
44+
* UUID clone. [#522](https://github.com/go-mysql-org/go-mysql/pull/522) ([lance6716](https://github.com/lance6716))
45+
* Sort mariadb gtid set. [#545](https://github.com/go-mysql-org/go-mysql/pull/545) ([zeminzhou](https://github.com/zeminzhou))
46+
* Mysql: use numeric comparison for binlog filename. [#547](https://github.com/go-mysql-org/go-mysql/pull/547) ([lance6716](https://github.com/lance6716))
47+
* Fix MySQL spell. [#549](https://github.com/go-mysql-org/go-mysql/pull/549) ([igoso](https://github.com/igoso))
48+
* Update README.md and CHANGELOG.md. [#564](https://github.com/go-mysql-org/go-mysql/pull/564) ([atercattus](https://github.com/atercattus))
49+
* Update method now may receive strings with GTID sets. [#569](https://github.com/go-mysql-org/go-mysql/pull/569) ([mialinx](https://github.com/mialinx))
50+
* Change module name from siddontang/go-mysql to go-mysql-org/go-mysql. [#571](https://github.com/go-mysql-org/go-mysql/pull/571) ([lance6716](https://github.com/lance6716))
51+
* Fix a bug that not cloned to original memory. [#572](https://github.com/go-mysql-org/go-mysql/pull/572) ([lance6716](https://github.com/lance6716))
52+
* Update README.md for a new tag. [#574](https://github.com/go-mysql-org/go-mysql/pull/574) ([atercattus](https://github.com/atercattus))
53+
54+
### Tag v1.1.1 (2021.04.08)
55+
* Restructured dump/ tests. [#563](https://github.com/go-mysql-org/go-mysql/pull/563) ([atercattus](https://github.com/atercattus))
56+
* Replace magic numbers in canal/canal_test.go by constants. [#562](https://github.com/go-mysql-org/go-mysql/pull/562) ([atercattus](https://github.com/atercattus))
57+
* Fix parsing GTIDs from mysqlpdump. [#561](https://github.com/go-mysql-org/go-mysql/pull/561) ([dobegor](https://github.com/dobegor))
58+
* Streaming of SELECT responses. `client/Conn.ExecuteSelectStreaming()` added. [#560](https://github.com/go-mysql-org/go-mysql/pull/560) ([atercattus](https://github.com/atercattus))
59+
* Migation from travis.ci to github actions. [#559](https://github.com/go-mysql-org/go-mysql/pull/559) ([atercattus](https://github.com/atercattus))
60+
* Output sorted mysql gtid. [#500](https://github.com/go-mysql-org/go-mysql/pull/500) ([zr-hebo](https://github.com/zr-hebo))
61+
* Add skipped columns information. [#505](https://github.com/go-mysql-org/go-mysql/pull/505) ([laskoviymishka](https://github.com/laskoviymishka))
62+
* Feat: support disable retry sync for canal. [#507](https://github.com/go-mysql-org/go-mysql/pull/507) ([everpcpc](https://github.com/everpcpc))
63+
* Update README.md. [#511](https://github.com/go-mysql-org/go-mysql/pull/511) ([TennyZhuang](https://github.com/TennyZhuang))
64+
* Add function to extend replication options. [#508](https://github.com/go-mysql-org/go-mysql/pull/508) ([wefen](https://github.com/wefen))
65+
66+
### Tag v1.1.0 (2020.07.17)
67+
* Update .travis.yml (go 1.14 and tip). [#510](https://github.com/go-mysql-org/go-mysql/pull/510) ([atercattus](https://github.com/atercattus))
68+
* Update README.md. [#509](https://github.com/go-mysql-org/go-mysql/pull/509) ([atercattus](https://github.com/atercattus))
69+
* A lot of memory allocation optimizations. Changed public API for `mysql/Resultset` type. [#466](https://github.com/go-mysql-org/go-mysql/pull/466) ([atercattus](https://github.com/atercattus))
70+
71+
### Tag v1.0.0 (2020.07.17)
72+
Add SemVer

Makefile

+9-6
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,17 @@ all: build
33
GO111MODULE=on
44

55
build:
6-
go build -o bin/go-mysqlbinlog cmd/go-mysqlbinlog/main.go
7-
go build -o bin/go-mysqldump cmd/go-mysqldump/main.go
8-
go build -o bin/go-canal cmd/go-canal/main.go
9-
go build -o bin/go-binlogparser cmd/go-binlogparser/main.go
10-
6+
go build -o bin/go-mysqlbinlog cmd/go-mysqlbinlog/main.go
7+
go build -o bin/go-mysqldump cmd/go-mysqldump/main.go
8+
go build -o bin/go-canal cmd/go-canal/main.go
9+
go build -o bin/go-binlogparser cmd/go-binlogparser/main.go
10+
1111
test:
1212
go test --race -timeout 2m ./...
13-
13+
14+
fmt:
15+
golangci-lint run --fix
16+
1417
clean:
1518
go clean -i ./...
1619
@rm -rf ./bin

README.md

+85-24
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,29 @@
22

33
A pure go library to handle MySQL network protocol and replication.
44

5-
## Call for Committer/Maintainer
5+
![semver](https://img.shields.io/github/v/tag/go-mysql-org/go-mysql)
6+
![example workflow](https://github.com/go-mysql-org/go-mysql/actions/workflows/ci.yml/badge.svg)
7+
![gomod version](https://img.shields.io/github/go-mod/go-version/go-mysql-org/go-mysql/master)
68

7-
Sorry that I have no enough time to maintain this project wholly, if you like this project and want to help me improve it continuously, please contact me through email ([email protected]).
9+
## How to migrate to this repo
10+
To change the used package in your repo it's enough to add this `replace` directive to your `go.mod`:
11+
```
12+
replace github.com/siddontang/go-mysql => github.com/go-mysql-org/go-mysql v1.4.0
13+
```
14+
15+
v1.4.0 - is the last tag in repo, feel free to choose what you want.
816

9-
Requirement: In the email, you should list somethings(including but not limited to below) to make me believe we can work together.
17+
## Changelog
18+
This repo uses [Changelog](CHANGELOG.md).
1019

11-
+ Your GitHub ID
12-
+ The contributions to go-mysql before, including PRs or Issues.
13-
+ The reason why you can improve go-mysql.
14-
20+
---
21+
# Content
22+
* [Slave replication](#replication)
23+
* [Incremental dumping](#canal)
24+
* [Client](#client)
25+
* [Fake server](#server)
26+
* [Failover](#failover)
27+
* [database/sql like driver](#driver)
1528

1629
## Replication
1730

@@ -23,7 +36,7 @@ You can use it as a MySQL slave to sync binlog from master then do something, li
2336

2437
```go
2538
import (
26-
"github.com/siddontang/go-mysql/replication"
39+
"github.com/go-mysql-org/go-mysql/replication"
2740
"os"
2841
)
2942
// Create a binlog syncer with a unique server id, the server id must be different from other MySQL's.
@@ -107,20 +120,18 @@ You must use ROW format for binlog, full binlog row image is preferred, because
107120
A simple example:
108121

109122
```go
110-
cfg := NewDefaultConfig()
111-
cfg.Addr = "127.0.0.1:3306"
112-
cfg.User = "root"
113-
// We only care table canal_test in test db
114-
cfg.Dump.TableDB = "test"
115-
cfg.Dump.Tables = []string{"canal_test"}
123+
package main
116124

117-
c, err := NewCanal(cfg)
125+
import (
126+
"github.com/siddontang/go-log/log"
127+
"github.com/go-mysql-org/go-mysql/canal"
128+
)
118129

119130
type MyEventHandler struct {
120-
DummyEventHandler
131+
canal.DummyEventHandler
121132
}
122133

123-
func (h *MyEventHandler) OnRow(e *RowsEvent) error {
134+
func (h *MyEventHandler) OnRow(e *canal.RowsEvent) error {
124135
log.Infof("%s %v\n", e.Action, e.Rows)
125136
return nil
126137
}
@@ -129,11 +140,25 @@ func (h *MyEventHandler) String() string {
129140
return "MyEventHandler"
130141
}
131142

132-
// Register a handler to handle RowsEvent
133-
c.SetEventHandler(&MyEventHandler{})
143+
func main() {
144+
cfg := canal.NewDefaultConfig()
145+
cfg.Addr = "127.0.0.1:3306"
146+
cfg.User = "root"
147+
// We only care table canal_test in test db
148+
cfg.Dump.TableDB = "test"
149+
cfg.Dump.Tables = []string{"canal_test"}
150+
151+
c, err := canal.NewCanal(cfg)
152+
if err != nil {
153+
log.Fatal(err)
154+
}
155+
156+
// Register a handler to handle RowsEvent
157+
c.SetEventHandler(&MyEventHandler{})
134158

135-
// Start canal
136-
c.Run()
159+
// Start canal
160+
c.Run()
161+
}
137162
```
138163

139164
You can see [go-mysql-elasticsearch](https://github.com/siddontang/go-mysql-elasticsearch) for how to sync MySQL data into Elasticsearch.
@@ -146,7 +171,7 @@ Client package supports a simple MySQL connection driver which you can use it to
146171

147172
```go
148173
import (
149-
"github.com/siddontang/go-mysql/client"
174+
"github.com/go-mysql-org/go-mysql/client"
150175
)
151176

152177
// Connect MySQL at 127.0.0.1:3306, with user root, an empty password and database test
@@ -197,6 +222,42 @@ Tested MySQL versions for the client include:
197222
- 5.7.x
198223
- 8.0.x
199224

225+
### Example for SELECT streaming (v1.1.1)
226+
You can use also streaming for large SELECT responses.
227+
The callback function will be called for every result row without storing the whole resultset in memory.
228+
`result.Fields` will be filled before the first callback call.
229+
230+
```go
231+
// ...
232+
var result mysql.Result
233+
err := conn.ExecuteSelectStreaming(`select id, name from table LIMIT 100500`, &result, func(row []mysql.FieldValue) error {
234+
for idx, val := range row {
235+
field := result.Fields[idx]
236+
// You must not save FieldValue.AsString() value after this callback is done.
237+
// Copy it if you need.
238+
// ...
239+
}
240+
return nil
241+
}, nil)
242+
243+
// ...
244+
```
245+
246+
### Example for connection pool (v1.3.0)
247+
248+
```go
249+
import (
250+
"github.com/go-mysql-org/go-mysql/client"
251+
)
252+
253+
pool := client.NewPool(log.Debugf, 100, 400, 5, "127.0.0.1:3306", `root`, ``, `test`)
254+
// ...
255+
conn, _ := pool.GetConn(ctx)
256+
defer pool.PutConn(conn)
257+
258+
conn.Execute() / conn.Begin() / etc...
259+
```
260+
200261
## Server
201262

202263
Server package supplies a framework to implement a simple MySQL server which can handle the packets from the MySQL client.
@@ -207,7 +268,7 @@ so that most MySQL clients should be able to connect to the Server without modif
207268

208269
```go
209270
import (
210-
"github.com/siddontang/go-mysql/server"
271+
"github.com/go-mysql-org/go-mysql/server"
211272
"net"
212273
)
213274

@@ -261,7 +322,7 @@ package main
261322
import (
262323
"database/sql"
263324

264-
_ "github.com/siddontang/go-mysql/driver"
325+
_ "github.com/go-mysql-org/go-mysql/driver"
265326
)
266327

267328
func main() {

0 commit comments

Comments
 (0)