forked from p53841790/wheat-cache
refactor(mod): gitee.com/wheat-os
This commit is contained in:
parent
99133bf7ea
commit
70b23849bc
|
@ -1,8 +1,8 @@
|
||||||
package client
|
package client
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/client/middle"
|
"gitee.com/wheat-os/wheatCache/client/middle"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/client/middle"
|
"gitee.com/wheat-os/wheatCache/client/middle"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ package middle
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
"google.golang.org/grpc/codes"
|
"google.golang.org/grpc/codes"
|
||||||
"google.golang.org/grpc/metadata"
|
"google.golang.org/grpc/metadata"
|
||||||
|
|
|
@ -7,9 +7,9 @@ package dao
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
"gitee.com/timedb/wheatCache/pkg/lru"
|
"gitee.com/wheat-os/wheatCache/pkg/lru"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,12 +4,12 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"net"
|
"net"
|
||||||
|
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
wheatCodec "gitee.com/timedb/wheatCache/gateway/codec"
|
wheatCodec "gitee.com/wheat-os/wheatCache/gateway/codec"
|
||||||
"gitee.com/timedb/wheatCache/gateway/proxy"
|
"gitee.com/wheat-os/wheatCache/gateway/proxy"
|
||||||
"gitee.com/timedb/wheatCache/gateway/transport"
|
"gitee.com/wheat-os/wheatCache/gateway/transport"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/util/server"
|
"gitee.com/wheat-os/wheatCache/pkg/util/server"
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
|
|
|
@ -15,7 +15,7 @@ limitations under the License.
|
||||||
*/
|
*/
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "gitee.com/timedb/wheatCache/gateway/cmd"
|
import "gitee.com/wheat-os/wheatCache/gateway/cmd"
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
cmd.Execute()
|
cmd.Execute()
|
||||||
|
|
|
@ -3,7 +3,7 @@ package proxy
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/gateway/transport"
|
"gitee.com/wheat-os/wheatCache/gateway/transport"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,9 +3,9 @@ package proxy
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/gateway/codec"
|
"gitee.com/wheat-os/wheatCache/gateway/codec"
|
||||||
"gitee.com/timedb/wheatCache/gateway/transport"
|
"gitee.com/wheat-os/wheatCache/gateway/transport"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
"google.golang.org/grpc/codes"
|
"google.golang.org/grpc/codes"
|
||||||
"google.golang.org/grpc/metadata"
|
"google.golang.org/grpc/metadata"
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"io"
|
"io"
|
||||||
|
|
||||||
wheatCodec "gitee.com/timedb/wheatCache/gateway/codec"
|
wheatCodec "gitee.com/wheat-os/wheatCache/gateway/codec"
|
||||||
"gitee.com/timedb/wheatCache/gateway/transport"
|
"gitee.com/wheat-os/wheatCache/gateway/transport"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
"google.golang.org/grpc/codes"
|
"google.golang.org/grpc/codes"
|
||||||
"google.golang.org/grpc/status"
|
"google.golang.org/grpc/status"
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"sort"
|
"sort"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
)
|
)
|
||||||
|
|
||||||
type HashFunc func(data []byte) uint32
|
type HashFunc func(data []byte) uint32
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,4 +1,4 @@
|
||||||
module gitee.com/timedb/wheatCache
|
module gitee.com/wheat-os/wheatCache
|
||||||
|
|
||||||
go 1.16
|
go 1.16
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// 事件 poll 降低 new 对象的频率
|
// 事件 poll 降低 new 对象的频率
|
||||||
|
|
|
@ -2,9 +2,10 @@ package logx
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
|
||||||
"github.com/spf13/viper"
|
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
type LogLevelState int8
|
type LogLevelState int8
|
||||||
|
|
|
@ -8,8 +8,8 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
middleMsg "gitee.com/timedb/wheatCache/pkg/middle-msg"
|
middleMsg "gitee.com/wheat-os/wheatCache/pkg/middle-msg"
|
||||||
)
|
)
|
||||||
|
|
||||||
func With(ctx context.Context, p event.ProduceInterface) *upLogger {
|
func With(ctx context.Context, p event.ProduceInterface) *upLogger {
|
||||||
|
|
|
@ -2,9 +2,10 @@ package logx
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStd(t *testing.T) {
|
func TestStd(t *testing.T) {
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
)
|
)
|
||||||
|
|
||||||
type SingleWorkFunc func() interface{}
|
type SingleWorkFunc func() interface{}
|
||||||
|
|
|
@ -4,13 +4,13 @@ import (
|
||||||
"container/list"
|
"container/list"
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
|
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/middle"
|
"gitee.com/wheat-os/wheatCache/pkg/middle"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
"gitee.com/timedb/wheatCache/pkg/util"
|
"gitee.com/wheat-os/wheatCache/pkg/util"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
"gitee.com/wheat-os/wheatCache/pkg/structure/stringx"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/util/skiplist"
|
"gitee.com/wheat-os/wheatCache/pkg/util/skiplist"
|
||||||
)
|
)
|
||||||
|
|
||||||
// lru 的 ttl 管理器
|
// lru 的 ttl 管理器
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
"gitee.com/wheat-os/wheatCache/pkg/structure/stringx"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,10 +5,10 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
"gitee.com/wheat-os/wheatCache/pkg/structure/stringx"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,10 +4,10 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
mMsg "gitee.com/timedb/wheatCache/pkg/middle-msg"
|
mMsg "gitee.com/wheat-os/wheatCache/pkg/middle-msg"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (lru *SingleCache) lruSingleWork() {
|
func (lru *SingleCache) lruSingleWork() {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package middlemsg
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
package middle
|
package middle
|
||||||
|
|
||||||
import (
|
import (
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/plugins"
|
"gitee.com/wheat-os/wheatCache/plugins"
|
||||||
"gitee.com/timedb/wheatCache/plugins/config"
|
"gitee.com/wheat-os/wheatCache/plugins/config"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,8 +3,8 @@ package middle
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
middleMsg "gitee.com/timedb/wheatCache/pkg/middle-msg"
|
middleMsg "gitee.com/wheat-os/wheatCache/pkg/middle-msg"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (m *MiddleWare) startWork() {
|
func (m *MiddleWare) startWork() {
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
middleMsg "gitee.com/timedb/wheatCache/pkg/middle-msg"
|
middleMsg "gitee.com/wheat-os/wheatCache/pkg/middle-msg"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Test_middleware_loadPlugins(t *testing.T) {
|
func Test_middleware_loadPlugins(t *testing.T) {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package listx
|
package listx
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
)
|
)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -3,8 +3,8 @@ package stringx
|
||||||
import (
|
import (
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
)
|
)
|
||||||
|
|
||||||
type StringSingle struct {
|
type StringSingle struct {
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"unsafe"
|
"unsafe"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"math"
|
"math"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Value 提供一个基础的 动态类型
|
// Value 提供一个基础的 动态类型
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// ParseSizeToBit
|
// ParseSizeToBit
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
"os/signal"
|
"os/signal"
|
||||||
"syscall"
|
"syscall"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,9 +4,9 @@
|
||||||
package config
|
package config
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/plugins"
|
"gitee.com/wheat-os/wheatCache/plugins"
|
||||||
|
|
||||||
mockPlugin "gitee.com/timedb/wheatCache/plugins/mock-plugin"
|
mockPlugin "gitee.com/wheat-os/wheatCache/plugins/mock-plugin"
|
||||||
)
|
)
|
||||||
|
|
||||||
func GetMiddlewareMap() map[string]plugins.PluginInterface {
|
func GetMiddlewareMap() map[string]plugins.PluginInterface {
|
||||||
|
|
|
@ -4,9 +4,9 @@
|
||||||
package config
|
package config
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/plugins"
|
"gitee.com/wheat-os/wheatCache/plugins"
|
||||||
{%for dir in dirs %}
|
{%for dir in dirs %}
|
||||||
{{dir[0]}} "gitee.com/timedb/wheatCache/plugins/{{dir[1]}}"
|
{{dir[0]}} "gitee.com/wheat-os/wheatCache/plugins/{{dir[1]}}"
|
||||||
{%- endfor%}
|
{%- endfor%}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"net/http"
|
"net/http"
|
||||||
_ "net/http/pprof"
|
_ "net/http/pprof"
|
||||||
|
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -6,12 +6,12 @@ import (
|
||||||
"log"
|
"log"
|
||||||
"net"
|
"net"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/storage/service"
|
"gitee.com/wheat-os/wheatCache/storage/service"
|
||||||
|
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/util/server"
|
"gitee.com/wheat-os/wheatCache/pkg/util/server"
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/pkg/lru"
|
"gitee.com/wheat-os/wheatCache/pkg/lru"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Dao struct {
|
type Dao struct {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import (
|
import (
|
||||||
_ "gitee.com/timedb/wheatCache/conf"
|
_ "gitee.com/wheat-os/wheatCache/conf"
|
||||||
)
|
)
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import "gitee.com/timedb/wheatCache/pkg/proto"
|
import "gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
|
|
||||||
type Interface interface {
|
type Interface interface {
|
||||||
LIndex(*proto.BaseKey, int32) (*proto.LIndexResponse, error)
|
LIndex(*proto.BaseKey, int32) (*proto.LIndexResponse, error)
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/listx"
|
"gitee.com/wheat-os/wheatCache/pkg/structure/listx"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (d *Dao) LIndex(key *proto.BaseKey, index int32) (*proto.LIndexResponse, error) {
|
func (d *Dao) LIndex(key *proto.BaseKey, index int32) (*proto.LIndexResponse, error) {
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure"
|
"gitee.com/wheat-os/wheatCache/pkg/structure"
|
||||||
"gitee.com/timedb/wheatCache/pkg/structure/stringx"
|
"gitee.com/wheat-os/wheatCache/pkg/structure/stringx"
|
||||||
)
|
)
|
||||||
|
|
||||||
// stringx 相关的方法
|
// stringx 相关的方法
|
||||||
|
|
|
@ -16,7 +16,7 @@ limitations under the License.
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"gitee.com/timedb/wheatCache/storage/cmd"
|
"gitee.com/wheat-os/wheatCache/storage/cmd"
|
||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/logx"
|
"gitee.com/wheat-os/wheatCache/pkg/logx"
|
||||||
protobuf "google.golang.org/protobuf/proto"
|
protobuf "google.golang.org/protobuf/proto"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
protobuf "google.golang.org/protobuf/proto"
|
protobuf "google.golang.org/protobuf/proto"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,12 +3,12 @@ package service
|
||||||
import (
|
import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/lru"
|
"gitee.com/wheat-os/wheatCache/pkg/lru"
|
||||||
"gitee.com/timedb/wheatCache/pkg/middle"
|
"gitee.com/wheat-os/wheatCache/pkg/middle"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
"gitee.com/timedb/wheatCache/storage/dao"
|
"gitee.com/wheat-os/wheatCache/storage/dao"
|
||||||
"gitee.com/timedb/wheatCache/storage/persisted"
|
"gitee.com/wheat-os/wheatCache/storage/persisted"
|
||||||
"github.com/spf13/viper"
|
"github.com/spf13/viper"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -5,9 +5,9 @@ package service
|
||||||
import (
|
import (
|
||||||
context "context"
|
context "context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/lru"
|
"gitee.com/wheat-os/wheatCache/pkg/lru"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
)
|
)
|
||||||
|
|
||||||
func (s *singleService) LIndex(
|
func (s *singleService) LIndex(
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/errorx"
|
"gitee.com/wheat-os/wheatCache/pkg/errorx"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
protobuf "google.golang.org/protobuf/proto"
|
protobuf "google.golang.org/protobuf/proto"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
package dao
|
package dao
|
||||||
|
|
||||||
import "gitee.com/timedb/wheatCache/pkg/proto"
|
import "gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
|
|
||||||
type Interface interface {
|
type Interface interface {
|
||||||
{%for key in keys %}
|
{%for key in keys %}
|
||||||
|
|
|
@ -5,9 +5,9 @@ package service
|
||||||
import (
|
import (
|
||||||
context "context"
|
context "context"
|
||||||
|
|
||||||
"gitee.com/timedb/wheatCache/pkg/event"
|
"gitee.com/wheat-os/wheatCache/pkg/event"
|
||||||
"gitee.com/timedb/wheatCache/pkg/lru"
|
"gitee.com/wheat-os/wheatCache/pkg/lru"
|
||||||
"gitee.com/timedb/wheatCache/pkg/proto"
|
"gitee.com/wheat-os/wheatCache/pkg/proto"
|
||||||
)
|
)
|
||||||
|
|
||||||
{% for key in keys %}
|
{% for key in keys %}
|
||||||
|
|
Loading…
Reference in New Issue