Files
go-common/app/service/main/up/dao/data/dao.go
2019-04-22 18:49:16 +08:00

25 lines
417 B
Go

package data
import (
"go-common/app/service/main/up/conf"
"go-common/library/database/hbase.v2"
"time"
)
//Dao hbase dao
type Dao struct {
c *conf.Config
hbase *hbase.Client
hbaseTimeOut time.Duration
}
//New create dao
func New(c *conf.Config) (d *Dao) {
d = &Dao{
c: c,
hbase: hbase.NewClient(&c.HBase.Config),
hbaseTimeOut: time.Millisecond * 500,
}
return
}