Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AOFSHRINK causes panic on server #624

Closed
saques opened this issue Sep 29, 2021 · 1 comment
Closed

AOFSHRINK causes panic on server #624

saques opened this issue Sep 29, 2021 · 1 comment

Comments

@saques
Copy link

saques commented Sep 29, 2021

Describe the bug
Whenever we run an AOFSHRINK operation, the Tile38 server panics and crashes, causing our daemon to restart the process.

Expected behavior
AOFSHRINK ends and the server proceeds as normal.

Logs
We noted this log when using the -vv option:

2021/09/29 15:26:08 [INFO] aof shrink ended 742.016591ms
panic: interface conversion: interface {} is string, not *server.Hook

goroutine 3058 [running]:
github.com/tidwall/tile38/internal/server.byHookName({0xe77b80, 0xc043131f40}, {0xf6d080, 0xc050ee4000})
        /Users/josh/go/src/github.com/tidwall/tile38/internal/server/hooks.go:26 +0x85
github.com/tidwall/btree.(*node).find(0xc04fb24600, {0xe77b80, 0xc043131f40}, 0x10667f0, 0xc050305df8, 0x0)
        /Users/josh/go/src/github.com/tidwall/tile38/vendor/github.com/tidwall/btree/btree.go:119 +0x34a
github.com/tidwall/btree.(*BTree).GetHint(0xc000096540, {0xe77b80, 0xc043131f40}, 0x0)
        /Users/josh/go/src/github.com/tidwall/tile38/vendor/github.com/tidwall/btree/btree.go:344 +0x11f
github.com/tidwall/tile38/internal/server.(*Server).aofshrink.func2.4(0xc000226900, 0xc050305e50, 0xc050305e98, 0xc050305ec8)
        /Users/josh/go/src/github.com/tidwall/tile38/internal/server/aofshrink.go:184 +0xf1
github.com/tidwall/tile38/internal/server.(*Server).aofshrink.func2(0xc0002269f0)
        /Users/josh/go/src/github.com/tidwall/tile38/internal/server/aofshrink.go:218 +0x345
github.com/tidwall/tile38/internal/server.(*Server).aofshrink(0xc000226900)
        /Users/josh/go/src/github.com/tidwall/tile38/internal/server/aofshrink.go:304 +0x15b
created by github.com/tidwall/tile38/internal/server.(*Server).command
        /Users/josh/go/src/github.com/tidwall/tile38/internal/server/server.go:1131 +0x4f7d

Operating System (please complete the following information):

  • OS: Linux (Ubuntu)
  • Version: 18.04
@tidwall
Copy link
Owner

tidwall commented Sep 29, 2021

I just pushed a fix and a new release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants