Github user elilevine commented on a diff in the pull request:
https://github.com/apache/phoenix/pull/37#discussion_r25212266
--- Diff:
phoenix-core/src/main/java/org/apache/phoenix/execute/MutationState.java ---
@@ -78,7 +87,11 @@
private PhoenixConnection connection;
private final long maxSize;
private final ImmutableBytesPtr tempPtr = new ImmutableBytesPtr();
- private final Map<TableRef,
Map<ImmutableBytesPtr,Map<PColumn,byte[]>>> mutations =
Maps.newHashMapWithExpectedSize(3); // TODO: Sizing?
+ /**
+ * Use {@link TreeMap} for {@link #mutations} below to enforce a
deterministic ordering for easier testing of partial failures.
+ * @see PartialCommitIT
+ */
+ private final Map<TableRef, Map<ImmutableBytesPtr,RowMutationState>>
mutations = Maps.newTreeMap(new TableRefComparator());
--- End diff --
@JamesRTaylor, can you take a look now? Switched back to using HashCode in
MutationState. PartialCommitIT now has the ability to substitue it for a
TreeMap to get consistent mutation sort order.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---