diff --git a/chains/cosmos/exporter/exporter.go b/chains/cosmos/exporter/exporter.go index de70860..1a2c56e 100644 --- a/chains/cosmos/exporter/exporter.go +++ b/chains/cosmos/exporter/exporter.go @@ -28,7 +28,7 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } @@ -36,9 +36,9 @@ func Start(log *zap.Logger) { // denom gagues count := 0 for i := 0; i < len(metric.DenomList)*3; i += 3 { - gaugesDenom[i] = metric.NewGauge("exporter_balances", metric.DenomList[count], "") - gaugesDenom[i+1] = metric.NewGauge("exporter_commission", metric.DenomList[count], "") - gaugesDenom[i+2] = metric.NewGauge("exporter_rewards", metric.DenomList[count], "") + gaugesDenom[i] = utils.NewGauge("exporter_balances", metric.DenomList[count], "") + gaugesDenom[i+1] = utils.NewGauge("exporter_commission", metric.DenomList[count], "") + gaugesDenom[i+2] = utils.NewGauge("exporter_rewards", metric.DenomList[count], "") prometheus.MustRegister(gaugesDenom[i]) prometheus.MustRegister(gaugesDenom[i+1]) prometheus.MustRegister(gaugesDenom[i+2]) @@ -49,7 +49,7 @@ func Start(log *zap.Logger) { // labels labels := []string{"chainId", "moniker", "operatorAddress", "accountAddress", "consHexAddress"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -71,6 +71,7 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: " +fmt.Sprint(currentBlockHeight))) diff --git a/chains/cosmos/exporter/metric/types.go b/chains/cosmos/exporter/metric/types.go deleted file mode 100644 index 52296e1..0000000 --- a/chains/cosmos/exporter/metric/types.go +++ /dev/null @@ -1,34 +0,0 @@ -package metric - -import ( - "github.com/prometheus/client_golang/prometheus" -) - -var ( - -) - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} - diff --git a/chains/emoney/exporter/exporter.go b/chains/emoney/exporter/exporter.go index 6e2c574..3ae5006 100644 --- a/chains/emoney/exporter/exporter.go +++ b/chains/emoney/exporter/exporter.go @@ -28,7 +28,7 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } @@ -36,9 +36,9 @@ func Start(log *zap.Logger) { // denom gagues count := 0 for i := 0; i < len(metric.DenomList)*3; i += 3 { - gaugesDenom[i] = metric.NewGauge("exporter_balances", metric.DenomList[count], "") - gaugesDenom[i+1] = metric.NewGauge("exporter_commission", metric.DenomList[count], "") - gaugesDenom[i+2] = metric.NewGauge("exporter_rewards", metric.DenomList[count], "") + gaugesDenom[i] = utils.NewGauge("exporter_balances", metric.DenomList[count], "") + gaugesDenom[i+1] = utils.NewGauge("exporter_commission", metric.DenomList[count], "") + gaugesDenom[i+2] = utils.NewGauge("exporter_rewards", metric.DenomList[count], "") prometheus.MustRegister(gaugesDenom[i]) prometheus.MustRegister(gaugesDenom[i+1]) prometheus.MustRegister(gaugesDenom[i+2]) @@ -49,7 +49,7 @@ func Start(log *zap.Logger) { // labels labels := []string{"chainId", "moniker", "operatorAddress", "accountAddress", "consHexAddress"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -71,6 +71,7 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: " +fmt.Sprint(currentBlockHeight))) diff --git a/chains/emoney/exporter/metric/types.go b/chains/emoney/exporter/metric/types.go deleted file mode 100644 index fccbb18..0000000 --- a/chains/emoney/exporter/metric/types.go +++ /dev/null @@ -1,35 +0,0 @@ -package metric - -import ( - - "github.com/prometheus/client_golang/prometheus" -) - -var ( - -) - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} - diff --git a/chains/iov/exporter/exporter.go b/chains/iov/exporter/exporter.go index 2324f0c..30d7a8e 100644 --- a/chains/iov/exporter/exporter.go +++ b/chains/iov/exporter/exporter.go @@ -7,6 +7,7 @@ import ( rpc "github.com/node-a-team/Cosmos-IE/chains/iov/getData/rpc" metric "github.com/node-a-team/Cosmos-IE/chains/iov/exporter/metric" + utils "github.com/node-a-team/Cosmos-IE/utils" "github.com/prometheus/client_golang/prometheus" ) @@ -25,13 +26,13 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } // labels labels := []string{"chainId"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -53,6 +54,7 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: " +fmt.Sprint(currentBlockHeight))) diff --git a/chains/iov/exporter/metric/types.go b/chains/iov/exporter/metric/types.go deleted file mode 100644 index 52296e1..0000000 --- a/chains/iov/exporter/metric/types.go +++ /dev/null @@ -1,34 +0,0 @@ -package metric - -import ( - "github.com/prometheus/client_golang/prometheus" -) - -var ( - -) - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} - diff --git a/chains/iov/getData/rpc/rpc.go b/chains/iov/getData/rpc/rpc.go index 83fc8c3..95f07db 100644 --- a/chains/iov/getData/rpc/rpc.go +++ b/chains/iov/getData/rpc/rpc.go @@ -43,10 +43,8 @@ func GetData(blockHeight int64, consHexAddr string, log *zap.Logger) *RPCData { log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Commit Data"),) } - fmt.Println("consHexAddr: ", consHexAddr) rd.Commit = getCommit(commitData, consHexAddr) - return rd } diff --git a/chains/iov/main.go b/chains/iov/main.go index 2294b98..1991202 100644 --- a/chains/iov/main.go +++ b/chains/iov/main.go @@ -16,9 +16,6 @@ func Main(port string) { log,_ := zap.NewDevelopment() defer log.Sync() -// cfg.ConfigPath = os.Args[1] - -// port := cfg.Init() rpc.OpenSocket(log) http.Handle("/metrics", promhttp.Handler()) diff --git a/chains/iris/exporter/exporter.go b/chains/iris/exporter/exporter.go index 919b6a5..c1d8908 100644 --- a/chains/iris/exporter/exporter.go +++ b/chains/iris/exporter/exporter.go @@ -5,10 +5,10 @@ import ( "go.uber.org/zap" "time" - metric "github.com/node-a-team/cosmos_metric/chains/iris/exporter/metric" - rest "github.com/node-a-team/cosmos_metric/chains/iris/getData/rest" - rpc "github.com/node-a-team/cosmos_metric/chains/iris/getData/rpc" - utils "github.com/node-a-team/cosmos_metric/utils" + metric "github.com/node-a-team/Cosmos-IE/chains/iris/exporter/metric" + rest "github.com/node-a-team/Cosmos-IE/chains/iris/getData/rest" + rpc "github.com/node-a-team/Cosmos-IE/chains/iris/getData/rpc" + utils "github.com/node-a-team/Cosmos-IE/utils" "github.com/prometheus/client_golang/prometheus" ) @@ -26,16 +26,16 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } // denom gagues count := 0 for i := 0; i < len(metric.DenomList)*3; i += 3 { - gaugesDenom[i] = metric.NewGauge("exporter_balances", metric.DenomList[count], "") - gaugesDenom[i+1] = metric.NewGauge("exporter_commission", metric.DenomList[count], "") - gaugesDenom[i+2] = metric.NewGauge("exporter_rewards", metric.DenomList[count], "") + gaugesDenom[i] = utils.NewGauge("exporter_balances", metric.DenomList[count], "") + gaugesDenom[i+1] = utils.NewGauge("exporter_commission", metric.DenomList[count], "") + gaugesDenom[i+2] = utils.NewGauge("exporter_rewards", metric.DenomList[count], "") prometheus.MustRegister(gaugesDenom[i]) prometheus.MustRegister(gaugesDenom[i+1]) prometheus.MustRegister(gaugesDenom[i+2]) @@ -45,7 +45,7 @@ func Start(log *zap.Logger) { // labels labels := []string{"chainId", "moniker", "operatorAddress", "accountAddress", "consHexAddress"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -65,6 +65,7 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: "+fmt.Sprint(currentBlockHeight))) restData, consHexAddr := rest.GetData(currentBlockHeight, log) diff --git a/chains/iris/exporter/metric/metric.go b/chains/iris/exporter/metric/metric.go index 5aaec4b..c182e6b 100644 --- a/chains/iris/exporter/metric/metric.go +++ b/chains/iris/exporter/metric/metric.go @@ -3,9 +3,9 @@ package metric import ( "go.uber.org/zap" - rest "github.com/node-a-team/cosmos_metric/chains/iris/getData/rest" - rpc "github.com/node-a-team/cosmos_metric/chains/iris/getData/rpc" - utils "github.com/node-a-team/cosmos_metric/utils" + rest "github.com/node-a-team/Cosmos-IE/chains/iris/getData/rest" + rpc "github.com/node-a-team/Cosmos-IE/chains/iris/getData/rpc" + utils "github.com/node-a-team/Cosmos-IE/utils" ) var ( diff --git a/chains/iris/exporter/metric/types.go b/chains/iris/exporter/metric/types.go deleted file mode 100644 index bc5dcc2..0000000 --- a/chains/iris/exporter/metric/types.go +++ /dev/null @@ -1,31 +0,0 @@ -package metric - -import ( - "github.com/prometheus/client_golang/prometheus" -) - -var () - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} diff --git a/chains/iris/getData/rest/delegations.go b/chains/iris/getData/rest/delegations.go index 7b1ec33..056b38a 100644 --- a/chains/iris/getData/rest/delegations.go +++ b/chains/iris/getData/rest/delegations.go @@ -5,7 +5,7 @@ import ( "go.uber.org/zap" "strings" - utils "github.com/node-a-team/cosmos_metric/utils" + utils "github.com/node-a-team/Cosmos-IE/utils" ) /* diff --git a/chains/iris/getData/rest/inflation.go b/chains/iris/getData/rest/inflation.go index e930c9d..4c9f940 100644 --- a/chains/iris/getData/rest/inflation.go +++ b/chains/iris/getData/rest/inflation.go @@ -5,7 +5,7 @@ import ( "go.uber.org/zap" "strings" - utils "github.com/node-a-team/cosmos_metric/utils" + utils "github.com/node-a-team/Cosmos-IE/utils" ) type param struct { diff --git a/chains/iris/getData/rest/rest.go b/chains/iris/getData/rest/rest.go index d76d1f8..1db9712 100644 --- a/chains/iris/getData/rest/rest.go +++ b/chains/iris/getData/rest/rest.go @@ -4,7 +4,7 @@ import ( "go.uber.org/zap" "os/exec" - utils "github.com/node-a-team/cosmos_metric/utils" + utils "github.com/node-a-team/Cosmos-IE/utils" ) var ( diff --git a/chains/iris/main.go b/chains/iris/main.go index eaeb60a..e1dae5f 100644 --- a/chains/iris/main.go +++ b/chains/iris/main.go @@ -7,8 +7,8 @@ import ( "github.com/prometheus/client_golang/prometheus/promhttp" - "github.com/node-a-team/cosmos_metric/chains/iris/exporter" - rpc "github.com/node-a-team/cosmos_metric/chains/iris/getData/rpc" + "github.com/node-a-team/Cosmos-IE/chains/iris/exporter" + rpc "github.com/node-a-team/Cosmos-IE/chains/iris/getData/rpc" ) func Main(port string) { @@ -16,9 +16,6 @@ func Main(port string) { log, _ := zap.NewDevelopment() defer log.Sync() -// cfg.ConfigPath = os.Args[1] - -// port := cfg.Init() rpc.OpenSocket(log) http.Handle("/metrics", promhttp.Handler()) diff --git a/chains/kava/exporter/exporter.go b/chains/kava/exporter/exporter.go index dc7a86c..171208d 100644 --- a/chains/kava/exporter/exporter.go +++ b/chains/kava/exporter/exporter.go @@ -5,10 +5,10 @@ import ( "time" "go.uber.org/zap" - rpc "github.com/node-a-team/cosmos_metric/chains/kava/getData/rpc" - rest "github.com/node-a-team/cosmos_metric/chains/kava/getData/rest" - metric "github.com/node-a-team/cosmos_metric/chains/kava/exporter/metric" - utils "github.com/node-a-team/cosmos_metric/utils" + rpc "github.com/node-a-team/Cosmos-IE/chains/kava/getData/rpc" + rest "github.com/node-a-team/Cosmos-IE/chains/kava/getData/rest" + metric "github.com/node-a-team/Cosmos-IE/chains/kava/exporter/metric" + utils "github.com/node-a-team/Cosmos-IE/utils" "github.com/prometheus/client_golang/prometheus" ) @@ -28,7 +28,7 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } @@ -36,9 +36,9 @@ func Start(log *zap.Logger) { // denom gagues count := 0 for i := 0; i < len(metric.DenomList)*3; i += 3 { - gaugesDenom[i] = metric.NewGauge("exporter_balances", metric.DenomList[count], "") - gaugesDenom[i+1] = metric.NewGauge("exporter_commission", metric.DenomList[count], "") - gaugesDenom[i+2] = metric.NewGauge("exporter_rewards", metric.DenomList[count], "") + gaugesDenom[i] = utils.NewGauge("exporter_balances", metric.DenomList[count], "") + gaugesDenom[i+1] = utils.NewGauge("exporter_commission", metric.DenomList[count], "") + gaugesDenom[i+2] = utils.NewGauge("exporter_rewards", metric.DenomList[count], "") prometheus.MustRegister(gaugesDenom[i]) prometheus.MustRegister(gaugesDenom[i+1]) prometheus.MustRegister(gaugesDenom[i+2]) @@ -49,7 +49,7 @@ func Start(log *zap.Logger) { // labels labels := []string{"chainId", "moniker", "operatorAddress", "accountAddress", "consHexAddress"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -71,6 +71,7 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: " +fmt.Sprint(currentBlockHeight))) diff --git a/chains/kava/exporter/metric/metric.go b/chains/kava/exporter/metric/metric.go index 25a74af..bb2014d 100644 --- a/chains/kava/exporter/metric/metric.go +++ b/chains/kava/exporter/metric/metric.go @@ -1,15 +1,11 @@ package metric import ( - -// "fmt" -// "encoding/hex" -// sdk "github.com/cosmos/cosmos-sdk/types" "go.uber.org/zap" - rest "github.com/node-a-team/cosmos_metric/chains/kava/getData/rest" - rpc "github.com/node-a-team/cosmos_metric/chains/kava/getData/rpc" - utils "github.com/node-a-team/cosmos_metric/utils" + rest "github.com/node-a-team/Cosmos-IE/chains/kava/getData/rest" + rpc "github.com/node-a-team/Cosmos-IE/chains/kava/getData/rpc" + utils "github.com/node-a-team/Cosmos-IE/utils" ) var ( diff --git a/chains/kava/exporter/metric/types.go b/chains/kava/exporter/metric/types.go deleted file mode 100644 index 828a54d..0000000 --- a/chains/kava/exporter/metric/types.go +++ /dev/null @@ -1,39 +0,0 @@ -package metric - -import ( - -// "fmt" -// "encoding/hex" -// sdk "github.com/cosmos/cosmos-sdk/types" - - "github.com/prometheus/client_golang/prometheus" -) - -var ( - -) - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} - diff --git a/chains/terra/exporter/exporter.go b/chains/terra/exporter/exporter.go index 27e55cf..30cd778 100644 --- a/chains/terra/exporter/exporter.go +++ b/chains/terra/exporter/exporter.go @@ -28,7 +28,7 @@ func Start(log *zap.Logger) { // nomal guages for i := 0; i < len(gaugesNamespaceList); i++ { - gauges[i] = metric.NewGauge("exporter", gaugesNamespaceList[i], "") + gauges[i] = utils.NewGauge("exporter", gaugesNamespaceList[i], "") prometheus.MustRegister(gauges[i]) } @@ -36,9 +36,9 @@ func Start(log *zap.Logger) { // denom gagues count := 0 for i := 0; i < len(metric.DenomList)*3; i += 3 { - gaugesDenom[i] = metric.NewGauge("exporter_balances", metric.DenomList[count], "") - gaugesDenom[i+1] = metric.NewGauge("exporter_commission", metric.DenomList[count], "") - gaugesDenom[i+2] = metric.NewGauge("exporter_rewards", metric.DenomList[count], "") + gaugesDenom[i] = utils.NewGauge("exporter_balances", metric.DenomList[count], "") + gaugesDenom[i+1] = utils.NewGauge("exporter_commission", metric.DenomList[count], "") + gaugesDenom[i+2] = utils.NewGauge("exporter_rewards", metric.DenomList[count], "") prometheus.MustRegister(gaugesDenom[i]) prometheus.MustRegister(gaugesDenom[i+1]) prometheus.MustRegister(gaugesDenom[i+2]) @@ -49,7 +49,7 @@ func Start(log *zap.Logger) { // labels labels := []string{"chainId", "moniker", "operatorAddress", "accountAddress", "consHexAddress"} - gaugesForLabel := metric.NewCounterVec("exporter", "labels", "", labels) + gaugesForLabel := utils.NewCounterVec("exporter", "labels", "", labels) prometheus.MustRegister(gaugesForLabel) @@ -71,9 +71,9 @@ func Start(log *zap.Logger) { if previousBlockHeight != currentBlockHeight { + fmt.Println("") log.Info("RPC-Server", zap.Bool("Success", true), zap.String("err", "nil"), zap.String("Get Data", "Block Height: " +fmt.Sprint(currentBlockHeight))) - restData, consHexAddr := rest.GetData(currentBlockHeight, log) rpcData := rpc.GetData(currentBlockHeight, consHexAddr, log) diff --git a/chains/terra/exporter/metric/types.go b/chains/terra/exporter/metric/types.go deleted file mode 100644 index fccbb18..0000000 --- a/chains/terra/exporter/metric/types.go +++ /dev/null @@ -1,35 +0,0 @@ -package metric - -import ( - - "github.com/prometheus/client_golang/prometheus" -) - -var ( - -) - -func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { - result := prometheus.NewGauge( - prometheus.GaugeOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - ) - - return result -} - -func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { - result := prometheus.NewCounterVec( - prometheus.CounterOpts{ - Namespace: "" + nameSpace, - Name: "" + name, - Help: "" + help, - }, - labels, - ) - return *result -} - diff --git a/cmd/root.go b/cmd/root.go index b3e7b90..07ad4ab 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -31,8 +31,9 @@ var ( // rootCmd represents the base command when called without any subcommands var rootCmd = &cobra.Command{ Use: "Cosmos-IE", - Short: "root short ", - Long: `root 설명충`, + Short: "", + Long: `Integrated Exporter for CosmosSDK`, + // Uncomment the following line if your bare application // has an action associated with it: // Run: func(cmd *cobra.Command, args []string) { }, diff --git a/cmd/run.go b/cmd/run.go index a1a4e81..907d358 100644 --- a/cmd/run.go +++ b/cmd/run.go @@ -72,10 +72,6 @@ func check_chain() { } - - fmt.Println("============================================") - fmt.Println(chain, operAddr, consHexAddr) - if (operAddr == "" && consHexAddr == "") || (operAddr != "" && consHexAddr != "") { log.Fatal("[Error] Enter only one of --oper-addr or --cons-addr") } else if chain == "iov" && consHexAddr == "" { diff --git a/cmd/version.go b/cmd/version.go index 4f0ae92..8448367 100644 --- a/cmd/version.go +++ b/cmd/version.go @@ -22,17 +22,18 @@ import ( ) var ( - version string = "1.0.0" - -// versionCmd represents the version command -var versionCmd = &cobra.Command{ - Use: "version", - Short: "Software version", - Long: ``, - Run: func(cmd *cobra.Command, args []string) { - fmt.Println("Cosmos-IE v" +version) - }, -} + version, tendermintVersion, cosmosSDKVersion string = "v1.0.0", "v0.32.9", "v0.37.6" + + // versionCmd represents the version command + versionCmd = &cobra.Command{ + Use: "version", + Short: "Software version", + Long: ``, + Run: func(cmd *cobra.Command, args []string) { + fmt.Printf("Cosmos-IE %s(Tendermint: %s, CosmosSDK: %s)\n", version, tendermintVersion, cosmosSDKVersion) + }, + } +) func init() { rootCmd.AddCommand(versionCmd) diff --git a/go.mod b/go.mod index e601c8f..3dd595d 100644 --- a/go.mod +++ b/go.mod @@ -1,26 +1,15 @@ -module github.com/node-a-team/cosmos_metric +module github.com/node-a-team/Cosmos-IE go 1.14 require ( - github.com/BurntSushi/toml v0.3.1 github.com/cosmos/cosmos-sdk v0.37.6 github.com/e-money/em-ledger v0.6.1 - github.com/fsnotify/fsnotify v1.4.9 // indirect - github.com/irisnet/irishub v0.16.1 github.com/mitchellh/go-homedir v1.1.0 - github.com/mitchellh/mapstructure v1.2.2 // indirect - github.com/pelletier/go-toml v1.6.0 // indirect github.com/prometheus/client_golang v1.5.1 - github.com/spf13/afero v1.2.2 // indirect - github.com/spf13/cast v1.3.1 // indirect github.com/spf13/cobra v0.0.7 github.com/spf13/viper v1.6.2 github.com/tendermint/tendermint v0.32.9 github.com/terra-project/core v0.3.3 go.uber.org/zap v1.14.1 - golang.org/x/sys v0.0.0-20200331124033-c3d80250170d // indirect - golang.org/x/text v0.3.2 // indirect - gopkg.in/ini.v1 v1.55.0 // indirect - gopkg.in/yaml.v2 v2.2.8 // indirect ) diff --git a/go.sum b/go.sum index a0b3a07..27cafd8 100644 --- a/go.sum +++ b/go.sum @@ -1,9 +1,7 @@ bou.ke/monkey v1.0.1/go.mod h1:FgHuK96Rv2Nlf+0u1OOVDpCMdsWyOFmeeketDHE7LIg= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= -github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= -github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= github.com/Workiva/go-datastructures v1.0.50/go.mod h1:Z+F2Rca0qCsVYDS8z7bAGm8f3UkzuWYS/oBZz5a7VVA= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= @@ -44,7 +42,6 @@ github.com/cosmos/cosmos-sdk v0.37.3/go.mod h1:dAwYeOJ5ybRZg/OdRfiDy8q/cZq/GXQp9 github.com/cosmos/cosmos-sdk v0.37.6 h1:l7urou9aTPqW/x3Hq+SAWn6OHDzjma+1OVi0TT+O36M= github.com/cosmos/cosmos-sdk v0.37.6/go.mod h1:63Y8V75rRDzUrtRUwy+5cBOy5mr6xytI11PBk53tBrE= github.com/cosmos/go-bip39 v0.0.0-20180618194314-52158e4697b8/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= -github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d h1:49RLWk1j44Xu4fjHb6JFYmeUnDORVwHNkDxaQ0ctCVU= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/ledger-cosmos-go v0.10.3/go.mod h1:J8//BsAGTo3OC/vDLjMRFLW6q0WAaXvHnVc7ZmE8iUY= github.com/cosmos/ledger-go v0.9.2/go.mod h1:oZJ2hHAZROdlHiwTg4t7kP+GKIIkBT+o6c9QWFanOyI= @@ -58,26 +55,18 @@ github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZm github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/e-money/em-ledger v0.6.1 h1:qteyFDwoOSdzTGlVk4wrIb4rWQf1UKhld2+XuNnHIBU= github.com/e-money/em-ledger v0.6.1/go.mod h1:pqiIZMNll6LTJM5jDW1FwLiqn0ZjgvdwiGxBayls7a8= -github.com/emicklei/proto v1.6.5/go.mod h1:Dqn751twH9SasYqvA59Lb9Hz+itoJgmMoivX6k7OPZc= github.com/emirpasic/gods v1.12.0/go.mod h1:YfzfFFoVP/catgzJb4IKIqXjX78Ha8FMSDh3ymbK86o= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/etcd-io/bbolt v1.3.2/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= -github.com/etcd-io/bbolt v1.3.3 h1:gSJmxrs37LgTqR/oyJBWok6k6SvXEUerFTbltIhXkBM= github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= -github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51 h1:0JZ+dUmQeA8IIVUMzysrX4/AKuQwWhV2dYQuPZdvdSQ= github.com/facebookgo/ensure v0.0.0-20160127193407-b4ab57deab51/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64= -github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= github.com/facebookgo/stack v0.0.0-20160209184415-751773369052/go.mod h1:UbMTZqLaRiH3MsBH8va0n7s1pQYcu3uTb8G4tygF4Zg= -github.com/facebookgo/subset v0.0.0-20150612182917-8dac2c3c4870 h1:E2s37DuLxFhQDg5gKsWoLBOB0n+ZW8s599zru8FJ2/Y= github.com/facebookgo/subset v0.0.0-20150612182917-8dac2c3c4870/go.mod h1:5tD+neXqOorC30/tWg0LCSkrqj/AR6gu8yY8/fpw1q0= github.com/fortytw2/leaktest v1.2.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= -github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= -github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= -github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/go-kit/kit v0.6.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= @@ -86,14 +75,12 @@ github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2 github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0 h1:MP4Eh7ZCb31lleYCFuwm0oe4/YGak+5l1vA2NOE80nA= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.0/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.1 h1:DqDEcV5aeaTmdFBePNpYsp3FlcVH/2ISVVM9Qf8PSls= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= -github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= @@ -105,20 +92,14 @@ github.com/golang/protobuf v1.3.2 h1:6nsPYzhq5kReh6QImI3k5qWzO4PEbvbIW2cwSfR/6xs github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/snappy v0.0.1 h1:Qgr9rKW7uDUkrbSmQeiDsGa8SjGyCOGtuasMWwvp2P4= github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/google/btree v1.0.0 h1:0udJVsspx3VBr5FwtLhQQtuAsVc79tTq0ocGIPAU6qo= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= -github.com/google/go-cmp v0.4.0 h1:xsAVV57WRhGj6kEIi8ReJzQlHHqcBYCElAvkovg3B/4= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= -github.com/google/gofuzz v1.0.0 h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= -github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 h1:EGx4pi6eqNxGaHF6qqu48+N2wcFQ5qg5FXgOdqsJ5d8= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= -github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= -github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.7.0/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.7.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/websocket v1.2.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= @@ -130,20 +111,14 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgf github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= -github.com/hpcloud/tail v1.0.0 h1:nfCOvKYfkgYP8hkirhJocXT2+zOD8yUNjXaWfTlyFKI= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= -github.com/inconshreveable/mousetrap v1.0.0 h1:Z8tu5sraLXCXIcARxBp/8cbvlwVa7Z1NHg9XEKhtSvM= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/irisnet/irishub v0.16.1 h1:vZQxRVMPUSqVGj3KN9aBvmcNADYf7uVp14q0iKrPZuI= -github.com/irisnet/irishub v0.16.1/go.mod h1:S6Y1vyjutENBFt7mS8UTh6L+91TpenYtmfu0KtND9I8= github.com/jessevdk/go-flags v0.0.0-20141203071132-1679536dcc89/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= @@ -151,29 +126,22 @@ github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQL github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= -github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= -github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/libp2p/go-buffer-pool v0.0.2 h1:QNK2iAFa8gjAe1SPz6mHSMuCcjs+X1wlHzeOSqcmlfs= github.com/libp2p/go-buffer-pool v0.0.2/go.mod h1:MvaB6xw5vOrDl8rYZGLFdKAuk/hRoRZd1Vi32+RXyFM= github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.1 h1:ZC2Vc7/ZFkGmsVC9KvOjumD+G5lXy2RtTKyzRKO2BQ4= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= -github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.6/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/mapstructure v1.1.2 h1:fmNYVwqnSfB9mZU6OS2O6GsXM+wcskZDuKQzvN1EDeE= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.2.2 h1:dxe5oCinTXiTIcfgmZecdCzPmAJKd46KsCWc35r0TV4= -github.com/mitchellh/mapstructure v1.2.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= @@ -181,9 +149,7 @@ github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3Rllmb github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.7.0 h1:WSHQ+IS43OoUrWtD1/bbclrwK8TTH5hzp+umCiuxHgs= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/gomega v1.4.3 h1:RE1xgDvH7imwFD45h+u2SgIfERHlS2yNG4DObb5BSKU= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/otiai10/copy v1.0.2/go.mod h1:c7RpqBkwMom4bYTSkLSym4VSJz/XtncWRAj/J4PEIMY= github.com/otiai10/curr v0.0.0-20150429015615-9b4961190c95/go.mod h1:9qAhocn7zKJG+0mI8eUu6xqkFDYS2kb2saOteoSB3cE= @@ -192,12 +158,9 @@ github.com/otiai10/mint v1.2.4/go.mod h1:d+b7n/0R3tdyUYYylALXpWQ/kTN+QobSq/4SRGB github.com/otiai10/mint v1.3.0/go.mod h1:F5AjcsTsWUqX+Na9fpHb52P8pcRX2CI6A3ctIT91xUo= github.com/pelletier/go-toml v1.2.0 h1:T5zMGML61Wp+FlcbWjRDT7yAxhJNAiPPLOFECq181zc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= -github.com/pelletier/go-toml v1.6.0 h1:aetoXYr0Tv7xRU/V4B4IZJ2QcbtMUFoNb3ORp7TzIK4= -github.com/pelletier/go-toml v1.6.0/go.mod h1:5N711Q9dKgbdkxHL+MEfF31hpT7l0S0s/t2kKREewys= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= @@ -235,9 +198,7 @@ github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykElWQ6/NYmHa3jpm/yHnI4xSofP+UP6SpjHcSeM= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= -github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/snikch/goodman v0.0.0-20171125024755-10e37e294daa/go.mod h1:oJyF+mSPHbB5mVY2iO9KV3pTt/QbIkGaO8gQ2WrDbP4= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= @@ -245,14 +206,9 @@ github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasO github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.2.1 h1:qgMbHoJbPbw579P+1zVY+6n4nIFuIchaIjzZ/I/Yq8M= github.com/spf13/afero v1.2.1/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= -github.com/spf13/afero v1.2.2 h1:5jhuqJyZCZf2JRofRvN/nIFgIWNzPa3/Vz8mYylgbWc= -github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/cast v1.3.0 h1:oget//CVOEoFewqQxwr0Ej5yjygnqGkvggSE/gB35Q8= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cast v1.3.1 h1:nFm6S0SMdyzrzcmThSipiEubIDy8WEXKNZ0UOgiRpng= -github.com/spf13/cast v1.3.1/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cobra v0.0.1/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/cobra v0.0.5 h1:f0B+LkLX6DtmRH1isoNA9VTtNUK9K8xYd28JNNfOv/s= github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= github.com/spf13/cobra v0.0.7 h1:FfTH+vuMXOas8jmfb5/M7dzEYx7LpcLb7a0LPe34uOU= github.com/spf13/cobra v0.0.7/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE= @@ -266,7 +222,6 @@ github.com/spf13/viper v1.0.0/go.mod h1:A8kyI5cUJhb8N+3pkfONlcEcZbueH6nhAm0Fq7Sr github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= github.com/spf13/viper v1.5.0/go.mod h1:AkYRkVJF8TkSG/xet6PzXX+l39KhhXa2pdqVSxnTcn4= -github.com/spf13/viper v1.6.1 h1:VPZzIkznI1YhVMRi6vNFLHSwhnhReBfgTxIPccpfdZk= github.com/spf13/viper v1.6.1/go.mod h1:t3iDnF5Jlj76alVNuyFBk5oUMCvsrkbvZK0WQdfDi5k= github.com/spf13/viper v1.6.2 h1:7aKfF+e8/k68gda3LOjo5RxiUqddoFxVq4BKBPrxk5E= github.com/spf13/viper v1.6.2/go.mod h1:t3iDnF5Jlj76alVNuyFBk5oUMCvsrkbvZK0WQdfDi5k= @@ -274,9 +229,7 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= -github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stumble/gorocksdb v0.0.3 h1:9UU+QA1pqFYJuf9+5p7z1IqdE5k0mma4UAeu2wmX8kA= github.com/stumble/gorocksdb v0.0.3/go.mod h1:v6IHdFBXk5DJ1K4FZ0xi+eY737quiiBxYtSWXadLybY= github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= @@ -287,10 +240,7 @@ github.com/tendermint/crypto v0.0.0-20180820045704-3764759f34a5/go.mod h1:z4YtwM github.com/tendermint/go-amino v0.14.1/go.mod h1:i/UKE5Uocn+argJJBb12qTZsCDBcAYMbR92AaJVmKso= github.com/tendermint/go-amino v0.15.0 h1:TC4e66P59W7ML9+bxio17CPKnxW3nKIRAYskntMAoRk= github.com/tendermint/go-amino v0.15.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= -github.com/tendermint/iavl v0.12.1/go.mod h1:EoKMMv++tDOL5qKKVnoIqtVPshRrEPeJ0WsgDOLAauM= -github.com/tendermint/iavl v0.12.4 h1:hd1woxUGISKkfUWBA4mmmTwOua6PQZTJM/F0FDrmMV8= github.com/tendermint/iavl v0.12.4/go.mod h1:8LHakzt8/0G3/I8FUU0ReNx98S/EP6eyPJkAUvEXT/o= -github.com/tendermint/tendermint v0.31.0/go.mod h1:ymcPyWblXCplCPQjbOYbrF1fWnpslATMVqiGgWbZrlc= github.com/tendermint/tendermint v0.32.1/go.mod h1:jmPDAKuNkev9793/ivn/fTBnfpA9mGBww8MPRNPNxnU= github.com/tendermint/tendermint v0.32.6/go.mod h1:D2+A3pNjY+Po72X0mTfaXorFhiVI8dh/Zg640FGyGtE= github.com/tendermint/tendermint v0.32.8/go.mod h1:5/B1XZjNYtVBso8o1l/Eg4A0Mhu42lDcmftoQl95j/E= @@ -299,7 +249,6 @@ github.com/tendermint/tendermint v0.32.9/go.mod h1:5/B1XZjNYtVBso8o1l/Eg4A0Mhu42 github.com/tendermint/tm-db v0.1.1/go.mod h1:0cPKWu2Mou3IlxecH+MEUSYc1Ch537alLe6CpFrKzgw= github.com/tendermint/tm-db v0.2.0 h1:rJxgdqn6fIiVJZy4zLpY1qVlyD0TU6vhkT4kEf71TQQ= github.com/tendermint/tm-db v0.2.0/go.mod h1:0cPKWu2Mou3IlxecH+MEUSYc1Ch537alLe6CpFrKzgw= -github.com/tendermint/tmlibs v0.9.0/go.mod h1:4L0tAKpLTioy14VnmbXYTLIJN0pCMiehxDMdN6zZfM8= github.com/terra-project/core v0.3.3 h1:UNOj087MfZEfgJ7Xz9FEiZZ0+O3xYhB4jZ4HHVaDphY= github.com/terra-project/core v0.3.3/go.mod h1:77b4dyp/4/CzHOnBVp489k7VQ8bmSO9glejY58iWplg= github.com/tidwall/gjson v1.3.2/go.mod h1:P256ACg0Mn+j1RXIDXoss50DeIABTYK1PULOJHhxOls= @@ -313,7 +262,6 @@ github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/zondax/hid v0.9.0/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.3 h1:MUGmc65QhB3pIlaQ5bB4LwqSj6GIonVJXpZiaKNyaKk= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.6.0 h1:Ezj3JGmsOnG1MoRWQkPBsKLe9DwWD9QeXzTRzzldNVk= @@ -321,7 +269,6 @@ go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.5.0 h1:KCa4XfM8CWFCpxXRGok+Q0SS/0XBhMDbHHGABQLvD2A= go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= -go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee h1:0mgffUl7nfd+FpvXMVz4IDEaUSmT1ysygQC7qYo7sG4= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.14.1 h1:nYDKopTbvAPq/NrUVZwT15y2lpROBiLLyoRTbXOYWOo= @@ -338,7 +285,6 @@ golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= -golang.org/x/lint v0.0.0-20190930215403-16217165b5de h1:5hukYrvBGR8/eNkX5mdUezrA6JiaEZDtJb9Ei+1LlBs= golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -373,18 +319,12 @@ golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82 h1:ywK/j/KkyTHcdyYSZNXGjMwgmDSfjglYZ3vStQ/gSCU= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200331124033-c3d80250170d h1:nc5K6ox/4lTFbMVSL9WRR81ixkcwXThoiF6yf+R9scA= -golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= -golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= @@ -394,10 +334,8 @@ golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5 h1:hKsoRgsbwY1NafxrwTs+k64bikrLBkAgPir1TNCj3Zs= golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -417,17 +355,12 @@ google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQ gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= -gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/ini.v1 v1.51.0 h1:AQvPpx3LzTDM0AjnIRlVFwFFGC+npRopjZxLJj6gdno= gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/ini.v1 v1.55.0 h1:E8yzL5unfpW3M6fz/eB7Cb5MQAYSZ7GKo4Qth+N2sgQ= -gopkg.in/ini.v1 v1.55.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -436,9 +369,6 @@ gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.7 h1:VUgggvou5XRW9mHwD/yXxIYSMtY0zoKQf/v226p2nyo= gopkg.in/yaml.v2 v2.2.7/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.2.8 h1:obN1ZagJSUGI0Ek/LBmuj4SNLPfIny3KsKFopxRdj10= -gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= -honnef.co/go/tools v0.0.1-2019.2.3 h1:3JgtbtFHMiCmsznwGVTUWbgGov+pVqnlf1dEJTNAXeM= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= diff --git a/utils/metric.go b/utils/metric.go new file mode 100644 index 0000000..bf16026 --- /dev/null +++ b/utils/metric.go @@ -0,0 +1,35 @@ +package utils + +import ( + + "github.com/prometheus/client_golang/prometheus" +) + +var ( + +) + +func NewGauge(nameSpace string, name string, help string) prometheus.Gauge { + result := prometheus.NewGauge( + prometheus.GaugeOpts{ + Namespace: "" + nameSpace, + Name: "" + name, + Help: "" + help, + }, + ) + + return result +} + +func NewCounterVec(nameSpace string, name string, help string, labels []string) prometheus.CounterVec { + result := prometheus.NewCounterVec( + prometheus.CounterOpts{ + Namespace: "" + nameSpace, + Name: "" + name, + Help: "" + help, + }, + labels, + ) + return *result +} +