commit | 8dc108b862db7aa11c557695ea4beffcf21cece4 | [log] [tgz] |
---|---|---|
author | Matteo Merli <mmerli@apache.org> | Sun May 09 14:01:13 2021 -0700 |
committer | GitHub <noreply@github.com> | Sun May 09 14:01:13 2021 -0700 |
tree | 79af67db015be41982e502e6a2637aa3d0688af0 | |
parent | 73e22cacf705e8462d80f477a0974db1d2bcf5b8 [diff] |
y ### Motivation In case of corrupted entry log, this exception can show up during the compaction phase: ``` 18:53:37.224 [GarbageCollectorThread-7-1] ERROR org.apache.bookkeeper.bookie.GarbageCollectorThread - Failed to compact entry log 16 due to unexpected error java.lang.IndexOutOfBoundsException: index: 8, length: 8 (expected: range(0, 0)) at io.netty.buffer.AbstractByteBuf.checkRangeBounds(AbstractByteBuf.java:1425) ~[netty-buffer-4.1.51.Final.jar:4.1.51.Final] at io.netty.buffer.AbstractByteBuf.checkIndex0(AbstractByteBuf.java:1432) ~[netty-buffer-4.1.51.Final.jar:4.1.51.Final] at io.netty.buffer.AbstractByteBuf.checkIndex(AbstractByteBuf.java:1419) ~[netty-buffer-4.1.51.Final.jar:4.1.51.Final] at io.netty.buffer.UnpooledUnsafeDirectByteBuf.getLong(UnpooledUnsafeDirectByteBuf.java:144) ~[netty-buffer-4.1.51.Final.jar:4.1.51.Final] at org.apache.bookkeeper.bookie.EntryLogCompactor$CompactionScannerFactory$1.process(EntryLogCompactor.java:103) ~[bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.EntryLogger.scanEntryLog(EntryLogger.java:1011) ~[bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.EntryLogCompactor.compact(EntryLogCompactor.java:64) ~[bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.GarbageCollectorThread.compactEntryLog(GarbageCollectorThread.java:528) [bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.GarbageCollectorThread.doCompactEntryLogs(GarbageCollectorThread.java:462) [bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.GarbageCollectorThread.runWithFlags(GarbageCollectorThread.java:367) [bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.bookie.GarbageCollectorThread.safeRun(GarbageCollectorThread.java:316) [bookkeeper-server-4.11.0.SPLK.8715995.jar:?] at org.apache.bookkeeper.common.util.SafeRunnable.run(SafeRunnable.java:36) [bookkeeper-common-4.11.0.SPLK.8715995.jar:?] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_232] at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_232] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_232] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_232] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_232] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_232] at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [netty-common-4.1.51.Final.jar:4.1.51.Final] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_232] ``` Reviewers: Andrey Yegorov <None>, Enrico Olivelli <eolivelli@gmail.com> This closes #2649 from merlimat/compaction-exception and squashes the following commits: 1360e2388 [Matteo Merli] Make sure to log warning when entrySize is 0 42e0790d8 [Matteo Merli] Exception in BK GC with corrupted data files
Apache BookKeeper is a scalable, fault tolerant and low latency storage service optimized for append-only workloads.
It is suitable for being used in following scenarios:
Please visit the Documentation from the project website for more information.
For filing bugs, suggesting improvements, or requesting new features, help us out by opening a Github issue or opening an Apache jira.
Subscribe or mail the user@bookkeeper.apache.org list - Ask questions, find answers, and also help other users.
Subscribe or mail the dev@bookkeeper.apache.org list - Join development discussions, propose new ideas and connect with contributors.
Join us on Slack - This is the most immediate way to connect with Apache BookKeeper committers and contributors.
We feel that a welcoming open community is important and welcome contributions.
See Developer Setup to get your local environment setup.
Take a look at our open issues: JIRA Issues Github Issues.
Review our coding style and follow our pull requests to learn about our conventions.
Make your changes according to our contribution guide.