fix(keeper): fix endpoint value too long for column/tag
This commit is contained in:
parent
fb8a10e717
commit
f1902dd69c
|
@ -23,8 +23,8 @@ var adapterLog = log.GetLogger("ADP")
|
|||
type adapterReqType int
|
||||
|
||||
const (
|
||||
rest adapterReqType = iota // 0 - rest
|
||||
ws // 1 - ws
|
||||
rest adapterReqType = iota
|
||||
ws
|
||||
)
|
||||
|
||||
type Adapter struct {
|
||||
|
@ -210,7 +210,7 @@ var adapterTableSql = "create stable if not exists `adapter_requests` (" +
|
|||
"`other_fail` int unsigned, " +
|
||||
"`query_in_process` int unsigned, " +
|
||||
"`write_in_process` int unsigned ) " +
|
||||
"tags (`endpoint` varchar(32), `req_type` tinyint unsigned )"
|
||||
"tags (`endpoint` varchar(255), `req_type` tinyint unsigned )"
|
||||
|
||||
func (a *Adapter) createTable() error {
|
||||
if a.conn == nil {
|
||||
|
|
|
@ -749,7 +749,7 @@ func (gm *GeneralMetric) initColumnSeqMap() error {
|
|||
|
||||
func (gm *GeneralMetric) createSTables() error {
|
||||
var createTableSql = "create stable if not exists taosd_cluster_basic " +
|
||||
"(ts timestamp, first_ep varchar(100), first_ep_dnode_id INT, cluster_version varchar(20)) " +
|
||||
"(ts timestamp, first_ep varchar(255), first_ep_dnode_id INT, cluster_version varchar(20)) " +
|
||||
"tags (cluster_id varchar(50))"
|
||||
|
||||
if gm.conn == nil {
|
||||
|
@ -760,8 +760,8 @@ func (gm *GeneralMetric) createSTables() error {
|
|||
return err
|
||||
}
|
||||
|
||||
createTableSql = "create stable if not exists taos_slow_sql_detail" +
|
||||
" (start_ts TIMESTAMP, request_id BIGINT UNSIGNED PRIMARY KEY, query_time INT, code INT, error_info varchar(128), " +
|
||||
createTableSql = "create stable if not exists taos_slow_sql_detail " +
|
||||
"(start_ts TIMESTAMP, request_id BIGINT UNSIGNED PRIMARY KEY, query_time INT, code INT, error_info varchar(128), " +
|
||||
"type TINYINT, rows_num BIGINT, sql varchar(16384), process_name varchar(32), process_id varchar(32)) " +
|
||||
"tags (db varchar(1024), `user` varchar(32), ip varchar(32), cluster_id varchar(32))"
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ var dnodeEpLen = strconv.Itoa(255)
|
|||
|
||||
var CreateClusterInfoSql = "create table if not exists cluster_info (" +
|
||||
"ts timestamp, " +
|
||||
"first_ep binary(134), " +
|
||||
"first_ep binary(255), " +
|
||||
"first_ep_dnode_id int, " +
|
||||
"version binary(12), " +
|
||||
"master_uptime float, " +
|
||||
|
|
|
@ -322,7 +322,7 @@ func (cmd *Command) TransferTaosdClusterBasicInfo() error {
|
|||
delta := time.Hour * 24 * 10
|
||||
|
||||
var createTableSql = "create stable if not exists taosd_cluster_basic " +
|
||||
"(ts timestamp, first_ep varchar(100), first_ep_dnode_id INT, cluster_version varchar(20)) " +
|
||||
"(ts timestamp, first_ep varchar(255), first_ep_dnode_id INT, cluster_version varchar(20)) " +
|
||||
"tags (cluster_id varchar(50))"
|
||||
|
||||
if _, err := cmd.conn.Exec(ctx, createTableSql, util.GetQidOwn()); err != nil {
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
package system
|
||||
|
||||
import (
|
||||
"testing"
|
||||
)
|
||||
|
||||
func TestEmpty(t *testing.T) {
|
||||
}
|
Loading…
Reference in New Issue