Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 0 additions & 3 deletions .github/workflows/pull.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ jobs:
strategy:
matrix:
include:
- os: ubuntu-latest
go: "1.17"

- os: ubuntu-latest
go: "1.18"
testWithMinio: true
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/push-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: build-push-dev

env:
GO_VERSION: "1.18"
MIN_SUPPORTED_GO_VERSION: "1.17"
MIN_SUPPORTED_GO_VERSION: "1.18"

on:
push:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: pushCI

env:
GO_VERSION: "1.18"
MIN_SUPPORTED_GO_VERSION: "1.17"
MIN_SUPPORTED_GO_VERSION: "1.18"

on:
push:
Expand Down
21 changes: 21 additions & 0 deletions .github/workflows/stress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,29 @@ on:
- '**'
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

jobs:
stress-tests:
runs-on: ubuntu-latest
steps:
- name: Checkout source code
uses: actions/checkout@v4
- name: Setup runner for Go
uses: actions/setup-go@v5
with:
go-version: "1.18"
- name: Build and run immudb
run: make immudb && ./immudb -d
- uses: actions/checkout@v4
- name: Build stress tool
run: |
go run ./tools/testing/stress_tool_test_kv/ \
-mix-read-writes \
-randomize-key-length \
-total-entries-written 300000 \
-total-entries-read 10000

stress-build:
runs-on: ubuntu-latest
steps:
Expand Down
14 changes: 7 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,16 +38,16 @@ V_COMMIT := $(shell git rev-parse HEAD)
V_BUILT_BY := $(shell git config user.email)
V_BUILT_AT := $(shell date +%s)
V_LDFLAGS_SYMBOL := -s
V_LDFLAGS_BUILD := -X "github.com/codenotary/immudb/cmd/version.Version=${VERSION}" \
-X "github.com/codenotary/immudb/cmd/version.Commit=${V_COMMIT}" \
-X "github.com/codenotary/immudb/cmd/version.BuiltBy=${V_BUILT_BY}"\
-X "github.com/codenotary/immudb/cmd/version.BuiltAt=${V_BUILT_AT}"
V_LDFLAGS_BUILD := -X "github.com/codenotary/immudb/v2/cmd/version.Version=${VERSION}" \
-X "github.com/codenotary/immudb/v2/cmd/version.Commit=${V_COMMIT}" \
-X "github.com/codenotary/immudb/v2/cmd/version.BuiltBy=${V_BUILT_BY}"\
-X "github.com/codenotary/immudb/v2/cmd/version.BuiltAt=${V_BUILT_AT}"
V_LDFLAGS_COMMON := ${V_LDFLAGS_SYMBOL} ${V_LDFLAGS_BUILD}
V_LDFLAGS_STATIC := ${V_LDFLAGS_COMMON} \
-X github.com/codenotary/immudb/cmd/version.Static=static \
-X github.com/codenotary/immudb/v2/cmd/version.Static=static \
-extldflags "-static"
V_LDFLAGS_FIPS_BUILD = ${V_LDFLAGS_BUILD} \
-X github.com/codenotary/immudb/cmd/version.FIPSEnabled=true
-X github.com/codenotary/immudb/v2/cmd/version.FIPSEnabled=true
V_GO_ENV_FLAGS := GOOS=$(GOOS) GOARCH=$(GOARCH)
V_BUILD_NAME ?= ""
V_BUILD_FLAG = -o $(V_BUILD_NAME)
Expand Down Expand Up @@ -179,7 +179,7 @@ build/codegen:
build/codegenv2:
$(PWD)/ext-tools/buf format -w

$(PROTOC) -I pkg/api/proto/ pkg/api/proto/authorization.proto pkg/api/proto/documents.proto \
$(PROTOC) -I pkg/api/proto/ pkg/api/proto/authorization.proto \
-I pkg/api/schema/ \
-I$(GOPATH)/pkg/mod \
-I$(GOPATH)/pkg/mod/github.com/grpc-ecosystem/grpc-gateway@$(GRPC_GATEWAY_VERSION) \
Expand Down
2 changes: 1 addition & 1 deletion cmd/helper/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"os/user"
"strings"

service "github.com/codenotary/immudb/cmd/immuclient/service/constants"
service "github.com/codenotary/immudb/v2/cmd/immuclient/service/constants"
"github.com/spf13/cobra"
"github.com/spf13/viper"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/helper/size_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package helper_test
import (
"testing"

"github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/helper"
"github.com/stretchr/testify/require"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/helper/table_printer_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"os"
"testing"

"github.com/codenotary/immudb/cmd/cmdtest"
"github.com/codenotary/immudb/v2/cmd/cmdtest"
"github.com/stretchr/testify/assert"
)

Expand Down
14 changes: 7 additions & 7 deletions cmd/immuadmin/command/backup.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ import (
"github.com/spf13/cobra"
daem "github.com/takama/daemon"

c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/pkg/auth"
"github.com/codenotary/immudb/pkg/client/homedir"
"github.com/codenotary/immudb/pkg/client/tokenservice"
"github.com/codenotary/immudb/pkg/fs"
"github.com/codenotary/immudb/pkg/immuos"
"github.com/codenotary/immudb/pkg/server"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/codenotary/immudb/v2/pkg/client/homedir"
"github.com/codenotary/immudb/v2/pkg/client/tokenservice"
"github.com/codenotary/immudb/v2/pkg/fs"
"github.com/codenotary/immudb/v2/pkg/immuos"
"github.com/codenotary/immudb/v2/pkg/server"
)

type backupper struct {
Expand Down
16 changes: 8 additions & 8 deletions cmd/immuadmin/command/backup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,16 @@ import (
"path/filepath"
"testing"

"github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/helper"
"github.com/stretchr/testify/assert"

"github.com/codenotary/immudb/cmd/cmdtest"
"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/client/clienttest"
"github.com/codenotary/immudb/pkg/fs"
"github.com/codenotary/immudb/pkg/immuos"
"github.com/codenotary/immudb/pkg/server"
"github.com/codenotary/immudb/v2/cmd/cmdtest"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/client/clienttest"
"github.com/codenotary/immudb/v2/pkg/fs"
"github.com/codenotary/immudb/v2/pkg/immuos"
"github.com/codenotary/immudb/v2/pkg/server"
"github.com/spf13/cobra"
"github.com/takama/daemon"

Expand Down
8 changes: 4 additions & 4 deletions cmd/immuadmin/command/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ limitations under the License.
package immuadmin

import (
"github.com/codenotary/immudb/cmd/docs/man"
c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/cmd/version"
"github.com/codenotary/immudb/pkg/immuos"
"github.com/codenotary/immudb/v2/cmd/docs/man"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/version"
"github.com/codenotary/immudb/v2/pkg/immuos"
"github.com/spf13/cobra"
)

Expand Down
12 changes: 6 additions & 6 deletions cmd/immuadmin/command/commandline.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ import (
"fmt"
"os"

"github.com/codenotary/immudb/pkg/client/homedir"
"github.com/codenotary/immudb/pkg/client/tokenservice"
"github.com/codenotary/immudb/v2/pkg/client/homedir"
"github.com/codenotary/immudb/v2/pkg/client/tokenservice"

"github.com/codenotary/immudb/cmd/helper"
c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/immuos"
"github.com/codenotary/immudb/v2/cmd/helper"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/immuos"
"github.com/spf13/cobra"
)

Expand Down
6 changes: 3 additions & 3 deletions cmd/immuadmin/command/commandline_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ import (
"errors"
"testing"

"github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/helper"
"github.com/stretchr/testify/assert"

"github.com/codenotary/immudb/pkg/client/clienttest"
"github.com/codenotary/immudb/v2/pkg/client/clienttest"
"github.com/stretchr/testify/require"

"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/spf13/cobra"
)

Expand Down
20 changes: 9 additions & 11 deletions cmd/immuadmin/command/database.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ import (
"strings"
"time"

"github.com/codenotary/immudb/cmd/helper"
c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/embedded/sql"
"github.com/codenotary/immudb/embedded/store"
"github.com/codenotary/immudb/embedded/tbtree"
"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/database"
"github.com/codenotary/immudb/pkg/replication"
"github.com/codenotary/immudb/v2/cmd/helper"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/embedded/sql"
"github.com/codenotary/immudb/v2/embedded/store"
"github.com/codenotary/immudb/v2/embedded/tbtree"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/database"
"github.com/codenotary/immudb/v2/pkg/replication"
"github.com/spf13/cobra"
"github.com/spf13/pflag"
"google.golang.org/protobuf/types/known/emptypb"
Expand All @@ -60,10 +60,8 @@ func addDbUpdateFlags(c *cobra.Command) {
c.Flags().Bool("replication-skip-integrity-check", replication.DefaultSkipIntegrityCheck, "disable integrity check when reading data during replication")
c.Flags().Bool("replication-wait-for-indexing", replication.DefaultWaitForIndexing, "wait for indexing to be up to date during replication")

c.Flags().Uint32("indexing-flush-threshold", tbtree.DefaultFlushThld, "number of new index entries between disk flushes")
c.Flags().Float32("indexing-cleanup-percentage", tbtree.DefaultCleanUpPercentage, "percentage of node files cleaned up during each flush")
c.Flags().Uint32("indexing-sync-threshold", tbtree.DefaultSyncThld, "number of new index entries between disk flushes with file sync")
c.Flags().Uint32("indexing-cache-size", tbtree.DefaultCacheSize, "size of the Btree node cache (number of nodes)")
c.Flags().Uint32("indexing-max-active-snapshots", tbtree.DefaultMaxActiveSnapshots, "maximum number of active btree snapshots")

c.Flags().Uint32("write-tx-header-version", 1, "set write tx header version (use 0 for compatibility with immudb 1.1, 1 for immudb 1.2+)")
Expand Down
4 changes: 2 additions & 2 deletions cmd/immuadmin/command/hot_backup.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ import (
"github.com/spf13/cobra"
"github.com/spf13/pflag"

"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/immuos"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/immuos"
)

const (
Expand Down
8 changes: 4 additions & 4 deletions cmd/immuadmin/command/hot_backup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ import (
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"

"github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/server"
"github.com/codenotary/immudb/pkg/server/servertest"
"github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/server"
"github.com/codenotary/immudb/v2/pkg/server/servertest"
)

func getCmdline(t *testing.T) *commandline {
Expand Down
2 changes: 1 addition & 1 deletion cmd/immuadmin/command/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"fmt"
"strings"

"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/spf13/cobra"
"github.com/spf13/viper"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/immuadmin/command/init_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ package immuadmin
import (
"testing"

"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/spf13/viper"
"github.com/stretchr/testify/assert"
)
Expand Down
4 changes: 2 additions & 2 deletions cmd/immuadmin/command/login.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ import (
"context"
"fmt"

c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/pkg/auth"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/spf13/cobra"
)

Expand Down
12 changes: 6 additions & 6 deletions cmd/immuadmin/command/login_errors_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ import (
"strings"
"testing"

"github.com/codenotary/immudb/cmd/helper"
c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/auth"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/client/clienttest"
"github.com/codenotary/immudb/v2/cmd/helper"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/client/clienttest"
"github.com/spf13/cobra"
"github.com/stretchr/testify/require"
"google.golang.org/grpc"
Expand Down
20 changes: 10 additions & 10 deletions cmd/immuadmin/command/login_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,20 @@ import (
"log"
"testing"

"github.com/codenotary/immudb/cmd/cmdtest"
"github.com/codenotary/immudb/pkg/client/homedir"
"github.com/codenotary/immudb/pkg/client/tokenservice"
"github.com/codenotary/immudb/v2/cmd/cmdtest"
"github.com/codenotary/immudb/v2/pkg/client/homedir"
"github.com/codenotary/immudb/v2/pkg/client/tokenservice"
"github.com/stretchr/testify/require"

"github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/helper"

"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/auth"
"github.com/codenotary/immudb/pkg/client/clienttest"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/codenotary/immudb/v2/pkg/client/clienttest"

"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/pkg/server"
"github.com/codenotary/immudb/pkg/server/servertest"
"github.com/codenotary/immudb/v2/pkg/client"
"github.com/codenotary/immudb/v2/pkg/server"
"github.com/codenotary/immudb/v2/pkg/server/servertest"
"github.com/spf13/cobra"
"github.com/stretchr/testify/assert"
"google.golang.org/grpc"
Expand Down
2 changes: 1 addition & 1 deletion cmd/immuadmin/command/serverconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"fmt"
"strconv"

"github.com/codenotary/immudb/pkg/auth"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/spf13/cobra"
)

Expand Down
6 changes: 3 additions & 3 deletions cmd/immuadmin/command/serverconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ package immuadmin
import (
"context"

"github.com/codenotary/immudb/pkg/api/schema"
"github.com/codenotary/immudb/pkg/auth"
"github.com/codenotary/immudb/pkg/client"
"github.com/codenotary/immudb/v2/pkg/api/schema"
"github.com/codenotary/immudb/v2/pkg/auth"
"github.com/codenotary/immudb/v2/pkg/client"
"google.golang.org/grpc"
)

Expand Down
6 changes: 3 additions & 3 deletions cmd/immuadmin/command/stats.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ import (

"github.com/spf13/cobra"

c "github.com/codenotary/immudb/cmd/helper"
"github.com/codenotary/immudb/cmd/immuadmin/command/stats"
"github.com/codenotary/immudb/pkg/api/schema"
c "github.com/codenotary/immudb/v2/cmd/helper"
"github.com/codenotary/immudb/v2/cmd/immuadmin/command/stats"
"github.com/codenotary/immudb/v2/pkg/api/schema"
)

func (cl *commandline) status(cmd *cobra.Command) {
Expand Down
2 changes: 1 addition & 1 deletion cmd/immuadmin/command/stats/controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (
"bytes"
"testing"

"github.com/codenotary/immudb/cmd/immuadmin/command/stats/statstest"
"github.com/codenotary/immudb/v2/cmd/immuadmin/command/stats/statstest"
ui "github.com/gizak/termui/v3"
"github.com/prometheus/common/expfmt"
"github.com/stretchr/testify/assert"
Expand Down
Loading
Loading