From d3f2ae092966f33584702a1dbb0c6f00335a156e Mon Sep 17 00:00:00 2001 From: "Brian S. O'Neill" Date: Wed, 18 May 2011 19:29:18 +0000 Subject: Add FIXME comment. --- src/main/java/com/amazon/carbonado/repo/indexed/ManagedIndex.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/main/java/com/amazon') diff --git a/src/main/java/com/amazon/carbonado/repo/indexed/ManagedIndex.java b/src/main/java/com/amazon/carbonado/repo/indexed/ManagedIndex.java index 1da57aa..4e99a06 100644 --- a/src/main/java/com/amazon/carbonado/repo/indexed/ManagedIndex.java +++ b/src/main/java/com/amazon/carbonado/repo/indexed/ManagedIndex.java @@ -660,15 +660,16 @@ class ManagedIndex implements IndexEntryAccessor { return true; } + // FIXME: This code effectively does nothing and always returns false. + // If index entry already exists, then index might be corrupt. try { Storable freshEntry = mIndexEntryStorage.prepare(); mAccessor.copyFromMaster(freshEntry, userStorable); indexEntry.copyVersionProperty(freshEntry); if (freshEntry.equals(indexEntry)) { - // Existing entry is exactly what we expect. Return false - // exception if alternate key constraint, since this is - // user error. + // Existing entry is exactly what we expect. Return false if + // alternate key constraint, since this is user error. return !isUnique(); } } catch (FetchException e) { -- cgit v1.2.3