Refactored Hyarcks API into a separate Maven project
git-svn-id: https://hyracks.googlecode.com/svn/trunk@32 123451ca-8445-de46-9d55-352943316053
diff --git a/hyracks/hyracks-api/.classpath b/hyracks/hyracks-api/.classpath
new file mode 100644
index 0000000..1f3c1ff
--- /dev/null
+++ b/hyracks/hyracks-api/.classpath
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="src" output="target/classes" path="src/main/java"/>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
+ <classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
+ <classpathentry kind="output" path="target/classes"/>
+</classpath>
diff --git a/hyracks/hyracks-api/.project b/hyracks/hyracks-api/.project
new file mode 100644
index 0000000..4ae9e54
--- /dev/null
+++ b/hyracks/hyracks-api/.project
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>hyracks-api</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.maven.ide.eclipse.maven2Builder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.maven.ide.eclipse.maven2Nature</nature>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ </natures>
+</projectDescription>
diff --git a/hyracks/hyracks-api/.settings/org.eclipse.jdt.core.prefs b/hyracks/hyracks-api/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 0000000..a0e106b
--- /dev/null
+++ b/hyracks/hyracks-api/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,6 @@
+#Thu Jul 29 01:10:06 PDT 2010
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
+org.eclipse.jdt.core.compiler.source=1.6
diff --git a/hyracks/hyracks-api/.settings/org.maven.ide.eclipse.prefs b/hyracks/hyracks-api/.settings/org.maven.ide.eclipse.prefs
new file mode 100644
index 0000000..930b4a1
--- /dev/null
+++ b/hyracks/hyracks-api/.settings/org.maven.ide.eclipse.prefs
@@ -0,0 +1,9 @@
+#Thu Jul 29 01:10:05 PDT 2010
+activeProfiles=
+eclipse.preferences.version=1
+fullBuildGoals=process-test-resources
+includeModules=false
+resolveWorkspaceProjects=true
+resourceFilterGoals=process-resources resources\:testResources
+skipCompilerPlugin=true
+version=1
diff --git a/hyracks/hyracks-api/pom.xml b/hyracks/hyracks-api/pom.xml
new file mode 100644
index 0000000..9bec30c
--- /dev/null
+++ b/hyracks/hyracks-api/pom.xml
@@ -0,0 +1,28 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>edu.uci.ics.hyracks</groupId>
+ <artifactId>hyracks-api</artifactId>
+ <version>0.1.0</version>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>2.0.2</version>
+ <configuration>
+ <source>1.6</source>
+ <target>1.6</target>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ <dependencies>
+ <dependency>
+ <groupId>org.json</groupId>
+ <artifactId>json</artifactId>
+ <version>20090211</version>
+ <type>jar</type>
+ <scope>compile</scope>
+ </dependency>
+ </dependencies>
+</project>
diff --git a/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/AbstractHyracksConnection.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/AbstractHyracksConnection.java
new file mode 100644
index 0000000..2bb44e0
--- /dev/null
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/AbstractHyracksConnection.java
@@ -0,0 +1,78 @@
+/*
+ * 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.api.client;
+
+import java.net.InetAddress;
+import java.util.EnumSet;
+import java.util.Map;
+import java.util.UUID;
+
+import edu.uci.ics.hyracks.api.job.JobFlag;
+import edu.uci.ics.hyracks.api.job.JobSpecification;
+import edu.uci.ics.hyracks.api.job.JobStatus;
+import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
+
+abstract class AbstractHyracksConnection implements IHyracksClientConnection {
+ private IHyracksClientInterface hci;
+
+ public AbstractHyracksConnection(IHyracksClientInterface hci) {
+ this.hci = hci;
+ }
+
+ @Override
+ public void createApplication(String appName) throws Exception {
+ hci.createApplication(appName);
+ }
+
+ @Override
+ public void startApplication(String appName) throws Exception {
+ hci.startApplication(appName);
+ }
+
+ @Override
+ public void destroyApplication(String appName) throws Exception {
+ hci.destroyApplication(appName);
+ }
+
+ @Override
+ public UUID createJob(JobSpecification jobSpec) throws Exception {
+ return hci.createJob(jobSpec);
+ }
+
+ @Override
+ public UUID createJob(JobSpecification jobSpec, EnumSet<JobFlag> jobFlags) throws Exception {
+ return hci.createJob(jobSpec, jobFlags);
+ }
+
+ @Override
+ public JobStatus getJobStatus(UUID jobId) throws Exception {
+ return hci.getJobStatus(jobId);
+ }
+
+ @Override
+ public void start(UUID jobId) throws Exception {
+ hci.start(jobId);
+ }
+
+ @Override
+ public JobStatistics waitForCompletion(UUID jobId) throws Exception {
+ return hci.waitForCompletion(jobId);
+ }
+
+ @Override
+ public Map<String, InetAddress[]> getRegistry() throws Exception {
+ return hci.getRegistry();
+ }
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksLocalConnection.java
similarity index 72%
copy from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java
copy to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksLocalConnection.java
index cc76bd4..df1ff2b 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksLocalConnection.java
@@ -12,12 +12,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.comm;
+package edu.uci.ics.hyracks.api.client;
-public interface FrameConstants {
- public static final int SIZE_LEN = 4;
-
- public static final boolean DEBUG_FRAME_IO = false;
-
- public static final int FRAME_FIELD_MAGIC = 0x12345678;
+public final class HyracksLocalConnection extends AbstractHyracksConnection {
+ public HyracksLocalConnection(IHyracksClientInterface hci) {
+ super(hci);
+ }
}
\ No newline at end of file
diff --git a/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksRMIConnection.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksRMIConnection.java
new file mode 100644
index 0000000..18c354b
--- /dev/null
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/HyracksRMIConnection.java
@@ -0,0 +1,31 @@
+/*
+ * 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.api.client;
+
+import java.rmi.NotBoundException;
+import java.rmi.RemoteException;
+import java.rmi.registry.LocateRegistry;
+import java.rmi.registry.Registry;
+
+public final class HyracksRMIConnection extends AbstractHyracksConnection {
+ public HyracksRMIConnection(String host, int port) throws RemoteException, NotBoundException {
+ super(lookupHCI(host, port));
+ }
+
+ private static IHyracksClientInterface lookupHCI(String host, int port) throws RemoteException, NotBoundException {
+ Registry registry = LocateRegistry.getRegistry(host, port);
+ return (IHyracksClientInterface) registry.lookup(IHyracksClientInterface.class.getName());
+ }
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientConnection.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientConnection.java
new file mode 100644
index 0000000..ef11fd0
--- /dev/null
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientConnection.java
@@ -0,0 +1,45 @@
+/*
+ * 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.api.client;
+
+import java.net.InetAddress;
+import java.util.EnumSet;
+import java.util.Map;
+import java.util.UUID;
+
+import edu.uci.ics.hyracks.api.job.JobFlag;
+import edu.uci.ics.hyracks.api.job.JobSpecification;
+import edu.uci.ics.hyracks.api.job.JobStatus;
+import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
+
+public interface IHyracksClientConnection {
+ public void createApplication(String appName) throws Exception;
+
+ public void startApplication(String appName) throws Exception;
+
+ public void destroyApplication(String appName) throws Exception;
+
+ public UUID createJob(JobSpecification jobSpec) throws Exception;
+
+ public UUID createJob(JobSpecification jobSpec, EnumSet<JobFlag> jobFlags) throws Exception;
+
+ public JobStatus getJobStatus(UUID jobId) throws Exception;
+
+ public void start(UUID jobId) throws Exception;
+
+ public JobStatistics waitForCompletion(UUID jobId) throws Exception;
+
+ public Map<String, InetAddress[]> getRegistry() throws Exception;
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientInterface.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientInterface.java
new file mode 100644
index 0000000..229299f
--- /dev/null
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/client/IHyracksClientInterface.java
@@ -0,0 +1,46 @@
+/*
+ * 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.api.client;
+
+import java.net.InetAddress;
+import java.rmi.Remote;
+import java.util.EnumSet;
+import java.util.Map;
+import java.util.UUID;
+
+import edu.uci.ics.hyracks.api.job.JobFlag;
+import edu.uci.ics.hyracks.api.job.JobSpecification;
+import edu.uci.ics.hyracks.api.job.JobStatus;
+import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
+
+public interface IHyracksClientInterface extends Remote {
+ public void createApplication(String appName) throws Exception;
+
+ public void startApplication(String appName) throws Exception;
+
+ public void destroyApplication(String appName) throws Exception;
+
+ public UUID createJob(JobSpecification jobSpec) throws Exception;
+
+ public UUID createJob(JobSpecification jobSpec, EnumSet<JobFlag> jobFlags) throws Exception;
+
+ public JobStatus getJobStatus(UUID jobId) throws Exception;
+
+ public void start(UUID jobId) throws Exception;
+
+ public JobStatistics waitForCompletion(UUID jobId) throws Exception;
+
+ public Map<String, InetAddress[]> getRegistry() throws Exception;
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionDemultiplexer.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionDemultiplexer.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionDemultiplexer.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionDemultiplexer.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionEntry.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionEntry.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionEntry.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IConnectionEntry.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListener.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListener.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListener.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListener.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListenerFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListenerFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListenerFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IDataReceiveListenerFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameReader.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameReader.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameReader.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameReader.java
diff --git a/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameTupleAccessor.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameTupleAccessor.java
new file mode 100644
index 0000000..88b8768
--- /dev/null
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameTupleAccessor.java
@@ -0,0 +1,21 @@
+package edu.uci.ics.hyracks.api.comm;
+
+import java.nio.ByteBuffer;
+
+public interface IFrameTupleAccessor {
+ public int getFieldSlotsLength();
+
+ public int getFieldEndOffset(int tupleIndex, int fIdx);
+
+ public int getFieldStartOffset(int tupleIndex, int fIdx);
+
+ public int getTupleEndOffset(int tupleIndex);
+
+ public int getTupleStartOffset(int tupleIndex);
+
+ public int getTupleCount();
+
+ public ByteBuffer getBuffer();
+
+ public void reset(ByteBuffer buffer);
+}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameWriter.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameWriter.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameWriter.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/comm/IFrameWriter.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/AbsoluteLocationConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/AbsoluteLocationConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/AbsoluteLocationConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/AbsoluteLocationConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/ChoiceLocationConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/ChoiceLocationConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/ChoiceLocationConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/ChoiceLocationConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/ExplicitPartitionConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/ExplicitPartitionConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/ExplicitPartitionConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/ExplicitPartitionConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/LocationConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/LocationConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/LocationConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/LocationConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionCountConstraint.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionCountConstraint.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionCountConstraint.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/constraints/PartitionCountConstraint.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/context/IHyracksContext.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/context/IHyracksContext.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/context/IHyracksContext.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/context/IHyracksContext.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/ActivityNodeId.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/ActivityNodeId.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/ActivityNodeId.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/ActivityNodeId.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/ConnectorDescriptorId.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/ConnectorDescriptorId.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/ConnectorDescriptorId.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/ConnectorDescriptorId.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/Direction.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/Direction.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/Direction.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/Direction.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityGraphBuilder.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityGraphBuilder.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityGraphBuilder.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityGraphBuilder.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityNode.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityNode.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityNode.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IActivityNode.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IConnectorDescriptor.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IConnectorDescriptor.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IConnectorDescriptor.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IConnectorDescriptor.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataReader.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataReader.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataReader.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataReader.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataWriter.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataWriter.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataWriter.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IDataWriter.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IEndpointDataWriterFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IEndpointDataWriterFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IEndpointDataWriterFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IEndpointDataWriterFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataReader.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataReader.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataReader.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataReader.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataWriter.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataWriter.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataWriter.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOpenableDataWriter.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorDescriptor.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorDescriptor.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorDescriptor.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorDescriptor.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePullable.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePullable.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePullable.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePullable.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePushable.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePushable.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePushable.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/IOperatorNodePushable.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorDescriptorId.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorDescriptorId.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorDescriptorId.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorDescriptorId.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorInstanceId.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorInstanceId.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorInstanceId.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/OperatorInstanceId.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/PortInstanceId.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/PortInstanceId.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/PortInstanceId.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/PortInstanceId.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparator.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparator.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparator.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparator.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparatorFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparatorFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparatorFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryComparatorFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunction.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunction.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunction.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunction.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunctionFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunctionFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunctionFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IBinaryHashFunctionFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparator.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparator.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparator.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparator.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparatorFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparatorFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparatorFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IComparatorFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunction.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunction.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunction.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunction.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunctionFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunctionFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunctionFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IHashFunctionFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IRecordDescriptorProvider.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IRecordDescriptorProvider.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IRecordDescriptorProvider.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/IRecordDescriptorProvider.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ISerializerDeserializer.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ISerializerDeserializer.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ISerializerDeserializer.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ISerializerDeserializer.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java
similarity index 82%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java
index d9b023d..baf9d5c 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java
+++ b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputer.java
@@ -14,9 +14,9 @@
*/
package edu.uci.ics.hyracks.api.dataflow.value;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
-import edu.uci.ics.hyracks.comm.io.FrameTupleAccessor;
public interface ITuplePartitionComputer {
- public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException;
+ public int partition(IFrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException;
}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputerFactory.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputerFactory.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputerFactory.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/ITuplePartitionComputerFactory.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/RecordDescriptor.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/RecordDescriptor.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/RecordDescriptor.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/dataflow/value/RecordDescriptor.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/exceptions/HyracksDataException.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/exceptions/HyracksDataException.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/exceptions/HyracksDataException.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/exceptions/HyracksDataException.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/IOperatorEnvironment.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/IOperatorEnvironment.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/IOperatorEnvironment.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/IOperatorEnvironment.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobFlag.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobFlag.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobFlag.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobFlag.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobSpecification.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobSpecification.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobSpecification.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobSpecification.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobStatus.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobStatus.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobStatus.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/JobStatus.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/JobStatistics.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/JobStatistics.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/JobStatistics.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/JobStatistics.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageStatistics.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageStatistics.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageStatistics.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageStatistics.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageletStatistics.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageletStatistics.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageletStatistics.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/job/statistics/StageletStatistics.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/IResource.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/IResource.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/IResource.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/IResource.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/IResourceManager.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/IResourceManager.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/IResourceManager.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/IResourceManager.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/ISpaceSharedResource.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/ISpaceSharedResource.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/ISpaceSharedResource.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/ISpaceSharedResource.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/ITimeSharedResource.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/ITimeSharedResource.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/resources/ITimeSharedResource.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/resources/ITimeSharedResource.java
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/util/Pair.java b/hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/util/Pair.java
similarity index 100%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/util/Pair.java
rename to hyracks/hyracks-api/src/main/java/edu/uci/ics/hyracks/api/util/Pair.java
diff --git a/hyracks/hyracks-core/pom.xml b/hyracks/hyracks-core/pom.xml
index 0222956..73a4cf6 100644
--- a/hyracks/hyracks-core/pom.xml
+++ b/hyracks/hyracks-core/pom.xml
@@ -136,6 +136,13 @@
<type>jar</type>
<scope>compile</scope>
</dependency>
+ <dependency>
+ <groupId>edu.uci.ics.hyracks</groupId>
+ <artifactId>hyracks-api</artifactId>
+ <version>0.1.0</version>
+ <type>jar</type>
+ <scope>compile</scope>
+ </dependency>
</dependencies>
<reporting>
<plugins>
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/IClusterController.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/IClusterController.java
index 6461a05..c1ed4c1 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/IClusterController.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/IClusterController.java
@@ -15,49 +15,20 @@
package edu.uci.ics.hyracks.api.controller;
import java.rmi.Remote;
-import java.util.EnumSet;
-import java.util.Map;
import java.util.UUID;
-import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobSpecification;
-import edu.uci.ics.hyracks.api.job.JobStatus;
-import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
+import edu.uci.ics.hyracks.api.client.IHyracksClientInterface;
import edu.uci.ics.hyracks.api.job.statistics.StageletStatistics;
-public interface IClusterController extends Remote {
+public interface IClusterController extends Remote, IHyracksClientInterface {
public NodeParameters registerNode(INodeController nodeController) throws Exception;
public void unregisterNode(INodeController nodeController) throws Exception;
public void notifyStageletComplete(UUID jobId, UUID stageId, int attempt, String nodeId,
- StageletStatistics statistics) throws Exception;
+ StageletStatistics statistics) throws Exception;
public void notifyStageletFailure(UUID jobId, UUID stageId, int attempt, String nodeId) throws Exception;
public void nodeHeartbeat(String id) throws Exception;
-
- /*
- * Client Application Control Methods.
- */
- public void createApplication(String appName) throws Exception;
-
- public void startApplication(String appName) throws Exception;
-
- public void destroyApplication(String appName) throws Exception;
-
- /*
- * Client Job Control methods.
- */
- public UUID createJob(JobSpecification jobSpec) throws Exception;
-
- public UUID createJob(JobSpecification jobSpec, EnumSet<JobFlag> jobFlags) throws Exception;
-
- public JobStatus getJobStatus(UUID jobId) throws Exception;
-
- public void start(UUID jobId) throws Exception;
-
- public JobStatistics waitForCompletion(UUID jobId) throws Exception;
-
- public Map<String, INodeController> getRegistry() throws Exception;
}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/INodeController.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/INodeController.java
index 264254e..8f46316 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/INodeController.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/controller/INodeController.java
@@ -19,12 +19,12 @@
import java.util.Set;
import java.util.UUID;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.dataflow.ActivityNodeId;
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.PortInstanceId;
-import edu.uci.ics.hyracks.api.job.JobPlan;
+import edu.uci.ics.hyracks.comm.Endpoint;
import edu.uci.ics.hyracks.config.NCConfig;
+import edu.uci.ics.hyracks.job.JobPlan;
public interface INodeController extends Remote {
public String getId() throws Exception;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ConnectionManager.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ConnectionManager.java
index ce752f3..b161fe2 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ConnectionManager.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ConnectionManager.java
@@ -35,14 +35,13 @@
import java.util.logging.Level;
import java.util.logging.Logger;
-import edu.uci.ics.hyracks.api.comm.FrameConstants;
import edu.uci.ics.hyracks.api.comm.IConnectionEntry;
import edu.uci.ics.hyracks.api.comm.IDataReceiveListener;
import edu.uci.ics.hyracks.api.comm.IDataReceiveListenerFactory;
import edu.uci.ics.hyracks.api.comm.IFrameWriter;
-import edu.uci.ics.hyracks.api.comm.NetworkAddress;
import edu.uci.ics.hyracks.api.context.IHyracksContext;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
+import edu.uci.ics.hyracks.comm.io.FrameConstants;
import edu.uci.ics.hyracks.comm.io.FrameHelper;
public class ConnectionManager {
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/Endpoint.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/Endpoint.java
similarity index 97%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/Endpoint.java
rename to hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/Endpoint.java
index c0d23c1..245c777 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/Endpoint.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/Endpoint.java
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.comm;
+package edu.uci.ics.hyracks.comm;
import java.io.Serializable;
import java.util.UUID;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ISenderProtocolStack.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ISenderProtocolStack.java
index c94c955..e038379 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ISenderProtocolStack.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/ISenderProtocolStack.java
@@ -14,7 +14,6 @@
*/
package edu.uci.ics.hyracks.comm;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.comm.IFrameWriter;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/NetworkAddress.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/NetworkAddress.java
similarity index 97%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/NetworkAddress.java
rename to hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/NetworkAddress.java
index 868221d..15db351 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/NetworkAddress.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/NetworkAddress.java
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.comm;
+package edu.uci.ics.hyracks.comm;
import java.io.Serializable;
import java.net.InetAddress;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/ArrayTupleBuilder.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/ArrayTupleBuilder.java
index d800fba..368f7a3 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/ArrayTupleBuilder.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/ArrayTupleBuilder.java
@@ -17,7 +17,6 @@
import java.io.DataOutputStream;
import java.io.IOException;
-import edu.uci.ics.hyracks.api.comm.FrameConstants;
import edu.uci.ics.hyracks.api.dataflow.value.ISerializerDeserializer;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameConstants.java
similarity index 95%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java
rename to hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameConstants.java
index cc76bd4..93aab63 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/comm/FrameConstants.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameConstants.java
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.comm;
+package edu.uci.ics.hyracks.comm.io;
public interface FrameConstants {
public static final int SIZE_LEN = 4;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameDeserializer.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameDeserializer.java
index c6b365b..499f692 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameDeserializer.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameDeserializer.java
@@ -20,7 +20,6 @@
import java.util.logging.Level;
import java.util.logging.Logger;
-import edu.uci.ics.hyracks.api.comm.FrameConstants;
import edu.uci.ics.hyracks.api.context.IHyracksContext;
import edu.uci.ics.hyracks.api.dataflow.value.RecordDescriptor;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameTupleAccessor.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameTupleAccessor.java
index 06c5a17..9a10136 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameTupleAccessor.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/comm/io/FrameTupleAccessor.java
@@ -17,6 +17,7 @@
import java.io.DataInputStream;
import java.nio.ByteBuffer;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.context.IHyracksContext;
import edu.uci.ics.hyracks.api.dataflow.value.RecordDescriptor;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
@@ -32,7 +33,7 @@
*
* @author vinayakb
*/
-public final class FrameTupleAccessor {
+public final class FrameTupleAccessor implements IFrameTupleAccessor {
private final IHyracksContext ctx;
private final RecordDescriptor recordDescriptor;
@@ -43,34 +44,42 @@
this.recordDescriptor = recordDescriptor;
}
+ @Override
public void reset(ByteBuffer buffer) {
this.buffer = buffer;
}
+ @Override
public ByteBuffer getBuffer() {
return buffer;
}
+ @Override
public int getTupleCount() {
return buffer.getInt(FrameHelper.getTupleCountOffset(ctx));
}
+ @Override
public int getTupleStartOffset(int tupleIndex) {
return tupleIndex == 0 ? 0 : buffer.getInt(FrameHelper.getTupleCountOffset(ctx) - 4 * tupleIndex);
}
+ @Override
public int getTupleEndOffset(int tupleIndex) {
return buffer.getInt(FrameHelper.getTupleCountOffset(ctx) - 4 * (tupleIndex + 1));
}
+ @Override
public int getFieldStartOffset(int tupleIndex, int fIdx) {
return fIdx == 0 ? 0 : buffer.getShort(getTupleStartOffset(tupleIndex) + (fIdx - 1) * 2);
}
+ @Override
public int getFieldEndOffset(int tupleIndex, int fIdx) {
return buffer.getShort(getTupleStartOffset(tupleIndex) + fIdx * 2);
}
+ @Override
public int getFieldSlotsLength() {
return recordDescriptor.getFields().length * 2;
}
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/ClusterControllerService.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/ClusterControllerService.java
index 367a356..543fca0 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/ClusterControllerService.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/ClusterControllerService.java
@@ -16,6 +16,7 @@
import java.io.IOException;
import java.io.PrintWriter;
+import java.net.InetAddress;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;
import java.util.EnumSet;
@@ -47,7 +48,6 @@
import org.eclipse.jetty.server.handler.AbstractHandler;
import org.eclipse.jetty.server.handler.ContextHandler;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.controller.IClusterController;
import edu.uci.ics.hyracks.api.controller.INodeController;
import edu.uci.ics.hyracks.api.controller.NodeParameters;
@@ -55,13 +55,14 @@
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.PortInstanceId;
import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobPlan;
import edu.uci.ics.hyracks.api.job.JobSpecification;
import edu.uci.ics.hyracks.api.job.JobStatus;
import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
import edu.uci.ics.hyracks.api.job.statistics.StageletStatistics;
+import edu.uci.ics.hyracks.comm.Endpoint;
import edu.uci.ics.hyracks.config.CCConfig;
import edu.uci.ics.hyracks.controller.AbstractRemoteService;
+import edu.uci.ics.hyracks.job.JobPlan;
import edu.uci.ics.hyracks.web.WebServer;
public class ClusterControllerService extends AbstractRemoteService implements IClusterController {
@@ -247,12 +248,13 @@
}
@Override
- public Map<String, INodeController> getRegistry() throws Exception {
+ public Map<String, InetAddress[]> getRegistry() throws Exception {
Map<String, INodeController> map = new HashMap<String, INodeController>();
for (Map.Entry<String, NodeControllerState> e : nodeRegistry.entrySet()) {
map.put(e.getKey(), e.getValue().getNodeController());
}
- return map;
+ // return map;
+ throw new UnsupportedOperationException();
}
@Override
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JOLJobManagerImpl.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JOLJobManagerImpl.java
index e8b6f14..11d5ba5 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JOLJobManagerImpl.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JOLJobManagerImpl.java
@@ -36,7 +36,6 @@
import jol.types.table.Function;
import jol.types.table.Key;
import jol.types.table.TableName;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.constraints.AbsoluteLocationConstraint;
import edu.uci.ics.hyracks.api.constraints.ChoiceLocationConstraint;
import edu.uci.ics.hyracks.api.constraints.ExplicitPartitionConstraint;
@@ -53,12 +52,13 @@
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.PortInstanceId;
import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobPlan;
import edu.uci.ics.hyracks.api.job.JobSpecification;
import edu.uci.ics.hyracks.api.job.JobStatus;
import edu.uci.ics.hyracks.api.job.statistics.JobStatistics;
import edu.uci.ics.hyracks.api.job.statistics.StageStatistics;
import edu.uci.ics.hyracks.api.job.statistics.StageletStatistics;
+import edu.uci.ics.hyracks.comm.Endpoint;
+import edu.uci.ics.hyracks.job.JobPlan;
public class JOLJobManagerImpl implements IJobManager {
private static final Logger LOGGER = Logger.getLogger(JOLJobManagerImpl.class.getName());
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanBuilder.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanBuilder.java
index d748a13..8781233 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanBuilder.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanBuilder.java
@@ -12,8 +12,8 @@
import edu.uci.ics.hyracks.api.dataflow.IActivityGraphBuilder;
import edu.uci.ics.hyracks.api.dataflow.IActivityNode;
import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobPlan;
import edu.uci.ics.hyracks.api.job.JobSpecification;
+import edu.uci.ics.hyracks.job.JobPlan;
public class JobPlanBuilder implements IActivityGraphBuilder {
private static final Logger LOGGER = Logger.getLogger(JobPlanBuilder.class.getName());
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanner.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanner.java
index f992de1..816570e 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanner.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/clustercontroller/JobPlanner.java
@@ -29,12 +29,12 @@
import edu.uci.ics.hyracks.api.dataflow.IOperatorDescriptor;
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobPlan;
import edu.uci.ics.hyracks.api.job.JobSpecification;
-import edu.uci.ics.hyracks.api.job.JobStage;
import edu.uci.ics.hyracks.api.util.Pair;
import edu.uci.ics.hyracks.dataflow.base.IOperatorDescriptorVisitor;
import edu.uci.ics.hyracks.dataflow.util.PlanUtils;
+import edu.uci.ics.hyracks.job.JobPlan;
+import edu.uci.ics.hyracks.job.JobStage;
public class JobPlanner {
private static final Logger LOGGER = Logger.getLogger(JobPlanner.class.getName());
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/NodeControllerService.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/NodeControllerService.java
index 682d6a2..2ebaa2e 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/NodeControllerService.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/NodeControllerService.java
@@ -34,7 +34,6 @@
import java.util.regex.Matcher;
import java.util.regex.Pattern;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.comm.IConnectionDemultiplexer;
import edu.uci.ics.hyracks.api.comm.IFrameReader;
import edu.uci.ics.hyracks.api.comm.IFrameWriter;
@@ -57,14 +56,15 @@
import edu.uci.ics.hyracks.api.dataflow.value.RecordDescriptor;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
import edu.uci.ics.hyracks.api.job.JobFlag;
-import edu.uci.ics.hyracks.api.job.JobPlan;
import edu.uci.ics.hyracks.api.job.JobSpecification;
import edu.uci.ics.hyracks.api.job.statistics.StageletStatistics;
import edu.uci.ics.hyracks.comm.ConnectionManager;
import edu.uci.ics.hyracks.comm.DemuxDataReceiveListenerFactory;
+import edu.uci.ics.hyracks.comm.Endpoint;
import edu.uci.ics.hyracks.config.NCConfig;
import edu.uci.ics.hyracks.context.HyracksContext;
import edu.uci.ics.hyracks.controller.AbstractRemoteService;
+import edu.uci.ics.hyracks.job.JobPlan;
import edu.uci.ics.hyracks.runtime.OperatorRunnable;
public class NodeControllerService extends AbstractRemoteService implements INodeController {
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/Stagelet.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/Stagelet.java
index 32793eb..c9bbc29 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/Stagelet.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/controller/nodecontroller/Stagelet.java
@@ -25,10 +25,10 @@
import java.util.logging.Level;
import java.util.logging.Logger;
-import edu.uci.ics.hyracks.api.comm.Endpoint;
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.OperatorInstanceId;
import edu.uci.ics.hyracks.api.job.statistics.StageletStatistics;
+import edu.uci.ics.hyracks.comm.Endpoint;
import edu.uci.ics.hyracks.runtime.OperatorRunnable;
public class Stagelet {
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/ExternalSortOperatorDescriptor.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/ExternalSortOperatorDescriptor.java
index 9f94086..cca90cf 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/ExternalSortOperatorDescriptor.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/ExternalSortOperatorDescriptor.java
@@ -26,6 +26,7 @@
import java.util.List;
import edu.uci.ics.hyracks.api.comm.IFrameReader;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.comm.IFrameWriter;
import edu.uci.ics.hyracks.api.context.IHyracksContext;
import edu.uci.ics.hyracks.api.dataflow.IActivityGraphBuilder;
@@ -442,7 +443,7 @@
}
}
- private void closeRun(int index, RunFileReader[] runCursors, FrameTupleAccessor[] tupleAccessor) {
+ private void closeRun(int index, RunFileReader[] runCursors, IFrameTupleAccessor[] tupleAccessor) {
runCursors[index] = null;
tupleAccessor[index] = null;
}
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/FieldHashPartitionComputerFactory.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/FieldHashPartitionComputerFactory.java
index ab66fb4..24c277d 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/FieldHashPartitionComputerFactory.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/FieldHashPartitionComputerFactory.java
@@ -14,11 +14,11 @@
*/
package edu.uci.ics.hyracks.coreops;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.dataflow.value.IBinaryHashFunction;
import edu.uci.ics.hyracks.api.dataflow.value.IBinaryHashFunctionFactory;
import edu.uci.ics.hyracks.api.dataflow.value.ITuplePartitionComputer;
import edu.uci.ics.hyracks.api.dataflow.value.ITuplePartitionComputerFactory;
-import edu.uci.ics.hyracks.comm.io.FrameTupleAccessor;
public class FieldHashPartitionComputerFactory implements ITuplePartitionComputerFactory {
private static final long serialVersionUID = 1L;
@@ -38,7 +38,7 @@
}
return new ITuplePartitionComputer() {
@Override
- public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) {
+ public int partition(IFrameTupleAccessor accessor, int tIndex, int nParts) {
int h = 0;
int startOffset = accessor.getTupleStartOffset(tIndex);
int slotLength = accessor.getFieldSlotsLength();
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
index dbb1780..2dd7092 100644
--- 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
@@ -14,10 +14,10 @@
*/
package edu.uci.ics.hyracks.coreops;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
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;
@@ -36,7 +36,7 @@
private ITuplePartitionComputer delegate = delegateFactory.createPartitioner();
@Override
- public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
+ public int partition(IFrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
return delegate.partition(accessor, tIndex, factor * nParts) / factor;
}
};
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/group/IAccumulatingAggregator.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/group/IAccumulatingAggregator.java
index d9e9337..ac1dc13 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/group/IAccumulatingAggregator.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/group/IAccumulatingAggregator.java
@@ -14,8 +14,8 @@
*/
package edu.uci.ics.hyracks.coreops.group;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.exceptions.HyracksDataException;
-import edu.uci.ics.hyracks.comm.io.FrameTupleAccessor;
import edu.uci.ics.hyracks.comm.io.FrameTupleAppender;
public interface IAccumulatingAggregator {
@@ -28,7 +28,7 @@
* - Index of the tuple in the accessor.
* @throws HyracksDataException
*/
- public void init(FrameTupleAccessor accessor, int tIndex) throws HyracksDataException;
+ public void init(IFrameTupleAccessor accessor, int tIndex) throws HyracksDataException;
/**
* Called once per tuple that belongs to this group.
@@ -39,7 +39,7 @@
* - Index of tuple in the accessor.
* @throws HyracksDataException
*/
- public void accumulate(FrameTupleAccessor accessor, int tIndex) throws HyracksDataException;
+ public void accumulate(IFrameTupleAccessor accessor, int tIndex) throws HyracksDataException;
/**
* Called finally to emit output. This method is called until it returns true. The method is free to
@@ -55,6 +55,6 @@
* @return true if all output is written, false if the appender is full.
* @throws HyracksDataException
*/
- public boolean output(FrameTupleAppender appender, FrameTupleAccessor accessor, int tIndex)
+ public boolean output(FrameTupleAppender appender, IFrameTupleAccessor accessor, int tIndex)
throws HyracksDataException;
}
\ No newline at end of file
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/HadoopReadOperatorDescriptor.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/HadoopReadOperatorDescriptor.java
index 7ec0eab..c17e62e 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/HadoopReadOperatorDescriptor.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/HadoopReadOperatorDescriptor.java
@@ -175,7 +175,8 @@
List<LocationConstraint> locationConstraints = new ArrayList<LocationConstraint>();
Map<String, INodeController> registry = null;
try {
- registry = clusterController.getRegistry();
+ // registry = clusterController.getRegistry();
+ // TODO
} catch (Exception e) {
e.printStackTrace();
}
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopHashTuplePartitionComputerFactory.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopHashTuplePartitionComputerFactory.java
index e361ebb..501a224 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopHashTuplePartitionComputerFactory.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopHashTuplePartitionComputerFactory.java
@@ -18,11 +18,11 @@
import org.apache.hadoop.io.Writable;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.dataflow.value.ISerializerDeserializer;
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;
import edu.uci.ics.hyracks.comm.util.ByteBufferInputStream;
public class HadoopHashTuplePartitionComputerFactory<K extends Writable> implements ITuplePartitionComputerFactory {
@@ -40,7 +40,7 @@
private final DataInputStream dis = new DataInputStream(bbis);
@Override
- public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
+ public int partition(IFrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
int keyStart = accessor.getTupleStartOffset(tIndex) + accessor.getFieldSlotsLength()
+ accessor.getFieldStartOffset(tIndex, 0);
bbis.setByteBuffer(accessor.getBuffer(), keyStart);
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopPartitionerTuplePartitionComputerFactory.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopPartitionerTuplePartitionComputerFactory.java
index a80682f..5c97ba8 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopPartitionerTuplePartitionComputerFactory.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/coreops/hadoop/data/HadoopPartitionerTuplePartitionComputerFactory.java
@@ -19,11 +19,11 @@
import org.apache.hadoop.io.Writable;
import org.apache.hadoop.mapred.Partitioner;
+import edu.uci.ics.hyracks.api.comm.IFrameTupleAccessor;
import edu.uci.ics.hyracks.api.dataflow.value.ISerializerDeserializer;
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;
import edu.uci.ics.hyracks.comm.util.ByteBufferInputStream;
public class HadoopPartitionerTuplePartitionComputerFactory<K extends Writable, V extends Writable> extends
@@ -46,7 +46,7 @@
private final DataInputStream dis = new DataInputStream(bbis);
@Override
- public int partition(FrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
+ public int partition(IFrameTupleAccessor accessor, int tIndex, int nParts) throws HyracksDataException {
int keyStart = accessor.getTupleStartOffset(tIndex) + accessor.getFieldSlotsLength()
+ accessor.getFieldStartOffset(tIndex, 0);
bbis.setByteBuffer(accessor.getBuffer(), keyStart);
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobPlan.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobPlan.java
similarity index 97%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobPlan.java
rename to hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobPlan.java
index 8c71438..5516870 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobPlan.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobPlan.java
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.job;
+package edu.uci.ics.hyracks.job;
import java.io.Serializable;
import java.util.ArrayList;
@@ -27,6 +27,8 @@
import edu.uci.ics.hyracks.api.dataflow.IConnectorDescriptor;
import edu.uci.ics.hyracks.api.dataflow.OperatorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.value.RecordDescriptor;
+import edu.uci.ics.hyracks.api.job.JobFlag;
+import edu.uci.ics.hyracks.api.job.JobSpecification;
public class JobPlan implements Serializable {
private static final long serialVersionUID = 1L;
diff --git a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobStage.java b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobStage.java
similarity index 98%
rename from hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobStage.java
rename to hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobStage.java
index 41187f1..0048ce9 100644
--- a/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/api/job/JobStage.java
+++ b/hyracks/hyracks-core/src/main/java/edu/uci/ics/hyracks/job/JobStage.java
@@ -12,7 +12,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package edu.uci.ics.hyracks.api.job;
+package edu.uci.ics.hyracks.job;
import java.io.Serializable;
import java.util.HashSet;
diff --git a/hyracks/hyracks-core/src/main/resources/edu/uci/ics/hyracks/controller/clustercontroller/scheduler.olg b/hyracks/hyracks-core/src/main/resources/edu/uci/ics/hyracks/controller/clustercontroller/scheduler.olg
index 3f03526..d346467 100644
--- a/hyracks/hyracks-core/src/main/resources/edu/uci/ics/hyracks/controller/clustercontroller/scheduler.olg
+++ b/hyracks/hyracks-core/src/main/resources/edu/uci/ics/hyracks/controller/clustercontroller/scheduler.olg
@@ -12,7 +12,7 @@
import edu.uci.ics.hyracks.api.dataflow.ConnectorDescriptorId;
import edu.uci.ics.hyracks.api.dataflow.IConnectorDescriptor;
import edu.uci.ics.hyracks.api.job.JobStatus;
-import edu.uci.ics.hyracks.api.job.JobPlan;
+import edu.uci.ics.hyracks.job.JobPlan;
define(activitystage_temp, keys(), {UUID, OperatorDescriptorId, ActivityNodeId, Integer});
diff --git a/hyracks/hyracks-core/src/test/java/edu/uci/ics/hyracks/tests/integration/AbstractIntegrationTest.java b/hyracks/hyracks-core/src/test/java/edu/uci/ics/hyracks/tests/integration/AbstractIntegrationTest.java
index 8505531..30b6ce4 100644
--- a/hyracks/hyracks-core/src/test/java/edu/uci/ics/hyracks/tests/integration/AbstractIntegrationTest.java
+++ b/hyracks/hyracks-core/src/test/java/edu/uci/ics/hyracks/tests/integration/AbstractIntegrationTest.java
@@ -20,6 +20,8 @@
import org.junit.AfterClass;
import org.junit.BeforeClass;
+import edu.uci.ics.hyracks.api.client.HyracksLocalConnection;
+import edu.uci.ics.hyracks.api.client.IHyracksClientConnection;
import edu.uci.ics.hyracks.api.job.JobFlag;
import edu.uci.ics.hyracks.api.job.JobSpecification;
import edu.uci.ics.hyracks.config.CCConfig;
@@ -31,9 +33,10 @@
public static final String NC1_ID = "nc1";
public static final String NC2_ID = "nc2";
- protected static ClusterControllerService cc;
- protected static NodeControllerService nc1;
- protected static NodeControllerService nc2;
+ private static ClusterControllerService cc;
+ private static NodeControllerService nc1;
+ private static NodeControllerService nc2;
+ private static IHyracksClientConnection hcc;
@BeforeClass
public static void init() throws Exception {
@@ -58,6 +61,8 @@
ncConfig2.nodeId = NC2_ID;
nc2 = new NodeControllerService(ncConfig2);
nc2.start();
+
+ hcc = new HyracksLocalConnection(cc);
}
@AfterClass
@@ -68,9 +73,9 @@
}
void runTest(JobSpecification spec) throws Exception {
- UUID jobId = cc.createJob(spec, EnumSet.of(JobFlag.COLLECT_FRAME_COUNTS));
+ UUID jobId = hcc.createJob(spec, EnumSet.of(JobFlag.COLLECT_FRAME_COUNTS));
System.err.println(spec.toJSON());
- cc.start(jobId);
+ hcc.start(jobId);
System.err.print(jobId);
System.err.println(cc.waitForCompletion(jobId));
}
diff --git a/hyracks/pom.xml b/hyracks/pom.xml
index 40634f5..4346027 100644
--- a/hyracks/pom.xml
+++ b/hyracks/pom.xml
@@ -6,6 +6,7 @@
<packaging>pom</packaging>
<modules>
+ <module>hyracks-api</module>
<module>hyracks-core</module>
</modules>
</project>