Skip to content
Snippets Groups Projects
Commit 8184b8e3 authored by Jesper Fyhr Knudsen's avatar Jesper Fyhr Knudsen
Browse files

Replaced all internal calls with the new Webserver

parent 10243c72
Branches
No related tags found
No related merge requests found
Showing
with 675 additions and 921 deletions
......@@ -2,11 +2,24 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="057f0053-f4e8-40ac-9d01-6a2f351d655a" name="Default" comment="">
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentConnectResult.java" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentStateResult.java" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/KeyValue.java" />
<change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/ResponseTest.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java" afterPath="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java" afterPath="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java" afterPath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java" afterPath="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java" afterPath="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java" afterPath="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/LargeTasksTest.java" afterPath="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/LargeTasksTest.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java" afterPath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java" afterPath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java" afterPath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java" afterPath="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java" afterPath="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AllocationHandlerTest.java" afterPath="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AllocationHandlerTest.java" />
</list>
<ignored path="parent-project.iws" />
<ignored path=".idea/workspace.xml" />
......@@ -39,93 +52,44 @@
<favorites_list name="parent-project" />
</component>
<component name="FileEditorManager">
<splitter split-orientation="horizontal" split-proportion="0.5988157">
<split-first>
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="OrchestratorImpl.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java">
<file leaf-file-name="HeartbeatTest.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/Synchronization/HeartbeatTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="378">
<caret line="195" column="0" selection-start-line="195" selection-start-column="0" selection-end-line="195" selection-end-column="0" />
<state relative-caret-position="96">
<caret line="15" column="14" selection-start-line="15" selection-start-column="14" selection-end-line="15" selection-end-column="14" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="SimpleServer.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="584">
<caret line="113" column="0" selection-start-line="113" selection-start-column="0" selection-end-line="113" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#1326#1327#0" expanded="true" />
<element signature="e#1367#1368#0" expanded="true" />
<element signature="e#1492#1493#0" expanded="true" />
<element signature="e#1526#1527#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="OrchestratorProxy.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java">
<file leaf-file-name="DistributeToWorkersTest.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="336">
<caret line="55" column="26" selection-start-line="55" selection-start-column="26" selection-end-line="55" selection-end-column="26" />
<state relative-caret-position="85">
<caret line="12" column="24" selection-start-line="12" selection-start-column="24" selection-end-line="12" selection-end-column="24" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="NetworkingUtil.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/NetworkingUtil.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="256">
<caret line="28" column="6" selection-start-line="28" selection-start-column="6" selection-end-line="28" selection-end-column="6" />
<folding>
<element signature="e#701#702#0" expanded="true" />
<element signature="e#735#736#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
</leaf>
</split-first>
<split-second>
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="SimpleServerTest.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="14" column="6" selection-start-line="14" selection-start-column="6" selection-end-line="14" selection-end-column="6" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="DistributeToWorkersTest.java" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java">
<file leaf-file-name="AgentNetworkingTest.java" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/AgentNetworkingTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="432">
<caret line="38" column="36" selection-start-line="38" selection-start-column="36" selection-end-line="38" selection-end-column="36" />
<state relative-caret-position="208">
<caret line="39" column="20" selection-start-line="39" selection-start-column="20" selection-end-line="39" selection-end-column="20" />
<folding />
</state>
</provider>
</entry>
</file>
</leaf>
</split-second>
</splitter>
</component>
<component name="FileTemplateManagerImpl">
<option name="RECENT_TEMPLATES">
<list>
<option value="Class" />
<option value="Interface" />
<option value="Class" />
</list>
</option>
</component>
......@@ -141,20 +105,11 @@
<component name="IdeDocumentHistory">
<option name="CHANGED_PATHS">
<list>
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/TaskState.java" />
<option value="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/Synchronization/HeartbeatTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/Commands.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/messageSpecification/ConnectSpecification.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/sdk/test/ChaosTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/sdk/test/MockGateway.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/messages/Message.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/Message.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/StreamUtilities.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/NetworkingUtil.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/AgentStateMessage.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/v6/dto/ClusterState.java" />
<option value="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/AgentAction.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/dfas.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/TaskFactory.java" />
......@@ -171,27 +126,36 @@
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/ExecutionHandler.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/action/AgentStateActionTest.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/AgentTest.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java" />
<option value="$PROJECT_DIR$/octopus-server/pom.xml" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Task.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/AuthenticatedChaosClient.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Job.java" />
<option value="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/AgentNetworkingTest.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java" />
<option value="$PROJECT_DIR$/LICENSE.txt" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/RequestParser.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/HttpRequestParser.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/RequestParserTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/RequestParser.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Request.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/EndPoint.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Endpoint.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/KeyValue.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentConnectResponse.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java" />
<option value="$MAVEN_REPOSITORY$/com/google/code/gson/gson/2.2.4/gson-2.2.4.jar!/com/google/gson/reflect/TypeToken.class" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentConnectResult.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/ResponseTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/RequestParser.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java" />
<option value="$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java" />
<option value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentStateResult.java" />
<option value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java" />
<option value="$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java" />
<option value="$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java" />
</list>
</option>
</component>
......@@ -214,38 +178,7 @@
</option>
</component>
<component name="MavenProjectNavigator">
<treeState>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$RootNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$ProjectNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$RootNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$ProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="Lifecycle" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$LifecycleNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="" />
<option name="myItemType" value="org.jetbrains.idea.maven.navigator.MavenProjectsStructure$RootNode" />
</PATH_ELEMENT>
</PATH>
</treeState>
<treeState />
</component>
<component name="ProjectFrameBounds">
<option name="x" value="-8" />
......@@ -370,6 +303,8 @@
<foldersAlwaysOnTop value="true" />
</navigator>
<panes>
<pane id="Scope" />
<pane id="Scratches" />
<pane id="ProjectPane">
<subPane>
<PATH>
......@@ -388,256 +323,6 @@
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-server" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-server" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-server" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="main" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="server" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="test" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="test" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="test" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="core" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="test" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="core" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="test" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="main" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
......@@ -651,30 +336,6 @@
<option name="myItemId" value="octopus-commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="main" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="util" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
......@@ -693,26 +354,6 @@
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="main" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="http" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
......@@ -743,10 +384,6 @@
<option name="myItemId" value="chaos" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
......@@ -781,10 +418,6 @@
<option name="myItemId" value="commons" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="core" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
......@@ -823,78 +456,10 @@
<option name="myItemId" value="core" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="message" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-agent" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-agent" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="parent-project" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="octopus-agent" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="src" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="main" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="java" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="agent" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
</subPane>
</pane>
<pane id="Scope" />
<pane id="PackagesPane" />
<pane id="Scratches" />
</panes>
</component>
<component name="PropertiesComponent">
......@@ -903,7 +468,7 @@
<property name="settings.editor.selected.configurable" value="reference.settingsdialog.IDE.editor.colors.Font" />
<property name="settings.editor.splitter.proportion" value="0.2" />
<property name="recentsLimit" value="5" />
<property name="last_directory_selection" value="$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent" />
<property name="last_directory_selection" value="$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core" />
<property name="aspect.path.notification.shown" value="true" />
<property name="WebServerToolWindowFactoryState" value="false" />
<property name="project.structure.last.edited" value="Modules" />
......@@ -913,31 +478,32 @@
</component>
<component name="RecentsManager">
<key name="MoveClassesOrPackagesDialog.RECENTS_KEY">
<recent name="com.chaos.octopus.commons.core" />
<recent name="com.chaos.octopus.agent.action" />
<recent name="com.chaos.octopus.commons.core.messages" />
</key>
<key name="CreateClassDialog.RecentsKey">
<recent name="com.chaos.octopus.agent" />
<recent name="com.chaos.octopus.commons.http" />
<recent name="com.chaos.octopus.agent.action" />
<recent name="com.chaos.octopus.agent" />
<recent name="com.chaos.sdk" />
</key>
</component>
<component name="RunManager" selected="JUnit.DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers">
<configuration default="false" name="AgentStateActionTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<configuration default="false" name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
<pattern>
<option name="PATTERN" value="com.chaos.octopus.agent.unit.action.*" />
<option name="PATTERN" value="com.chaos.octopus.integrationtests.*" />
<option name="ENABLED" value="true" />
</pattern>
</extension>
<module name="octopus-agent" />
<module name="octopus-integrationtests" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.agent.unit.action" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.agent.unit.action.AgentStateActionTest" />
<option name="METHOD_NAME" />
<option name="TEST_OBJECT" value="class" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.integrationtests" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.integrationtests.DistributeToWorkersTest" />
<option name="METHOD_NAME" value="distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" />
<option name="TEST_OBJECT" value="method" />
<option name="VM_PARAMETERS" value="-ea" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
......@@ -950,7 +516,7 @@
<patterns />
<method />
</configuration>
<configuration default="false" name="AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<configuration default="false" name="AgentNetworkingTest.agentConnectFailed_OrchestratorNotStarted_ThrowException" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
<pattern>
<option name="PATTERN" value="com.chaos.octopus.integrationtests.*" />
......@@ -958,36 +524,36 @@
</pattern>
</extension>
<module name="octopus-integrationtests" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
<option name="ALTERNATIVE_JRE_PATH" value="1.8" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.integrationtests" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.integrationtests.AgentNetworkingTest" />
<option name="METHOD_NAME" value="agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<option name="METHOD_NAME" value="agentConnectFailed_OrchestratorNotStarted_ThrowException" />
<option name="TEST_OBJECT" value="method" />
<option name="VM_PARAMETERS" value="-ea" />
<option name="PARAMETERS" value="" />
<option name="WORKING_DIRECTORY" value="file://$MODULE_DIR$" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
<option name="ENV_VARIABLES" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="TEST_SEARCH_SCOPE">
<value defaultName="wholeProject" />
<value defaultName="singleModule" />
</option>
<envs />
<patterns />
<method />
</configuration>
<configuration default="false" name="SimpleServerTest.nothing" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<configuration default="false" name="ResponseTest.nothing" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
<pattern>
<option name="PATTERN" value="com.chaos.octopus.commons.core.http.test.*" />
<option name="PATTERN" value="com.chaos.octopus.commons.core.*" />
<option name="ENABLED" value="true" />
</pattern>
</extension>
<module name="octopus-commons" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.commons.core.http.test" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.commons.core.http.test.SimpleServerTest" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.commons.core" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.commons.core.ResponseTest" />
<option name="METHOD_NAME" value="nothing" />
<option name="TEST_OBJECT" value="method" />
<option name="VM_PARAMETERS" value="-ea" />
......@@ -1002,19 +568,19 @@
<patterns />
<method />
</configuration>
<configuration default="false" name="RequestParserTest.parse_GivenValidRequest_Return" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<configuration default="false" name="AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
<pattern>
<option name="PATTERN" value="com.chaos.octopus.commons.core.http.test.*" />
<option name="PATTERN" value="com.chaos.octopus.integrationtests.*" />
<option name="ENABLED" value="true" />
</pattern>
</extension>
<module name="octopus-commons" />
<module name="octopus-integrationtests" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.commons.core.http.test" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.commons.core.http.test.RequestParserTest" />
<option name="METHOD_NAME" value="parse_GivenValidRequest_Return" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.integrationtests" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.integrationtests.AgentNetworkingTest" />
<option name="METHOD_NAME" value="agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<option name="TEST_OBJECT" value="method" />
<option name="VM_PARAMETERS" value="-ea" />
<option name="PARAMETERS" />
......@@ -1028,20 +594,20 @@
<patterns />
<method />
</configuration>
<configuration default="false" name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<configuration default="false" name="AgentProxyTest" type="JUnit" factoryName="JUnit" temporary="true" nameIsGenerated="true">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea">
<pattern>
<option name="PATTERN" value="com.chaos.octopus.integrationtests.*" />
<option name="PATTERN" value="com.chaos.octopus.server.unit.*" />
<option name="ENABLED" value="true" />
</pattern>
</extension>
<module name="octopus-integrationtests" />
<module name="octopus-server" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.integrationtests" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.integrationtests.DistributeToWorkersTest" />
<option name="METHOD_NAME" value="distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" />
<option name="TEST_OBJECT" value="method" />
<option name="PACKAGE_NAME" value="com.chaos.octopus.server.unit" />
<option name="MAIN_CLASS_NAME" value="com.chaos.octopus.server.unit.AgentProxyTest" />
<option name="METHOD_NAME" />
<option name="TEST_OBJECT" value="class" />
<option name="VM_PARAMETERS" value="-ea" />
<option name="PARAMETERS" />
<option name="WORKING_DIRECTORY" value="$MODULE_DIR$" />
......@@ -1499,19 +1065,19 @@
</configuration>
<list size="6">
<item index="0" class="java.lang.String" itemvalue="JUnit.All Tests" />
<item index="1" class="java.lang.String" itemvalue="JUnit.AgentStateActionTest" />
<item index="2" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<item index="3" class="java.lang.String" itemvalue="JUnit.SimpleServerTest.nothing" />
<item index="4" class="java.lang.String" itemvalue="JUnit.RequestParserTest.parse_GivenValidRequest_Return" />
<item index="5" class="java.lang.String" itemvalue="JUnit.DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" />
<item index="1" class="java.lang.String" itemvalue="JUnit.DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" />
<item index="2" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentConnectFailed_OrchestratorNotStarted_ThrowException" />
<item index="3" class="java.lang.String" itemvalue="JUnit.ResponseTest.nothing" />
<item index="4" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<item index="5" class="java.lang.String" itemvalue="JUnit.AgentProxyTest" />
</list>
<recent_temporary>
<list size="5">
<item index="0" class="java.lang.String" itemvalue="JUnit.DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" />
<item index="1" class="java.lang.String" itemvalue="JUnit.SimpleServerTest.nothing" />
<item index="2" class="java.lang.String" itemvalue="JUnit.RequestParserTest.parse_GivenValidRequest_Return" />
<item index="3" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<item index="4" class="java.lang.String" itemvalue="JUnit.AgentStateActionTest" />
<item index="1" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" />
<item index="2" class="java.lang.String" itemvalue="JUnit.AgentProxyTest" />
<item index="3" class="java.lang.String" itemvalue="JUnit.ResponseTest.nothing" />
<item index="4" class="java.lang.String" itemvalue="JUnit.AgentNetworkingTest.agentConnectFailed_OrchestratorNotStarted_ThrowException" />
</list>
</recent_temporary>
</component>
......@@ -1535,44 +1101,45 @@
<workItem from="1466691045796" duration="601000" />
<workItem from="1466764339577" duration="7277000" />
<workItem from="1467023521811" duration="7535000" />
<workItem from="1467103515684" duration="15752000" />
<workItem from="1467103515684" duration="15797000" />
<workItem from="1467200687540" duration="14361000" />
</task>
<servers />
</component>
<component name="TestHistory">
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 41m 07s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="AgentNetworkingTest_agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList - 2016.06.29 at 17h 45m 10s.xml">
<configuration name="AgentNetworkingTest.agentDisconnect_NewJobIsQueued_AgentShouldBeRemovedFromAgentList" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 41m 13s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="AgentProxyTest - 2016.06.29 at 17h 35m 34s.xml">
<configuration name="AgentProxyTest" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 41m 20s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="AgentProxyTest - 2016.06.29 at 17h 36m 17s.xml">
<configuration name="AgentProxyTest" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 42m 07s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="AgentProxyTest - 2016.06.29 at 17h 38m 33s.xml">
<configuration name="AgentProxyTest" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 42m 52s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="AgentProxyTest - 2016.06.29 at 17h 42m 55s.xml">
<configuration name="AgentProxyTest" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 53m 37s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
<history-entry file="All_Tests - 2016.06.29 at 17h 43m 08s.xml">
<configuration name="All Tests" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 16h 57m 16s.xml">
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.29 at 17h 45m 34s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 17h 05m 59s.xml">
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.29 at 17h 45m 40s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 17h 06m 27s.xml">
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.29 at 17h 45m 43s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
</history-entry>
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.28 at 17h 06m 44s.xml">
<history-entry file="DistributeToWorkersTest_distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers - 2016.06.29 at 17h 45m 46s.xml">
<configuration name="DistributeToWorkersTest.distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers" configurationId="JUnit" />
</history-entry>
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="39872000" />
<option name="totallyTimeSpent" value="54278000" />
</component>
<component name="ToolWindowManager">
<frame x="-8" y="-8" width="1936" height="1056" extended-state="6" />
......@@ -1580,13 +1147,13 @@
<layout>
<window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32875264" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32769555" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Palette&#9;" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Capture Analysis" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="8" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="11" side_tool="true" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.096875" sideWeight="0.4973404" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.096875" sideWeight="0.4973404" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.25158563" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.24312897" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="10" side_tool="false" content_ui="tabs" />
<window_info id="Capture Tool" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Designer" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
......@@ -1595,8 +1162,8 @@
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.23150106" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.50259453" order="3" side_tool="true" content_ui="tabs" />
<window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.50259453" order="4" side_tool="true" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.39970207" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
<window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
......@@ -1620,7 +1187,7 @@
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
<option name="time" value="6" />
<option name="time" value="10" />
</breakpoint-manager>
<watches-manager />
</component>
......@@ -1629,407 +1196,435 @@
<option name="FILTER_TARGETS" value="false" />
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/sdk/test/ChaosTest.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/ExecutionHandler.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="16" column="28" selection-start-line="16" selection-start-column="28" selection-end-line="16" selection-end-column="28" />
<caret line="32" column="38" selection-start-line="32" selection-start-column="38" selection-end-line="32" selection-end-column="38" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/PluginFactoryTest.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/OrchestratorImplTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="17" column="0" selection-start-line="17" selection-start-column="0" selection-end-line="17" selection-end-column="0" />
<caret line="27" column="3" selection-start-line="27" selection-start-column="3" selection-end-line="27" selection-end-column="3" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/AgentAction.java">
<entry file="file://$PROJECT_DIR$/pom.xml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="2" column="0" selection-start-line="2" selection-start-column="0" selection-end-line="2" selection-end-column="0" />
<caret line="3" column="0" selection-start-line="3" selection-start-column="0" selection-end-line="3" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/ListSupportedPluginsAction.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AllocationHandlerTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="11" column="61" selection-start-line="11" selection-start-column="61" selection-end-line="11" selection-end-column="61" />
<caret line="17" column="24" selection-start-line="17" selection-start-column="24" selection-end-line="17" selection-end-column="24" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/TaskUpdatedListener.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/v6/dto/ClusterState.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="4" column="17" selection-start-line="4" selection-start-column="17" selection-end-line="4" selection-end-column="17" />
<caret line="7" column="0" selection-start-line="7" selection-start-column="0" selection-end-line="7" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/TaskCompleteListener.java">
<entry file="file://$PROJECT_DIR$/octopus-server/pom.xml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="6" column="24" selection-start-line="6" selection-start-column="24" selection-end-line="6" selection-end-column="24" />
<caret line="41" column="21" selection-start-line="41" selection-start-column="21" selection-end-line="41" selection-end-column="21" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/TaskStatusChangeListener.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/ExecutionSlot.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
<caret line="14" column="12" selection-start-line="14" selection-start-column="12" selection-end-line="14" selection-end-column="12" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/PluginFactory.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/plugin/ChaosPlugin.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="4" column="30" selection-start-line="4" selection-start-column="30" selection-end-line="4" selection-end-column="30" />
<caret line="18" column="13" selection-start-line="18" selection-start-column="13" selection-end-line="18" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/action/AgentStateActionTest.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/pom.xml">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="52" column="0" selection-start-line="52" selection-start-column="0" selection-end-line="52" selection-end-column="0" />
<caret line="39" column="21" selection-start-line="39" selection-start-column="21" selection-end-line="39" selection-end-column="21" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/EnqueueTaskAction.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/ConcurrentJobQueue.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="19" column="17" selection-start-line="19" selection-start-column="17" selection-end-line="19" selection-end-column="17" />
<caret line="11" column="13" selection-start-line="11" selection-start-column="13" selection-end-line="11" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/AgentStateAction.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/AuthenticatedChaosClient.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="21" column="3" selection-start-line="21" selection-start-column="3" selection-end-line="21" selection-end-column="3" />
<caret line="54" column="0" selection-start-line="54" selection-start-column="0" selection-end-line="54" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/ExecutionHandler.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Job.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="32" column="38" selection-start-line="32" selection-start-column="38" selection-end-line="32" selection-end-column="38" />
<caret line="10" column="46" selection-start-line="10" selection-start-column="46" selection-end-line="10" selection-end-column="46" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/OrchestratorImplTest.java">
<entry file="file://$PROJECT_DIR$/LICENSE.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="27" column="3" selection-start-line="27" selection-start-column="3" selection-end-line="27" selection-end-column="3" />
<state relative-caret-position="374">
<caret line="188" column="17" selection-start-line="188" selection-start-column="17" selection-end-line="188" selection-end-column="17" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/pom.xml">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/Check.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="3" column="0" selection-start-line="3" selection-start-column="0" selection-end-line="3" selection-end-column="0" />
<folding />
<state relative-caret-position="85">
<caret line="5" column="10" selection-start-line="5" selection-start-column="10" selection-end-line="5" selection-end-column="10" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AllocationHandlerTest.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/TestPlugin.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="17" column="24" selection-start-line="17" selection-start-column="24" selection-end-line="17" selection-end-column="24" />
<state relative-caret-position="-245">
<caret line="17" column="9" selection-start-line="17" selection-start-column="9" selection-end-line="17" selection-end-column="9" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/v6/dto/ClusterState.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/EnqueueJobs.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="7" column="0" selection-start-line="7" selection-start-column="0" selection-end-line="7" selection-end-column="0" />
<state relative-caret-position="119">
<caret line="14" column="27" selection-start-line="14" selection-start-column="27" selection-end-line="14" selection-end-column="27" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/pom.xml">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Task.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="41" column="21" selection-start-line="41" selection-start-column="21" selection-end-line="41" selection-end-column="21" />
<folding />
<state relative-caret-position="408">
<caret line="31" column="34" selection-start-line="31" selection-start-column="34" selection-end-line="31" selection-end-column="34" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/RequestParserTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="5" column="27" selection-start-line="5" selection-start-column="27" selection-end-line="5" selection-end-column="27" />
<state relative-caret-position="187">
<caret line="11" column="42" selection-start-line="11" selection-start-column="42" selection-end-line="11" selection-end-column="42" />
<folding>
<element signature="imports" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/ExecutionSlot.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Request.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="14" column="12" selection-start-line="14" selection-start-column="12" selection-end-line="14" selection-end-column="12" />
<state relative-caret-position="204">
<caret line="15" column="0" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/plugin/ChaosPlugin.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/StreamUtilities.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="18" column="13" selection-start-line="18" selection-start-column="13" selection-end-line="18" selection-end-column="13" />
<state relative-caret-position="224">
<caret line="22" column="22" selection-start-line="22" selection-start-column="22" selection-end-line="22" selection-end-column="22" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/pom.xml">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/NetworkGateway.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="39" column="21" selection-start-line="39" selection-start-column="21" selection-end-line="39" selection-end-column="21" />
<folding />
<state relative-caret-position="80">
<caret line="16" column="13" selection-start-line="16" selection-start-column="13" selection-end-line="16" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/ConcurrentJobQueue.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/TaskMessage.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="11" column="13" selection-start-line="11" selection-start-column="13" selection-end-line="11" selection-end-column="13" />
<state relative-caret-position="224">
<caret line="18" column="3" selection-start-line="18" selection-start-column="3" selection-end-line="18" selection-end-column="3" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/Message.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="12" column="14" selection-start-line="12" selection-start-column="14" selection-end-line="12" selection-end-column="14" />
<state relative-caret-position="400">
<caret line="35" column="8" selection-start-line="35" selection-start-column="4" selection-end-line="35" selection-end-column="8" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/AuthenticatedChaosClient.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/AgentTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="54" column="0" selection-start-line="54" selection-start-column="0" selection-end-line="54" selection-end-column="0" />
<state relative-caret-position="224">
<caret line="34" column="17" selection-start-line="34" selection-start-column="17" selection-end-line="34" selection-end-column="17" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Job.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Endpoint.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="10" column="46" selection-start-line="10" selection-start-column="46" selection-end-line="10" selection-end-column="46" />
<state relative-caret-position="96">
<caret line="6" column="33" selection-start-line="6" selection-start-column="33" selection-end-line="6" selection-end-column="33" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/LICENSE.txt">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="374">
<caret line="188" column="17" selection-start-line="188" selection-start-column="17" selection-end-line="188" selection-end-column="17" />
<state relative-caret-position="224">
<caret line="14" column="27" selection-start-line="14" selection-start-column="27" selection-end-line="14" selection-end-column="27" />
<folding>
<element signature="imports" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/Check.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/NetworkingUtil.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="85">
<caret line="5" column="10" selection-start-line="5" selection-start-column="10" selection-end-line="5" selection-end-column="10" />
<state relative-caret-position="416">
<caret line="68" column="0" selection-start-line="68" selection-start-column="0" selection-end-line="68" selection-end-column="0" />
<folding>
<element signature="e#701#702#0" expanded="true" />
<element signature="e#735#736#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/TestUtils.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119">
<state relative-caret-position="112">
<caret line="7" column="23" selection-start-line="7" selection-start-column="23" selection-end-line="7" selection-end-column="23" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/TestPlugin.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/KeyValue.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-245">
<caret line="17" column="9" selection-start-line="17" selection-start-column="9" selection-end-line="17" selection-end-column="9" />
<state relative-caret-position="128">
<caret line="8" column="23" selection-start-line="8" selection-start-column="23" selection-end-line="8" selection-end-column="23" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/AgentNetworkingTest.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/EnqueueTaskAction.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="476">
<caret line="42" column="22" selection-start-line="42" selection-start-column="22" selection-end-line="42" selection-end-column="22" />
<state relative-caret-position="208">
<caret line="20" column="4" selection-start-line="20" selection-start-column="4" selection-end-line="24" selection-end-column="70" />
<folding>
<element signature="e#488#489#0" expanded="false" />
<element signature="e#516#517#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="170">
<caret line="36" column="0" selection-start-line="36" selection-start-column="0" selection-end-line="36" selection-end-column="0" />
<state relative-caret-position="36">
<caret line="52" column="24" selection-start-line="52" selection-start-column="24" selection-end-line="52" selection-end-column="47" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/EnqueueJobs.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/ListSupportedPluginsAction.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="119">
<caret line="14" column="27" selection-start-line="14" selection-start-column="27" selection-end-line="14" selection-end-column="27" />
<state relative-caret-position="208">
<caret line="20" column="2" selection-start-line="20" selection-start-column="2" selection-end-line="44" selection-end-column="3" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Task.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/AgentStateMessage.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="408">
<caret line="31" column="34" selection-start-line="31" selection-start-column="34" selection-end-line="31" selection-end-column="34" />
<state relative-caret-position="112">
<caret line="9" column="9" selection-start-line="9" selection-start-column="9" selection-end-line="9" selection-end-column="9" />
<folding>
<element signature="e#314#315#0" expanded="true" />
<element signature="e#355#356#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/synchronization/Heartbeat.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="17">
<caret line="32" column="0" selection-start-line="32" selection-start-column="0" selection-end-line="32" selection-end-column="0" />
<state relative-caret-position="351">
<caret line="22" column="33" selection-start-line="22" selection-start-column="33" selection-end-line="22" selection-end-column="33" />
<folding>
<element signature="n#!!doc" expanded="false" />
<element signature="e#1352#1353#0" expanded="false" />
<element signature="e#1386#1387#0" expanded="false" />
<element signature="e#2055#2056#0" expanded="false" />
<element signature="e#2101#2102#0" expanded="false" />
<element signature="e#2784#2785#0" expanded="false" />
<element signature="e#2829#2830#0" expanded="false" />
<element signature="e#3023#3024#0" expanded="false" />
<element signature="e#3048#3049#0" expanded="false" />
<element signature="imports" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentConfigurationMessage.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="10" column="23" selection-start-line="10" selection-start-column="23" selection-end-line="10" selection-end-column="23" />
<folding>
<element signature="imports" expanded="true" />
</folding>
<state relative-caret-position="112">
<caret line="13" column="44" selection-start-line="13" selection-start-column="28" selection-end-line="13" selection-end-column="44" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/RequestParserTest.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/action/AgentStateAction.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="187">
<caret line="11" column="42" selection-start-line="11" selection-start-column="42" selection-end-line="11" selection-end-column="42" />
<state relative-caret-position="320">
<caret line="26" column="31" selection-start-line="26" selection-start-column="31" selection-end-line="26" selection-end-column="31" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#478#479#0" expanded="false" />
<element signature="e#528#529#0" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/RequestParser.java">
<entry file="jar://$MAVEN_REPOSITORY$/com/google/code/gson/gson/2.2.4/gson-2.2.4.jar!/com/google/gson/reflect/TypeToken.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="106">
<caret line="12" column="3" selection-start-line="12" selection-start-column="3" selection-end-line="12" selection-end-column="3" />
<folding>
<element signature="imports" expanded="true" />
</folding>
<state relative-caret-position="-192">
<caret line="21" column="12" selection-start-line="21" selection-start-column="12" selection-end-line="21" selection-end-column="12" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Request.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentConnectResult.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="204">
<caret line="15" column="0" selection-start-line="15" selection-start-column="0" selection-end-line="15" selection-end-column="0" />
<state relative-caret-position="112">
<caret line="7" column="45" selection-start-line="7" selection-start-column="45" selection-end-line="7" selection-end-column="45" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/StreamUtilities.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/ResponseTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="22" column="22" selection-start-line="22" selection-start-column="22" selection-end-line="22" selection-end-column="22" />
<folding />
<state relative-caret-position="336">
<caret line="21" column="29" selection-start-line="21" selection-start-column="29" selection-end-line="21" selection-end-column="29" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#271#281#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/RequestParser.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="436">
<caret line="50" column="55" selection-start-line="50" selection-start-column="55" selection-end-line="50" selection-end-column="55" />
<state relative-caret-position="320">
<caret line="34" column="0" selection-start-line="34" selection-start-column="0" selection-end-line="34" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/sdk/NetworkGateway.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="16" column="13" selection-start-line="16" selection-start-column="13" selection-end-line="16" selection-end-column="13" />
<folding />
<state relative-caret-position="805">
<caret line="63" column="43" selection-start-line="63" selection-start-column="43" selection-end-line="63" selection-end-column="43" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/TaskMessage.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Response.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="18" column="3" selection-start-line="18" selection-start-column="3" selection-end-line="18" selection-end-column="3" />
<folding />
<state relative-caret-position="176">
<caret line="11" column="0" selection-start-line="11" selection-start-column="0" selection-end-line="11" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/message/Message.java">
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/AgentStateResult.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="400">
<caret line="35" column="8" selection-start-line="35" selection-start-column="4" selection-end-line="35" selection-end-column="8" />
<folding />
<state relative-caret-position="128">
<caret line="8" column="0" selection-start-line="8" selection-start-column="0" selection-end-line="8" selection-end-column="0" />
<folding>
<element signature="e#262#263#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/test/java/com/chaos/octopus/agent/unit/AgentTest.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/AgentProxyTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="34" column="17" selection-start-line="34" selection-start-column="17" selection-end-line="34" selection-end-column="17" />
<state relative-caret-position="64">
<caret line="12" column="29" selection-start-line="12" selection-start-column="29" selection-end-line="12" selection-end-column="29" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/test/java/com/chaos/octopus/commons/core/http/test/SimpleServerTest.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AgentProxy.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="14" column="6" selection-start-line="14" selection-start-column="6" selection-end-line="14" selection-end-column="6" />
<state relative-caret-position="320">
<caret line="151" column="0" selection-start-line="151" selection-start-column="0" selection-end-line="151" selection-end-column="0" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#2317#2318#0" expanded="true" />
<element signature="e#2362#2363#0" expanded="true" />
<element signature="e#2396#2397#0" expanded="true" />
<element signature="e#2474#2475#0" expanded="true" />
<element signature="e#3178#3179#0" expanded="true" />
<element signature="e#3203#3204#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/util/NetworkingUtil.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/AllocationHandler.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="256">
<caret line="28" column="6" selection-start-line="28" selection-start-column="6" selection-end-line="28" selection-end-column="6" />
<folding>
<element signature="e#701#702#0" expanded="true" />
<element signature="e#735#736#0" expanded="true" />
</folding>
<state relative-caret-position="219">
<caret line="82" column="0" selection-start-line="82" selection-start-column="0" selection-end-line="82" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java">
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/Agent.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="432">
<caret line="38" column="36" selection-start-line="38" selection-start-column="36" selection-end-line="38" selection-end-column="36" />
<folding />
<state relative-caret-position="219">
<caret line="56" column="16" selection-start-line="56" selection-start-column="6" selection-end-line="56" selection-end-column="16" />
<folding>
<element signature="imports" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/http/SimpleServer.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="584">
<caret line="113" column="0" selection-start-line="113" selection-start-column="0" selection-end-line="113" selection-end-column="0" />
<state relative-caret-position="435">
<caret line="169" column="15" selection-start-line="169" selection-start-column="8" selection-end-line="169" selection-end-column="15" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#1326#1327#0" expanded="true" />
<element signature="e#1367#1368#0" expanded="true" />
<element signature="e#1492#1493#0" expanded="true" />
<element signature="e#1526#1527#0" expanded="true" />
<element signature="e#2806#2807#0" expanded="true" />
<element signature="e#2853#2854#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-commons/src/main/java/com/chaos/octopus/commons/core/Endpoint.java">
<entry file="file://$PROJECT_DIR$/octopus-server/src/test/java/com/chaos/octopus/server/unit/Synchronization/HeartbeatTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="96">
<caret line="6" column="33" selection-start-line="6" selection-start-column="33" selection-end-line="6" selection-end-column="33" />
<caret line="15" column="14" selection-start-line="15" selection-start-column="14" selection-end-line="15" selection-end-column="14" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-agent/src/main/java/com/chaos/octopus/agent/OrchestratorProxy.java">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/AgentNetworkingTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="336">
<caret line="55" column="26" selection-start-line="55" selection-start-column="26" selection-end-line="55" selection-end-column="26" />
<state relative-caret-position="208">
<caret line="39" column="20" selection-start-line="39" selection-start-column="20" selection-end-line="39" selection-end-column="20" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/octopus-server/src/main/java/com/chaos/octopus/server/OrchestratorImpl.java">
<entry file="file://$PROJECT_DIR$/octopus-integrationtests/src/test/java/com/chaos/octopus/integrationtests/DistributeToWorkersTest.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="378">
<caret line="195" column="0" selection-start-line="195" selection-start-column="0" selection-end-line="195" selection-end-column="0" />
<state relative-caret-position="85">
<caret line="12" column="24" selection-start-line="12" selection-start-column="24" selection-end-line="12" selection-end-column="24" />
<folding />
</state>
</provider>
......
......@@ -6,28 +6,25 @@ package com.chaos.octopus.agent;
import com.chaos.octopus.agent.action.AgentAction;
import com.chaos.octopus.agent.action.AgentStateAction;
import com.chaos.octopus.agent.action.EnqueueTaskAction;
import com.chaos.octopus.agent.action.ListSupportedPluginsAction;
import com.chaos.octopus.commons.core.*;
import com.chaos.octopus.commons.core.message.Message;
import com.chaos.octopus.commons.exception.DisconnectError;
import com.chaos.octopus.commons.http.SimpleServer;
import com.chaos.octopus.commons.util.Commands;
import com.chaos.octopus.commons.util.NetworkingUtil;
import com.chaos.octopus.commons.util.StreamUtilities;
import com.chaos.sdk.v6.dto.ClusterState;
import com.google.gson.Gson;
import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;
import java.util.HashMap;
import java.util.Map;
public class Agent implements Runnable, AutoCloseable, TaskStatusChangeListener {
private boolean _isRunning;
private Thread _thread;
import java.util.ArrayList;
import java.util.List;
public class Agent implements AutoCloseable, TaskStatusChangeListener {
private ExecutionHandler _executionHandler;
private Orchestrator _orchestrator;
private ServerSocket _Server;
private Map<String, AgentAction> _agentActions = new HashMap<>();
private PluginFactory _pluginFactory;
private SimpleServer _simpleServer;
public Agent(String orchestratorHostname, int orchestratorPort, int listenPort) {
this(new OrchestratorProxy(orchestratorHostname, orchestratorPort, listenPort), 4);
......@@ -39,16 +36,14 @@ public class Agent implements Runnable, AutoCloseable, TaskStatusChangeListener
public Agent(Orchestrator orchestrator, int parallelism) {
_orchestrator = orchestrator;
_isRunning = false;
_thread = new Thread(this);
_thread.setName("Agent");
_executionHandler = new ExecutionHandler(this, parallelism);
_pluginFactory = new PluginFactory();
_agentActions.put(Commands.LIST_SUPPORTED_PLUGINS, new ListSupportedPluginsAction(_pluginFactory, parallelism));
_agentActions.put(Commands.ENQUEUE_TASK, new EnqueueTaskAction(this));
_agentActions.put(Commands.AGENT_STATE, new AgentStateAction(_executionHandler));
_simpleServer = new SimpleServer(_orchestrator.get_localListenPort());
_simpleServer.addEndpoint("Task/Enqueue", new TaskEnqueueEndpoint());
_simpleServer.addEndpoint("State/Get", new StateGetEndpoint());
_simpleServer.addEndpoint("Plugin/Get", new PluginGetEndpoint());
}
public static Agent create(OctopusConfiguration config) {
......@@ -58,10 +53,6 @@ public class Agent implements Runnable, AutoCloseable, TaskStatusChangeListener
public void open() throws IOException {
try {
_orchestrator.open();
_Server = new ServerSocket(_orchestrator.get_localListenPort());
_isRunning = true;
_thread.start();
} catch (DisconnectError e) {
System.out.println(Thread.currentThread().getId() + " AGENT DISCONNECTED");
try {
......@@ -73,27 +64,8 @@ public class Agent implements Runnable, AutoCloseable, TaskStatusChangeListener
}
public void run() {
while (_isRunning) {
try {
// todo refactor so the implementation doesn't depend on the socket
try (Socket socket = _Server.accept()) {
String message = StreamUtilities.ReadString(socket.getInputStream());
Message msg = StreamUtilities.ReadJson(message, Message.class);
_agentActions.get(msg.getAction()).invoke(message, socket.getOutputStream());
}
} catch (Exception e) {
if (!_Server.isClosed()) e.printStackTrace();
}
}
}
public void close() throws Exception {
_isRunning = false;
if (_Server != null) _Server.close();
_simpleServer.stop();
if (_executionHandler != null) _executionHandler.close();
}
......@@ -119,4 +91,70 @@ public class Agent implements Runnable, AutoCloseable, TaskStatusChangeListener
public int getQueueSize() {
return _executionHandler.getQueueSize();
}
private class TaskEnqueueEndpoint implements Endpoint {
public Response invoke(Request request) {
String taskJson = request.queryString.get("task");
Task task = StreamUtilities.ReadJson(taskJson, Task.class);
enqueue(task);
// todo add proper OK response
return new Response();
}
}
private class StateGetEndpoint implements Endpoint {
public Response invoke(Request request) {
ClusterState.AgentState state = new ClusterState.AgentState();
state.runningSize = _executionHandler.getQueueSize() > _executionHandler.getParallelism()
? _executionHandler.getParallelism()
: _executionHandler.getQueueSize();
state.queueSize = _executionHandler.getQueueSize();
state.parallelism = _executionHandler.getParallelism();
Response<AgentStateResult> response = new Response<>();
response.Results.add(new AgentStateResult(state));
return response;
}
}
private class PluginGetEndpoint implements Endpoint {
public Response invoke(Request request) {
AgentConfigurationMessage response = createAgentConfigurationMessage();
Response res = new Response();
AgentConnectResult result = new AgentConnectResult();
res.Results.add(result);
for (String s:response.getSupportedPlugins())
result.supportedPlugins.add(s);
result.masNumberOfSimultaneousTasks = _executionHandler.getParallelism();
return res;
}
private AgentConfigurationMessage createAgentConfigurationMessage() {
AgentConfigurationMessage message = new AgentConfigurationMessage();
message.setNumberOfSimulataniousTasks(_executionHandler.getParallelism());
for (PluginDefinition definition : get_SupportedPlugins())
message.getSupportedPlugins().add(definition.getId());
return message;
}
public List<PluginDefinition> get_SupportedPlugins() {
List<PluginDefinition> list = new ArrayList<>();
for (PluginDefinition definition : _pluginFactory.get_SupportedPlugins())
list.add(definition);
return list;
}
}
}
......@@ -5,28 +5,24 @@
package com.chaos.octopus.agent;
import com.chaos.octopus.commons.core.*;
import com.chaos.octopus.commons.core.message.ConnectMessage;
import com.chaos.octopus.commons.core.message.TaskMessage;
import com.chaos.octopus.commons.util.Commands;
import com.chaos.octopus.commons.util.NetworkingUtil;
import com.chaos.octopus.commons.util.StreamUtilities;
import com.google.gson.Gson;
import java.io.IOException;
import java.net.ConnectException;
import java.net.Inet4Address;
import java.net.Socket;
import java.net.UnknownHostException;
public class OrchestratorProxy implements Orchestrator {
private final int port;
private final String hostname;
private int _localListenPort;
private String _localHostAddress;
private NetworkingUtil _network;
public OrchestratorProxy(String hostname, int port, int listenPort) {
_localHostAddress = getHostAddress();
_localListenPort = listenPort;
_network = new NetworkingUtil(hostname, port);
this.port = port;
this.hostname = hostname;
}
private String getHostAddress() {
......@@ -42,32 +38,57 @@ public class OrchestratorProxy implements Orchestrator {
}
public void open() throws ConnectException {
ConnectMessage msg = new ConnectMessage(_localHostAddress, _localListenPort);
_network.send(msg.toJson());
sendResponse("Agent/Connect",
new KeyValue("hostname", _localHostAddress),
new KeyValue("port", _localListenPort + ""));
}
public void taskCompleted(Task task) {
try(Socket socket = new Socket("localhost", 8080)) {
String taskString = new Gson().toJson(task);
socket.getOutputStream().write(String.format("GET /Task/Complete/?task=%1s HTTP/1.1", taskString).getBytes());
} catch (IOException e) {
e.printStackTrace();
}
sendResponse("Task/Complete", new KeyValue("task", taskString));
}
@Override
public void taskUpdate(Task task) {
try(Socket socket = new Socket("localhost", 8080)) {
String taskString = new Gson().toJson(task);
socket.getOutputStream().write(String.format("GET /Task/Update/?task=%1s HTTP/1.1", taskString).getBytes());
} catch (IOException e) {
sendResponse("Task/Update", new KeyValue("task", taskString));
}
private void sendResponse(String endpoint, KeyValue... parameters) {
String queryString = "";
for (KeyValue entry: parameters)
queryString += String.format("%1s=%2s&", entry.key, entry.value);
sendResponse(String.format("GET /%1s/?%2s HTTP/1.1", endpoint, queryString), 10);
}
private void sendResponse(String message, int retries) {
try(Socket socket = new Socket(hostname, port)) {
socket.getOutputStream().write(message.getBytes());
} catch (ConnectException e) {
throw new com.chaos.octopus.commons.exception.ConnectException("Connection to Orchestrator could not be established, check hostname and port", e);
} catch (Exception e) {
if (retries > 0) {
sleep(250);
sendResponse(message, --retries);
}
// TODO This exception should be handled at a higher level
System.err.println("Couldn't connect to: " + "" + ":" + "");
e.printStackTrace();
}
}
private void sleep(int millis) {
try {
Thread.sleep(millis);
} catch (InterruptedException e1) {
}
}
@Override
public int get_localListenPort() {
return _localListenPort;
......
package com.chaos.octopus.commons.core;
import java.util.*;
public class AgentConnectResult {
public List<String> supportedPlugins = new ArrayList<>();
public int masNumberOfSimultaneousTasks = 0;
}
package com.chaos.octopus.commons.core;
import com.chaos.sdk.v6.dto.ClusterState;
public class AgentStateResult {
public ClusterState.AgentState agentState;
public AgentStateResult(ClusterState.AgentState agentState) {
this.agentState = agentState;
}
}
package com.chaos.octopus.commons.core;
public class KeyValue {
public String key;
public String value;
public KeyValue(String key, String value) {
this.key = key;
this.value = value;
}
}
package com.chaos.octopus.commons.core;
import com.chaos.sdk.v6.dto.ClusterState;
import com.google.gson.Gson;
import java.util.ArrayList;
import java.util.List;
/**
* Created by Jesper on 27-06-2016.
*/
public class Response {
public class Response<T> {
private static Gson _json = new Gson();
public List<Result> Results = new ArrayList<>();
public List<T> Results = new ArrayList<>();
public String toJson(){
return _json.toJson(this, Response.class);
......
......@@ -18,9 +18,9 @@ public class SimpleServer implements Runnable{
private ExecutorService _pool = Executors.newFixedThreadPool(8);
private Map<String, Endpoint> _endpoints = new HashMap<>();
public SimpleServer(){
public SimpleServer(int listeningPort){
try {
_serverSocket = new ServerSocket(8080);
_serverSocket = new ServerSocket(listeningPort);
_thread = new Thread(this);
_thread.setName("CHAOS Webserver");
_thread.start();
......@@ -66,6 +66,9 @@ public class SimpleServer implements Runnable{
SendResponse(res);
socket.close();
} catch (SocketException se) {
// if the socket is closed it means the server is turned off, so we can ignore the exception
if (!socket.isClosed()) se.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
......
package com.chaos.octopus.commons.core;
import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;
import org.junit.Test;
import java.lang.reflect.Type;
public class ResponseTest {
@Test
public void nothing(){
Response<MyResult> res1 = new Response<MyResult>();
res1.Results.add(new MyResult());
String json = new Gson().toJson(res1);
System.out.println(json);
Type type = new TypeToken<Response<MyResult>>() {
}.getType();
System.out.println(type);
Response<MyResult> res11 = new Gson().fromJson(json, type);
for (MyResult result : res11.Results) {
System.out.println(result.value);
}
}
private class MyResult {
public String value = "MyResult";
}
private class MyOtherResult {
public String value = "MyOtherResult";
}
}
......@@ -9,7 +9,7 @@ import org.junit.Test;
public class SimpleServerTest {
@Test
public void nothing() throws InterruptedException {
SimpleServer ss = new SimpleServer();
SimpleServer ss = new SimpleServer(8080);
ss.addEndpoint("test", new TestEndpoint());
//Thread.sleep(100000);
......
......@@ -9,6 +9,8 @@ import static org.junit.Assert.*;
public class DistributeToWorkersTest extends TestBase
{
// todo occasional bug
@Test
public void distributeTasksAmongstWorkers_GivenAJobWithMoreTasksThanOneWorkerCanHandle_ExecuteOnOtherWorkers() throws Exception
{
......@@ -35,8 +37,8 @@ public class DistributeToWorkersTest extends TestBase
public Boolean isTrue() { return agent1.getQueueSize() == 1 && agent2.getQueueSize() == 1;}
});
assertEquals("One task should be queued", 1, agent1.getQueueSize());
assertEquals("One task should be queued", 1, agent2.getQueueSize());
assertEquals("One key should be queued", 1, agent1.getQueueSize());
assertEquals("One key should be queued", 1, agent2.getQueueSize());
}
}
......
......@@ -37,7 +37,7 @@ public class LargeTasksTest {
public Boolean isTrue() {return agent1.getQueueSize() == 1;}
});
assertEquals("One task should be queued", 1, agent1.getQueueSize());
assertEquals("One key should be queued", 1, agent1.getQueueSize());
}
}
......
......@@ -4,10 +4,9 @@
*/
package com.chaos.octopus.server;
import com.chaos.octopus.commons.core.AgentConfigurationMessage;
import com.chaos.octopus.commons.core.*;
import com.chaos.octopus.commons.core.message.AgentStateMessage;
import com.chaos.octopus.commons.core.message.Message;
import com.chaos.octopus.commons.core.Task;
import com.chaos.octopus.commons.core.message.TaskMessage;
import com.chaos.octopus.commons.exception.ConnectException;
import com.chaos.octopus.commons.exception.DisconnectError;
......@@ -15,24 +14,28 @@ import com.chaos.octopus.commons.util.Commands;
import com.chaos.octopus.commons.util.NetworkingUtil;
import com.chaos.octopus.commons.util.StreamUtilities;
import com.chaos.sdk.v6.dto.ClusterState;
import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;
import java.io.IOException;
import java.lang.reflect.Type;
import java.net.Socket;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class AgentProxy {
private final String _hostname;
public final int port;
private final String hostname;
private List<String> _SupportedPlugins;
private int _MaxNumberOfSimultaneousTasks;
private Map<String, Task> _AllocatedTasks;
private NetworkingUtil _network;
public AgentProxy(String hostname, int port) {
_hostname = hostname;
_AllocatedTasks = new HashMap<>();
_network = new NetworkingUtil(hostname, port);
this.port = port;
this.hostname = hostname;
}
public List<String> get_SupportedPlugins() {
......@@ -40,43 +43,30 @@ public class AgentProxy {
}
public void InitializeAgent() {
String msg = Message.createWithAction(Commands.LIST_SUPPORTED_PLUGINS).toJson();
String responseString = _network.sendWithReply(msg);
AgentConfigurationMessage response = AgentConfigurationMessage.create(responseString);
Response<AgentConnectResult> response = sendRequest("Plugin/Get", new TypeToken<Response<AgentConnectResult>>(){}.getType());
InitializeAgent(response);
}
private void InitializeAgent(AgentConfigurationMessage response) {
private void InitializeAgent(Response<AgentConnectResult> response) {
_SupportedPlugins = new ArrayList<>();
for (String pluginId : response.getSupportedPlugins())
for (String pluginId : response.Results.get(0).supportedPlugins)
_SupportedPlugins.add(pluginId);
_MaxNumberOfSimultaneousTasks = response.getNumberOfSimulataniousTasks();
_MaxNumberOfSimultaneousTasks = response.Results.get(0).masNumberOfSimultaneousTasks;
}
public void set_SupportedPlugins(List<String> supportedPlugins) {
_SupportedPlugins = supportedPlugins;
}
private Object _EnqueueBlock = new Object();
public void enqueue(Task task) throws DisconnectError {
synchronized (_EnqueueBlock) {
try {
String msg = new TaskMessage(Commands.ENQUEUE_TASK, task).toJson();
String response = _network.sendWithReply(msg);
Message parsedResponse = StreamUtilities.ReadJson(response, Message.class);
if (!parsedResponse.getAction().equals("OK")) throw new IOException("Agent didnt queue task");
_AllocatedTasks.put(task.taskId, task);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
String taskString = new Gson().toJson(task);
sendRequest("Task/Enqueue", new KeyValue("task", taskString));
}
public void taskCompleted(Task task) {
......@@ -84,21 +74,20 @@ public class AgentProxy {
}
public boolean isQueueFull() {
synchronized (_EnqueueBlock) {
return _MaxNumberOfSimultaneousTasks - _AllocatedTasks.size() == 0;
}
}
public NetworkingUtil get_network() {
return _network;
}
public ClusterState.AgentState getState() {
ClusterState.AgentState state = new ClusterState.AgentState();
try{
String response = _network.sendWithReply(new AgentStateMessage().toJson());
state = AgentStateMessage.createFromJson(response).getState();
String stateString = new Gson().toJson(state);
Response<AgentStateResult> result = sendRequest("State/Get",
new TypeToken<Response<AgentStateResult>>(){}.getType(),
new KeyValue("state", stateString));
state = result.Results.get(0).agentState;
state.state = "Connected";
}catch (DisconnectError e){
state.state = "Disconnected";
......@@ -112,6 +101,68 @@ public class AgentProxy {
}
public String getHostname() {
return _hostname;
return hostname;
}
private <T> Response<T> sendRequest(String endpoint, KeyValue... parameters) {
String queryString = "";
for (KeyValue entry: parameters)
queryString += String.format("%1s=%2s&", entry.key, entry.value);
return sendRequest(String.format("GET /%1s/?%2s HTTP/1.1", endpoint, queryString),
new TypeToken<Response>(){}.getType(),
10);
}
private <T> Response<T> sendRequest(String endpoint, Type t, KeyValue... parameters) {
String queryString = "";
for (KeyValue entry: parameters)
queryString += String.format("%1s=%2s&", entry.key, entry.value);
return sendRequest(String.format("GET /%1s/?%2s HTTP/1.1", endpoint, queryString), t, 10);
}
private <T> Response<T> sendRequest(String message, Type t, int retries) {
try(Socket socket = new Socket(hostname, port)) {
socket.getOutputStream().write(message.getBytes());
while (socket.getInputStream().available() == 0){}
String reaponseString = "";
while(socket.getInputStream().available() != 0){
byte[] buffer = new byte[socket.getInputStream().available()];
socket.getInputStream().read(buffer);
reaponseString += new String(buffer);
}
String content = reaponseString.substring(reaponseString.indexOf("\n\n")+2);
return new Gson().fromJson(content, t);
} catch (java.net.ConnectException e) {
throw new com.chaos.octopus.commons.exception.ConnectException("Connection to Orchestrator could not be established, check hostname and port", e);
} catch (Exception e) {
if (retries > 0) {
sleep(250);
sendRequest(message, t, --retries);
}
// TODO This exception should be handled at a higher level
System.err.println("Couldn't connect to: " + "" + ":" + "");
e.printStackTrace();
throw new com.chaos.octopus.commons.exception.ConnectException("Failed to call Agent after multiple attempts", e);
}
}
private void sleep(int millis) {
try {
Thread.sleep(millis);
} catch (InterruptedException e1) {
}
}
}
......@@ -22,6 +22,7 @@ public class AllocationHandler implements AutoCloseable {
public void addAgent(AgentProxy agent) {
_agents.add(agent);
enqueueNextTaskOnAgent();
}
......@@ -48,23 +49,28 @@ public class AllocationHandler implements AutoCloseable {
private void enqueueNextTaskOnAgent() {
synchronized (_Jobs) {
for (Job job : _Jobs)
for (Task task : job.getTasks(TaskState.isQueueable()))
{
for (Task task : job.getTasks(TaskState.isQueueable())) {
task.setTargetAgent(job.targetAgent);
enqueue(task);
}
}
}
private Object enqueueLock = new Object();
public void enqueue(Task task) {
for (int i = 0; i < _agents.size(); i++) {
AgentProxy agent = _agents.get(i);
if(task.getTargetAgent() != null && !agent.getHostname().equals(task.getTargetAgent())) continue;
synchronized (enqueueLock) {
if(agent.isQueueFull()) continue;
task.set_State(TaskState.Queued);
enqueueOrDisconnectAgent(task, agent);
}
task.set_State(TaskState.Queued);
return;
}
......@@ -79,10 +85,8 @@ public class AllocationHandler implements AutoCloseable {
}
public ArrayList<AgentProxy> getAgents() {
synchronized (_agents) {
return _agents;
}
}
public synchronized void taskUpdate(Task task) {
Job job = getJob(task);
......@@ -122,7 +126,7 @@ public class AllocationHandler implements AutoCloseable {
return job;
}
throw new ArrayIndexOutOfBoundsException("Job containing given task not found");
throw new ArrayIndexOutOfBoundsException("Job containing given key not found");
}
public int getQueued() {
......
......@@ -7,7 +7,6 @@ package com.chaos.octopus.server;
import com.chaos.octopus.commons.core.*;
import com.chaos.octopus.commons.core.message.ConnectMessage;
import com.chaos.octopus.commons.core.message.Message;
import com.chaos.octopus.commons.core.message.TaskMessage;
import com.chaos.octopus.commons.exception.ConnectException;
import com.chaos.octopus.commons.http.SimpleServer;
import com.chaos.octopus.commons.util.Commands;
......@@ -26,15 +25,12 @@ import java.net.SocketException;
import java.util.ArrayList;
import java.util.List;
public class OrchestratorImpl implements Orchestrator, Runnable {
public class OrchestratorImpl implements Orchestrator {
// keeps track of the jobs thqt need to be updated
// listens for packets from the agents
// Parses the message and decides how to handle it
// Contains the synchronization
private final ConcurrentJobQueue _jobsWithUpdates;
private boolean _isRunning = false;
private Thread _thread;
private ServerSocket _socket;
private int _port;
private AllocationHandler _AllocationHandler;
private Synchronization _synchronization;
......@@ -51,9 +47,10 @@ public class OrchestratorImpl implements Orchestrator, Runnable {
_jobsWithUpdates = queue;
_synchronization = sync;
_simpleServer = new SimpleServer();
_simpleServer = new SimpleServer(listeningPort);
_simpleServer.addEndpoint("Task/Update", new TaskUpdateEndpoint());
_simpleServer.addEndpoint("Task/Complete", new TaskCompleteEndpoint());
_simpleServer.addEndpoint("Agent/Connect", new AgentConnectEndpoint());
}
public static OrchestratorImpl create(OctopusConfiguration config) throws IOException {
......@@ -75,53 +72,8 @@ public class OrchestratorImpl implements Orchestrator, Runnable {
}
public void open() {
try {
_socket = new ServerSocket(_port);
_isRunning = true;
_thread = new Thread(this);
_thread.setName("Orchestrator");
_thread.start();
// todo: move interval to configuration
_synchronization.synchronize(30 * 1000); // synchronize every 30 seconds
} catch (IOException e) {
e.printStackTrace();
}
}
public void run() {
while (_isRunning) {
try (Socket socket = _socket.accept()) {
String result = StreamUtilities.ReadString(socket.getInputStream());
Message message = Message.createFromJson(result);
// todo: refactor switch, perhaps using the specification pattern.
switch (message.getAction()) {
case Commands.CONNECT: {
ConnectMessage connect = ConnectMessage.createFromJson(result);
try {
AgentProxy ap = new AgentProxy(connect.get_Hostname(), connect.get_Port());
ap.InitializeAgent();
_AllocationHandler.addAgent(ap);
} catch (ConnectException e) {
System.err.println("Connection to Agent could not be established, hostname: " + connect.get_Hostname() + ", port: " + connect.get_Port());
e.printStackTrace();
}
break;
}
}
} catch (SocketException se) {
// if the socket is closed it means the server is turned off, so we can ignore the exception
if (!_socket.isClosed()) se.printStackTrace();
} catch (IOException | InterruptedException e) {
e.printStackTrace();
}
}
}
@Override
......@@ -161,10 +113,8 @@ public class OrchestratorImpl implements Orchestrator, Runnable {
}
public void close() throws Exception {
_isRunning = false;
_simpleServer.stop();
if (_socket != null) _socket.close();
if (_AllocationHandler != null) _AllocationHandler.close();
if (_synchronization != null) _synchronization.stop();
}
......@@ -186,6 +136,7 @@ public class OrchestratorImpl implements Orchestrator, Runnable {
private class TaskUpdateEndpoint implements Endpoint {
public Response invoke(Request request) {
String taskJson = request.queryString.get("task");
Task task = StreamUtilities.ReadJson(taskJson, Task.class);
taskUpdate(task);
......@@ -204,4 +155,23 @@ public class OrchestratorImpl implements Orchestrator, Runnable {
return new Response();
}
}
private class AgentConnectEndpoint implements Endpoint {
public Response invoke(Request request) {
String hostname = request.queryString.get("hostname");
int port = Integer.parseInt(request.queryString.get("port"));
try {
AgentProxy ap = new AgentProxy(hostname, port);
ap.InitializeAgent();
_AllocationHandler.addAgent(ap);
} catch (ConnectException e) {
System.err.println("Connection to Agent could not be established, hostname: " + hostname + ", port: " + port);
e.printStackTrace();
}
return new Response();
}
}
}
......@@ -21,8 +21,8 @@ public class Heartbeat implements SynchronizationTask {
for (AgentProxy ap : allocationHandler.getAgents()){
ClusterState.AgentState as = ap.getState();
as.hasAvailableSlots = !ap.isQueueFull();
as.hostname = ap.get_network().get_hostname();
as.port = ap.get_network().get_port();
as.hostname = ap.getHostname();
as.port = ap.port;
state.agents.add(as);
}
......
......@@ -8,6 +8,8 @@ import com.chaos.sdk.v6.dto.ClusterState;
import junit.framework.Assert;
import org.junit.Test;
import static junit.framework.Assert.*;
public class AgentProxyTest {
@Test
public void getState_AgentNotConnected_ReturnDisconnectedState(){
......@@ -15,7 +17,7 @@ public class AgentProxyTest {
ClusterState.AgentState state = ap.getState();
Assert.assertEquals("Disconnected", state.state);
assertEquals("Disconnected", state.state);
}
@Test
......@@ -28,8 +30,8 @@ public class AgentProxyTest {
ClusterState.AgentState state = ap.getState();
Assert.assertEquals("Connected", state.state);
Assert.assertEquals(1, state.parallelism);
assertEquals("Connected", state.state);
assertEquals("Parallelism not set", 1, state.parallelism);
}
}
}
......@@ -51,7 +51,7 @@ public class AllocationHandlerTest
AgentProxy agent = mock(AgentProxy.class);
ah.addAgent(agent);
ah.enqueue(job);
task1.set_State(TaskState.Committed); // simulate the task was completed
task1.set_State(TaskState.Committed); // simulate the key was completed
ah.taskComplete(task1);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment