Fix gomod (#379)

This commit is contained in:
Lunny Xiao 2020-04-24 14:10:03 +08:00 committed by GitHub
parent 1b73a3d5bb
commit 4c786878af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
66 changed files with 96 additions and 93 deletions

View File

@ -3,8 +3,8 @@ package main
import (
"flag"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/ledis"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/ledis"
)
var configPath = flag.String("config", "", "ledisdb config file")

View File

@ -3,8 +3,8 @@ package main
import (
"flag"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store"
)
var fileName = flag.String("config", "", "ledisdb config file")

View File

@ -12,8 +12,8 @@ import (
"strings"
"syscall"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/server"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/server"
)
var configFile = flag.String("config", "", "ledisdb config file")

2
go.mod
View File

@ -1,4 +1,4 @@
module github.com/siddontang/ledisdb
module github.com/ledisdb/ledisdb
go 1.12

View File

@ -3,9 +3,9 @@ package ledis
import (
"sync"
"github.com/ledisdb/ledisdb/rpl"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/log"
"github.com/siddontang/ledisdb/rpl"
"github.com/siddontang/ledisdb/store"
)
type batch struct {

View File

@ -7,8 +7,8 @@ import (
"io"
"os"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/snappy"
"github.com/siddontang/ledisdb/store"
)
// DumpHead is the head of a dump.

View File

@ -5,8 +5,8 @@ import (
"os"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store"
)
func TestDump(t *testing.T) {

View File

@ -8,11 +8,11 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/rpl"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/filelock"
"github.com/siddontang/go/log"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/rpl"
"github.com/siddontang/ledisdb/store"
)
// Ledis is the core structure to handle the database.

View File

@ -6,7 +6,7 @@ import (
"fmt"
"sync"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/store"
)
type ibucket interface {

View File

@ -5,7 +5,7 @@ import (
"sync"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
var testLedis *Ledis

View File

@ -4,7 +4,7 @@ import (
"os"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
func TestMigrate(t *testing.T) {

View File

@ -6,10 +6,10 @@ import (
"io"
"time"
"github.com/ledisdb/ledisdb/rpl"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/log"
"github.com/siddontang/go/snappy"
"github.com/siddontang/ledisdb/rpl"
"github.com/siddontang/ledisdb/store"
)
const (

View File

@ -6,8 +6,8 @@ import (
"os"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store"
)
func checkLedisEqual(master *Ledis, slave *Ledis) error {

View File

@ -4,7 +4,7 @@ import (
"errors"
"regexp"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/store"
)
var errDataType = errors.New("error data type")

View File

@ -6,7 +6,7 @@ import (
"sort"
"strconv"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/store"
)
// Limit is for sort.

View File

@ -5,8 +5,8 @@ import (
"errors"
"time"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/store"
)
// FVPair is the pair of field and value.

View File

@ -7,8 +7,8 @@ import (
"strings"
"time"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/store"
)
// KVPair is the pair of key-value.

View File

@ -7,10 +7,10 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/log"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/store"
"golang.org/x/net/context"
)

View File

@ -5,8 +5,8 @@ import (
"errors"
"time"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/hack"
"github.com/siddontang/ledisdb/store"
)
var errSetKey = errors.New("invalid set key")

View File

@ -6,7 +6,7 @@ import (
"sync"
"time"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/store"
)
var (

View File

@ -6,8 +6,8 @@ import (
"errors"
"time"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/hack"
"github.com/siddontang/ledisdb/store"
)
// For zset const.

View File

@ -5,7 +5,7 @@ import (
"reflect"
"testing"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/store"
)
const (

View File

@ -8,9 +8,9 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/go/log"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/config"
)
const (
@ -38,7 +38,7 @@ const (
meta: log1 offset | log2 offset
log offset: bigendian uint32 | bigendian uint32
//sha1 of github.com/siddontang/ledisdb 20 bytes
//sha1 of github.com/ledisdb/ledisdb 20 bytes
magic data = "\x1c\x1d\xb8\x88\xff\x9e\x45\x55\x40\xf0\x4c\xda\xe0\xce\x47\xde\x65\x48\x71\x17"
we must guarantee that the log id is monotonic increment strictly.

View File

@ -7,9 +7,9 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store"
)
type GoLevelDBStore struct {

View File

@ -7,9 +7,9 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/go/log"
"github.com/siddontang/go/snappy"
"github.com/siddontang/ledisdb/config"
)
type Stat struct {

View File

@ -5,7 +5,7 @@ import (
"os"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
func TestReplication(t *testing.T) {

View File

@ -5,7 +5,7 @@ import (
"os"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
func TestGoLevelDBStore(t *testing.T) {

View File

@ -11,9 +11,10 @@ import (
"sync"
"crypto/tls"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/ledis"
)
type App struct {

View File

@ -5,8 +5,8 @@ import (
"sync"
"testing"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/config"
)
var testAppOnce sync.Once

View File

@ -7,8 +7,8 @@ import (
"strings"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/sync2"
"github.com/siddontang/ledisdb/ledis"
)
type responseWriter interface {

View File

@ -8,10 +8,10 @@ import (
"strconv"
"strings"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/bson"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/log"
"github.com/siddontang/ledisdb/ledis"
"github.com/ugorji/go/codec"
)

View File

@ -12,11 +12,11 @@ import (
"syscall"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/log"
"github.com/siddontang/go/num"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/ledis"
)
var errReadRequest = errors.New("invalid request protocol")

View File

@ -1,7 +1,7 @@
package server
import (
"github.com/siddontang/ledisdb/ledis"
"github.com/ledisdb/ledisdb/ledis"
)
func hsetCommand(c *client) error {

View File

@ -3,7 +3,7 @@ package server
import (
"strconv"
"github.com/siddontang/ledisdb/ledis"
"github.com/ledisdb/ledisdb/ledis"
)
// func getCommand(c *client) error {

View File

@ -5,8 +5,9 @@ import (
"time"
"bytes"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/ledisdb/ledis"
)
func lpushCommand(c *client) error {

View File

@ -7,10 +7,10 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/log"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/ledis"
)
func dumpCommand(c *client) error {

View File

@ -6,8 +6,8 @@ import (
"testing"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/config"
)
func TestDumpRestore(t *testing.T) {

View File

@ -8,9 +8,9 @@ import (
"strings"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/ledis"
)
func slaveofCommand(c *client) error {

View File

@ -7,8 +7,8 @@ import (
"testing"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/config"
)
func checkDataEqual(master *App, slave *App) error {

View File

@ -6,9 +6,9 @@ import (
"strconv"
"strings"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/ledis"
)
func parseXScanArgs(args [][]byte) (cursor []byte, match string, count int, desc bool, err error) {

View File

@ -5,8 +5,8 @@ import (
"os"
"testing"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/config"
)
func TestScan(t *testing.T) {

View File

@ -4,10 +4,11 @@ import (
"github.com/siddontang/go/hack"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/config"
"strconv"
"strings"
"time"
"github.com/ledisdb/ledisdb/config"
)
func pingCommand(c *client) error {

View File

@ -1,7 +1,7 @@
package server
import (
"github.com/siddontang/ledisdb/ledis"
"github.com/ledisdb/ledisdb/ledis"
)
func saddCommand(c *client) error {

View File

@ -6,10 +6,10 @@ import (
"strconv"
"strings"
"github.com/ledisdb/ledisdb/ledis"
"github.com/ledisdb/ledisdb/store"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/ledis"
"github.com/siddontang/ledisdb/store"
)
//for simple implementation, we only support int64 score

View File

@ -3,7 +3,7 @@ package server
import (
"errors"
"github.com/siddontang/ledisdb/ledis"
"github.com/ledisdb/ledisdb/ledis"
)
var (

View File

@ -10,8 +10,8 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/sync2"
"github.com/siddontang/ledisdb/ledis"
)
type info struct {

View File

@ -11,12 +11,12 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/ledis"
"github.com/ledisdb/ledisdb/rpl"
"github.com/siddontang/go/log"
"github.com/siddontang/go/num"
"github.com/siddontang/go/sync2"
"github.com/siddontang/goredis"
"github.com/siddontang/ledisdb/ledis"
"github.com/siddontang/ledisdb/rpl"
)
var (

View File

@ -8,10 +8,10 @@ import (
"strings"
"sync"
"github.com/ledisdb/ledisdb/ledis"
"github.com/siddontang/go/hack"
"github.com/siddontang/go/num"
"github.com/siddontang/ledisdb/ledis"
"github.com/yuin/gopher-lua"
lua "github.com/yuin/gopher-lua"
luajson "github.com/glendc/gopher-json"
)

View File

@ -3,8 +3,8 @@ package server
import (
"fmt"
"github.com/siddontang/ledisdb/config"
"github.com/yuin/gopher-lua"
"github.com/ledisdb/ledisdb/config"
lua "github.com/yuin/gopher-lua"
"testing"
)

View File

@ -10,8 +10,8 @@ import (
"sync"
"time"
"github.com/ledisdb/ledisdb/config"
"github.com/siddontang/go/log"
"github.com/siddontang/ledisdb/config"
)
const (

View File

@ -7,7 +7,7 @@ import (
"path"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
type testSnapshotDumper struct {

View File

@ -4,8 +4,8 @@ import (
"sync"
"time"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
)
type DB struct {

View File

@ -3,7 +3,7 @@ package driver
import (
"fmt"
"github.com/siddontang/ledisdb/config"
"github.com/ledisdb/ledisdb/config"
)
type Store interface {

View File

@ -8,8 +8,8 @@ import (
"github.com/syndtr/goleveldb/leveldb/storage"
"github.com/syndtr/goleveldb/leveldb/util"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
"os"
)

View File

@ -1,7 +1,7 @@
package goleveldb
import (
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
"github.com/syndtr/goleveldb/leveldb"
)

View File

@ -3,7 +3,7 @@ package store
import (
"bytes"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
)
const (

View File

@ -15,8 +15,8 @@ import (
"runtime"
"unsafe"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
)
const defaultFilterBits int = 10

View File

@ -7,7 +7,7 @@ package leveldb
import "C"
import (
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
)
type Snapshot struct {

View File

@ -16,8 +16,8 @@ import (
"runtime"
"unsafe"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
)
const defaultFilterBits int = 10

View File

@ -7,7 +7,7 @@ package rocksdb
import "C"
import (
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
)
type Snapshot struct {

View File

@ -1,7 +1,7 @@
package store
import (
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
)
type Slice interface {

View File

@ -1,7 +1,7 @@
package store
import (
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
)
type Snapshot struct {

View File

@ -5,12 +5,12 @@ import (
"os"
"path"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
_ "github.com/siddontang/ledisdb/store/goleveldb"
_ "github.com/siddontang/ledisdb/store/leveldb"
_ "github.com/siddontang/ledisdb/store/rocksdb"
_ "github.com/ledisdb/ledisdb/store/goleveldb"
_ "github.com/ledisdb/ledisdb/store/leveldb"
_ "github.com/ledisdb/ledisdb/store/rocksdb"
)
func getStorePath(cfg *config.Config) string {

View File

@ -7,8 +7,8 @@ import (
"reflect"
"testing"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/store/driver"
)
func TestStore(t *testing.T) {

View File

@ -3,7 +3,7 @@ package store
import (
"time"
"github.com/siddontang/ledisdb/store/driver"
"github.com/ledisdb/ledisdb/store/driver"
"github.com/syndtr/goleveldb/leveldb"
)

View File

@ -5,9 +5,9 @@ import (
"flag"
"fmt"
"github.com/siddontang/ledisdb/config"
"github.com/siddontang/ledisdb/ledis"
"github.com/siddontang/ledisdb/store"
"github.com/ledisdb/ledisdb/config"
"github.com/ledisdb/ledisdb/ledis"
"github.com/ledisdb/ledisdb/store"
)
var configPath = flag.String("config", "", "ledisdb config file")