diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/RepartitionComputerFactory.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/RepartitionComputerFactory.java
new file mode 100644
index 0000000..dbb1780
--- /dev/null
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/RepartitionComputerFactory.java
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2009-2010 by The Regents of the University of California
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * you may obtain a copy of the License from
+ * 
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package edu.uci.ics.hyracks.coreops;
+
+import edu.uci.ics.hyracks.api.dataflow.value.ITuplePartitionComputer;
+import edu.uci.ics.hyracks.api.dataflow.value.ITuplePartitionComputerFactory;
+import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
+import edu.uci.ics.hyracks.comm.io.FrameTupleAccessor;
+
+public class RepartitionComputerFactory implements ITuplePartitionComputerFactory {
+    private static final long serialVersionUID = 1L;
+
+    private int factor;
+    private ITuplePartitionComputerFactory delegateFactory;
+
+    public RepartitionComputerFactory(int factor, ITuplePartitionComputerFactory delegate) {
+        this.factor = factor;
+        this.delegateFactory = delegate;
+    }
+
+    @Override
+    public ITuplePartitionComputer createPartitioner() {
+        return new ITuplePartitionComputer() {
+            private ITuplePartitionComputer delegate = delegateFactory.createPartitioner();
+
+            @Override
+            public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
+                return delegate.partition(accessor, tIndex, factor * nParts) / factor;
+            }
+        };
+    }
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/GraceHashJoinOperatorDescriptor.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/GraceHashJoinOperatorDescriptor.java
index 79d88af..c38b9ce 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/GraceHashJoinOperatorDescriptor.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/GraceHashJoinOperatorDescriptor.java
@@ -40,6 +40,7 @@
 import edu.uci.ics.hyracks.comm.util.FrameUtils;
 import edu.uci.ics.hyracks.context.HyracksContext;
 import edu.uci.ics.hyracks.coreops.FieldHashPartitionComputerFactory;
+import edu.uci.ics.hyracks.coreops.RepartitionComputerFactory;
 import edu.uci.ics.hyracks.coreops.base.AbstractActivityNode;
 import edu.uci.ics.hyracks.coreops.base.AbstractOperatorDescriptor;
 
@@ -264,10 +265,6 @@
 
             IOperatorNodePushable op = new IOperatorNodePushable() {
                 private InMemoryHashJoin joiner;
-                private ITuplePartitionComputer hpc0 = new FieldHashPartitionComputerFactory(keys0,
-                        hashFunctionFactories).createPartitioner();
-                private ITuplePartitionComputer hpc1 = new FieldHashPartitionComputerFactory(keys1,
-                        hashFunctionFactories).createPartitioner();
 
                 private IFrameWriter writer;
                 private FileChannel[] channelsR;
@@ -281,8 +278,10 @@
                     channelsS = (FileChannel[]) env.get(LARGERELATION);
                     numPartitions = (Integer) env.get(NUM_PARTITION);
 
-                    ITuplePartitionComputer hpcRep0 = new RepartitionComputer(numPartitions, hpc0);
-                    ITuplePartitionComputer hpcRep1 = new RepartitionComputer(numPartitions, hpc1);
+                    ITuplePartitionComputer hpcRep0 = new RepartitionComputerFactory(numPartitions,
+                            new FieldHashPartitionComputerFactory(keys0, hashFunctionFactories)).createPartitioner();
+                    ITuplePartitionComputer hpcRep1 = new RepartitionComputerFactory(numPartitions,
+                            new FieldHashPartitionComputerFactory(keys1, hashFunctionFactories)).createPartitioner();
 
                     writer.open();// open for probe
 
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/RepartitionComputer.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/RepartitionComputer.java
deleted file mode 100644
index c5c3af8..0000000
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/join/RepartitionComputer.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright 2009-2010 by The Regents of the University of California
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * you may obtain a copy of the License from
- * 
- *     http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package edu.uci.ics.hyracks.coreops.join;
-
-import edu.uci.ics.hyracks.api.dataflow.value.ITuplePartitionComputer;
-import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
-import edu.uci.ics.hyracks.comm.io.FrameTupleAccessor;
-
-public class RepartitionComputer implements ITuplePartitionComputer {
-    private int factor;
-    private ITuplePartitionComputer delegate;
-
-    public RepartitionComputer(int factor, ITuplePartitionComputer delegate) {
-        super();
-        this.factor = factor;
-        this.delegate = delegate;
-    }
-
-    @Override
-    public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
-        return delegate.partition(accessor, tIndex, factor * nParts) / factor;
-    }
-}
\ No newline at end of file
