Skip to content

Commit

Permalink
Merge pull request #49 from xephonhq/go/dep-to-mod
Browse files Browse the repository at this point in the history
[dep] Switch to go mod and update dependencies
  • Loading branch information
at15 authored Jan 20, 2020
2 parents 41d4da3 + 4191135 commit aba2a30
Show file tree
Hide file tree
Showing 29 changed files with 153 additions and 383 deletions.
13 changes: 5 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,13 @@ git:
# TODO: use docker service to start influxdb etc. and create database like oltpbench
# https://github.com/benchhub/oltpbench/blob/config/cleanup-v2/.travis.yml
go:
- 1.9.x
- "1.10"
- "1.13"
- tip

# FIXME: enable test when we no longer rely on local go modules

install:
- go get -u github.com/golang/dep/cmd/dep
- dep version
- dep ensure
- pwd
- go version

script:
- make install
- make test
- go version
99 changes: 0 additions & 99 deletions Gopkg.lock

This file was deleted.

41 changes: 0 additions & 41 deletions Gopkg.toml

This file was deleted.

3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ FLAGS = -X main.version=$(VERSION) -X main.commit=$(BUILD_COMMIT) -X main.buildT

.PHONY: install
install:
go install -ldflags "$(FLAGS)" ./cmd/xab
go install -ldflags "$(FLAGS)" ./cmd/xb

.PHONY: test
Expand All @@ -16,7 +15,7 @@ test:

.PHONY: fmt
fmt:
gofmt -d -l -w ./pkg ./cmd
goimports -d -l -w ./pkg ./cmd

.PHONY: generate
generate:
Expand Down
9 changes: 3 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

A time series database benchmark tool. NOTE: it is under major rewrite

- status: Under major rewrite, after libtsdb-go
- status: Under major rewrite, along with [libtsdb-go](https://github.com/libtsdb/libtsdb-go)
- [Documentation](doc)
- [Slide: Introduce Xephon-B](http://www.slideshare.net/ssuser7e134a/intoduce-xephonb)

Expand All @@ -32,16 +32,13 @@ A time series database benchmark tool. NOTE: it is under major rewrite

MIT


[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fxephonhq%2Fxephon-b.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2Fxephonhq%2Fxephon-b?ref=badge_large)

## Authors

- [Pinglei Guo](https://at15.github.io) [@at15](https://github.com/at15), [linkedin](https://www.linkedin.com/in/at1510086), [twitter](https://twitter.com/at1510086)
- [Zheyuan Chen](http://czheo.github.io/) [@czheo](https://github.com/czheo), [linkedin](https://www.linkedin.com/in/zheyuan-chen), [twitter](https://twitter.com/czheo)
- [Pinglei Guo](https://at15.github.io) [@at15](https://github.com/at15), [twitter](https://twitter.com/at1510086)
- [Zheyuan Chen](http://czheo.github.io/) [@czheo](https://github.com/czheo), [twitter](https://twitter.com/czheo)

## About

B is for benchmark and Xephon comes from the animation [RahXephon](https://en.wikipedia.org/wiki/RahXephon)

It was merged into Xephon-K and now split out from it as a standalone project again
7 changes: 1 addition & 6 deletions cmd/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,2 @@
# Cli
# Xephon-B binaries

## Legacy

- tsdb-proxy
- xb is alias of xephon-b
- xephon-b
65 changes: 0 additions & 65 deletions cmd/xab/main.go

This file was deleted.

16 changes: 4 additions & 12 deletions cmd/xb/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,17 @@ import (
"os"
"runtime"

icli "github.com/at15/go.ice/ice/cli"
goicelog "github.com/at15/go.ice/ice/util/logutil"

icli "github.com/dyweb/go.ice/cli"
dlog "github.com/dyweb/gommon/log"
"github.com/xephonhq/xephon-b/pkg/config"
"github.com/xephonhq/xephon-b/pkg/util/logutil"
)

const (
myname = "xb"
)

// FIXME: debug logging is not working ....
var log = logutil.Registry
var logReg = dlog.NewRegistry()
var log = logReg.Logger()

var (
version string
Expand All @@ -37,7 +35,6 @@ func main() {
icli.Name(myname),
icli.Description("Xephon-B Time Series Benchmark cli"),
icli.Version(buildInfo),
icli.LogRegistry(log),
)
root := cli.Command()
root.AddCommand(runCmd)
Expand All @@ -48,12 +45,7 @@ func main() {
}

func mustLoadConfig() {
// TODO: go.ice should use UnmarshalStrict, and might just use direct load ...
if err := cli.LoadConfigTo(&cfg); err != nil {
log.Fatal(err)
}
}

func init() {
log.AddChild(goicelog.Registry)
}
1 change: 1 addition & 0 deletions cmd/xb/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package main

import (
"context"

"github.com/spf13/cobra"
"github.com/xephonhq/xephon-b/pkg/runner"
)
Expand Down
14 changes: 14 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
module github.com/xephonhq/xephon-b

go 1.13

require (
github.com/dyweb/go.ice v0.0.3
github.com/dyweb/gommon v0.0.13
github.com/libtsdb/libtsdb-go v0.0.0-20180319021657-419c24436f34
github.com/spf13/cobra v0.0.5
)

replace github.com/dyweb/go.ice => ../../dyweb/go.ice

replace github.com/libtsdb/libtsdb-go => ../../libtsdb/libtsdb-go
Loading

0 comments on commit aba2a30

Please sign in to comment.