jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefan Egli (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (OAK-2479) FileStoreBackup throws SegmentNotFoundException
Date Tue, 10 Mar 2015 17:00:45 GMT

    [ https://issues.apache.org/jira/browse/OAK-2479?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14355205#comment-14355205
] 

Stefan Egli commented on OAK-2479:
----------------------------------

[~mduerig] what's your take on this one, 1.2 or 1.4 ? thx

> FileStoreBackup throws SegmentNotFoundException
> -----------------------------------------------
>
>                 Key: OAK-2479
>                 URL: https://issues.apache.org/jira/browse/OAK-2479
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: run
>    Affects Versions: 1.1.5, 1.0.11
>            Reporter: Stefan Egli
>         Attachments: BackupTest.java, oak-2479.cloneBinaries.partial.patch
>
>
> Running the FileStoreBackup (in oak-run) results in a SegmentNotFoundException to be
thrown.
> Narrowed this down to a regression introduced with https://github.com/apache/jackrabbit-oak/commit/6129da4251d36e3f2e1ac4b72ebf3602d0073d47
> The issue seems to be related to the fact that it creates a Compactor with the parameter
cloneBinaries set to false. This results in blobs not being copied by value but rather by
reference. Which results in segments not being found in the backup (since they only exist
in the origin-store).
> Creating the Compactor with cloneBinaries set to true fixes this (not saying that this
is the correct fix - as I understood at least in online-compaction case you want to have cloneBinaries
set to false for example).
> Attaching a test case later which reproduces the problem and currently results in the
following exception (in trunk):
> {code}
> org.apache.jackrabbit.oak.plugins.segment.SegmentNotFoundException: Segment 7433ef00-fac5-48d5-b91d-923c517c4a5b
not found
> 	at org.apache.jackrabbit.oak.plugins.segment.file.FileStore.readSegment(FileStore.java:711)
> 	at org.apache.jackrabbit.oak.plugins.segment.SegmentTracker.getSegment(SegmentTracker.java:122)
> 	at org.apache.jackrabbit.oak.plugins.segment.SegmentId.getSegment(SegmentId.java:108)
> 	at org.apache.jackrabbit.oak.plugins.segment.Record.getSegment(Record.java:82)
> 	at org.apache.jackrabbit.oak.plugins.segment.BlockRecord.read(BlockRecord.java:55)
> 	at org.apache.jackrabbit.oak.plugins.segment.SegmentStream.read(SegmentStream.java:171)
> 	at com.google.common.io.ByteStreams.read(ByteStreams.java:828)
> 	at com.google.common.io.ByteSource.contentEquals(ByteSource.java:303)
> 	at com.google.common.io.ByteStreams.equal(ByteStreams.java:661)
> 	at org.apache.jackrabbit.oak.plugins.memory.AbstractBlob.equal(AbstractBlob.java:58)
> 	at org.apache.jackrabbit.oak.plugins.segment.SegmentBlob.equals(SegmentBlob.java:211)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor.compact(Compactor.java:229)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor.compact(Compactor.java:185)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor.access$0(Compactor.java:181)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor$CompactDiff.propertyAdded(Compactor.java:115)
> 	at org.apache.jackrabbit.oak.plugins.memory.EmptyNodeState.compareAgainstEmptyState(EmptyNodeState.java:155)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor$CompactDiff.childNodeAdded(Compactor.java:137)
> 	at org.apache.jackrabbit.oak.plugins.segment.SegmentNodeState.compareAgainstBaseState(SegmentNodeState.java:488)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor.process(Compactor.java:92)
> 	at org.apache.jackrabbit.oak.plugins.segment.Compactor.compact(Compactor.java:97)
> 	at org.apache.jackrabbit.oak.plugins.backup.FileStoreBackup.backup(FileStoreBackup.java:81)
> 	at org.apache.jackrabbit.oak.run.BackupTest.testInMemoryBackup(BackupTest.java:55)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:597)
> 	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
> 	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
> 	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
> 	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
> 	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
> 	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
> 	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
> 	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
> 	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
> 	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
> 	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
> 	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
> 	at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
> 	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
> 	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message