Skip to content

Commit

Permalink
Merge pull request #291 from brokercap/v2.3.8
Browse files Browse the repository at this point in the history
V2.3.8
  • Loading branch information
jc3wish authored Nov 5, 2024
2 parents ba0a03e + b0d9d16 commit e8dabf2
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 9 deletions.
7 changes: 5 additions & 2 deletions Bristol/mysql/packets.go
Original file line number Diff line number Diff line change
Expand Up @@ -810,10 +810,13 @@ func (mc *mysqlConn) readBinaryRows(rc *rowsContent) (e error) {
b := int8(byteToUint8(data[pos]))
//length == 1 是 tinyint(1) bool值
if rc.columns[i].length == 1 {
if b == 1 {
switch b {
case 1:
row[i] = true
} else {
case 0:
row[i] = false
default:
row[i] = b
}
} else {
row[i] = b
Expand Down
5 changes: 5 additions & 0 deletions Bristol/mysql/parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -485,6 +485,11 @@ func (parser *eventParser) GetTableSchemaByName(tableId uint64, database string,
CHARACTER_OCTET_LENGTH = uint64(dest[9].(uint32))
case uint64:
CHARACTER_OCTET_LENGTH = dest[9].(uint64)
case int64:
CHARACTER_OCTET_LENGTH = uint64(dest[9].(int64))
case int32:
CHARACTER_OCTET_LENGTH = uint64(dest[9].(int32))

default:
CHARACTER_OCTET_LENGTH = 0
}
Expand Down
6 changes: 3 additions & 3 deletions README.EN.MD
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,11 @@ After compiling, the corresponding platform name folder will be created in the t
##### Binary

```
wget https://github.com/brokercap/Bifrost/releases/download/v2.3.5-beta/bifrost_v2.3.5-beta_Linux-amd64-bin.tar.gz
wget https://github.com/brokercap/Bifrost/releases/download/v2.3.6-beta/bifrost_v2.3.6-beta_Linux-amd64-bin.tar.gz
tar -zxvf bifrost_v2.3.5-beta_Linux-amd64-bin.tar.gz
tar -zxvf bifrost_v2.3.6-beta_Linux-amd64-bin.tar.gz
cd bifrost_v2.3.5-beta_Linux-amd64-bin/bin && chmod a+x ./Bifrost*
cd bifrost_v2.3.6-beta_Linux-amd64-bin/bin && chmod a+x ./Bifrost*
```

Expand Down
6 changes: 3 additions & 3 deletions README.MD
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,11 @@ make install prefix=./target
##### 二进制文件安装
`````sh

wget https://github.com/brokercap/Bifrost/releases/download/v2.3.5-beta/bifrost_v2.3.5-beta_Linux-amd64-bin.tar.gz
wget https://github.com/brokercap/Bifrost/releases/download/v2.3.6-beta/bifrost_v2.3.6-beta_Linux-amd64-bin.tar.gz

tar -zxvf bifrost_v2.3.5-beta_Linux-amd64-bin.tar.gz
tar -zxvf bifrost_v2.3.6-beta_Linux-amd64-bin.tar.gz

cd bifrost_v2.3.5-beta_Linux-amd64-bin/bin && chmod a+x ./Bifrost*
cd bifrost_v2.3.6-beta_Linux-amd64-bin/bin && chmod a+x ./Bifrost*

`````

Expand Down
10 changes: 10 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
v2.3.8-beta 2024-11-05
1. fix mysql select tinyint(1) , value > 1 , transfer to bool ,result false bug

v2.3.7-beta 2024-10-16
1. output kakfa tableMap add binlog_timestamp field
2. CHARACTER_OCTET_LENGTH add support for int64 and int32 in mysql parser

v2.3.6-beta 2024-04-21
1. input varchar(255) to output starrocks varchar(765)

v2.3.5-beta 2024-04-05
1. fixed output starrocks varchar(255) tansfer error bug https://github.com/brokercap/Bifrost/issues/266
2. 修复mongo数据源全量功能无效的bug https://github.com/brokercap/Bifrost/issues/272
Expand Down
2 changes: 1 addition & 1 deletion config/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ limitations under the License.

package config

const VERSION = "v2.3.5-beta"
const VERSION = "v2.3.8-beta"
1 change: 1 addition & 0 deletions plugin/driver/table_map_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ func (c *PluginDataType) ToTableMapObject() (data map[string]interface{}, err er
} else {
data["bifrost_query"] = c.Query
}
data["binlog_timestamp"] = fmt.Sprint(c.Timestamp)
data["binlog_event_type"] = c.EventType
data["bifrost_pri"] = strings.Join(c.Pri, ",")
data["bifrost_database"] = c.SchemaName
Expand Down

0 comments on commit e8dabf2

Please sign in to comment.