forked from IceFireDB/IceFireDB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathglobal.go
50 lines (39 loc) · 952 Bytes
/
global.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/*
* @Author: gitsrc
* @Date: 2021-03-10 11:17:13
* @LastEditors: gitsrc
* @LastEditTime: 2021-08-20 10:47:35
* @FilePath: /IceFireDB/global.go
*/
package main
import (
"fmt"
lediscfg "github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/ledis"
"github.com/syndtr/goleveldb/leveldb"
rafthub "github.com/tidwall/uhaha"
)
// BuildDate: Binary file compilation time
// BuildVersion: Binary compiled GIT version
var (
BuildDate string
BuildVersion string
)
var (
db *leveldb.DB
le *ledis.Ledis
ldb *ledis.DB
ldsCfg *lediscfg.Config
serverInfo *info
respClientNum int64
)
var conf rafthub.Config // raft config
var banner string
func init() {
banner = ` ____ _____ ___ ___
/ _/______ / __(_)______ / _ \/ _ )
_/ // __/ -_) _// / __/ -_) // / _ |
/___/\__/\__/_/ /_/_/ \__/____/____/
`
fmt.Println(banner)
}