Skip to content

Commit

Permalink
feat: script
Browse files Browse the repository at this point in the history
  • Loading branch information
zenghur committed Jun 15, 2021
1 parent abeccd2 commit 9c2a0a5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ require (
github.com/aliyun/aliyun-tablestore-go-sdk/v5 v5.0.6
github.com/baiyubin/aliyun-sts-go-sdk v0.0.0-20180326062324-cfa1a18b161f // indirect
github.com/gin-gonic/gin v1.7.2
github.com/golang/protobuf v1.3.3
github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22
github.com/influxdata/influxdb-client-go/v2 v2.4.0
github.com/sirupsen/logrus v1.5.0
Expand Down
10 changes: 5 additions & 5 deletions script/tablestore.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,31 +44,31 @@ func InitOTS(env *env.Env) {
request.IndexName = idx

schemas := []*tablestore.FieldSchema{
&tablestore.FieldSchema{
{
FieldName: proto.String("profile_type"),
FieldType: tablestore.FieldType_KEYWORD,
Index: proto.Bool(true),
EnableSortAndAgg: proto.Bool(true),
},
&tablestore.FieldSchema{
{
FieldName: proto.String("create_time"),
FieldType: tablestore.FieldType_LONG,
Index: proto.Bool(true),
EnableSortAndAgg: proto.Bool(true),
},
&tablestore.FieldSchema{
{
FieldName: proto.String("service"),
FieldType: tablestore.FieldType_KEYWORD,
Index: proto.Bool(true),
EnableSortAndAgg: proto.Bool(true),
},
&tablestore.FieldSchema{
{
FieldName: proto.String("ip"),
FieldType: tablestore.FieldType_KEYWORD,
Index: proto.Bool(true),
EnableSortAndAgg: proto.Bool(true),
},
&tablestore.FieldSchema{
{
FieldName: proto.String("host"),
FieldType: tablestore.FieldType_KEYWORD,
Index: proto.Bool(true),
Expand Down

0 comments on commit 9c2a0a5

Please sign in to comment.