aboutsummaryrefslogtreecommitdiffstats
path: root/oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java
diff options
context:
space:
mode:
Diffstat (limited to 'oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java')
-rw-r--r--oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java404
1 files changed, 201 insertions, 203 deletions
diff --git a/oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java b/oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java
index a9b1a2d..0150bbb 100644
--- a/oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java
+++ b/oom-app-common/src/main/java/org/onap/oom/dashboard/rest/IControllerRestClient.java
@@ -7,9 +7,9 @@
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -24,7 +24,6 @@ package org.onap.oom.dashboard.rest;
import java.net.URI;
import java.time.Instant;
import java.util.List;
-
import org.onap.oom.dashboard.model.CloudifyBlueprintContent;
import org.onap.oom.dashboard.model.CloudifyBlueprintList;
import org.onap.oom.dashboard.model.CloudifyBlueprintUpload;
@@ -45,204 +44,203 @@ import org.onap.oom.dashboard.model.ConsulServiceInfo;
*/
public interface IControllerRestClient {
- public static String blueprintsPath = "blueprints";
- public static String viewBlueprintsPath = "viewblueprints";
- public static String deploymentsPath = "deployments";
- public static String executionsPath = "executions";
- public static String healthServicesPath = "healthservices";
-
- /**
- * Gets the list of Cloudify blueprints.
- *
- * @return CloudifyBlueprintList
- */
- public CloudifyBlueprintList getBlueprints();
-
- /**
- * Gets the Cloudify blueprint metadata for the specified ID
- *
- * @param id
- * Blueprint ID
- * @return CloudifyBlueprintList of size 1; null if not found
- */
- public CloudifyBlueprintList getBlueprint(String id);
-
- /**
- * Gets the Cloudify blueprint content for the specified ID
- *
- * @param id
- * Blueprint ID
- * @return Blueprint content
- */
- public CloudifyBlueprintContent viewBlueprint(String id);
-
- /**
- * Uploads a Cloudify blueprint.
- *
- * @param blueprint
- * Cloudify Blueprint to upload
- * @return CloudifyBlueprintList of size 1; null if not found
- */
- public CloudifyBlueprintList uploadBlueprint(CloudifyBlueprintUpload blueprint);
-
- /**
- * Deletes the Cloudify blueprint with the specified id.
- *
- * @param id
- * Blueprint ID
- * @return Status code; e.g., 200, 202, 204.
- */
- public int deleteBlueprint(String id);
-
- /**
- * Gets the list of Cloudify deployments.
- *
- * @return CloudifyDeploymentList
- */
- public CloudifyDeploymentList getDeployments();
-
- /**
- * Gets the Cloudify deployment for the specified ID
- *
- * @param id
- * Deployment ID
- * @return CloudifyDeploymentList of size 1; null if not found.
- */
- public CloudifyDeploymentList getDeployment(String id);
-
- /**
- * Creates a Cloudify deployment.
- *
- * @param deployment
- * Deployment details
- * @return CloudifyDeploymentList of size 1
- */
- public CloudifyDeploymentList createDeployment(CloudifyDeploymentRequest deployment);
-
- /**
- * Deletes the Cloudify deployment with the specified id.
- *
- * @param id
- * Deployment ID
- * @param ignoreLiveNodes
- * Boolean indicator whether to delete even if live nodes exist
- * @return Status code; e.g., 200, 202, 204.
- */
- public int deleteDeployment(String id, boolean ignoreLiveNodes);
-
- /**
- * Gets the Cloudify executions for the specified deployment ID
- *
- * @param deploymentId
- * Deployment ID
- * @return CloudifyExecutionList
- */
- public CloudifyExecutionList getExecutions(String deploymentId);
-
- /**
- * Gets the Cloudify execution for the specified execution ID and deployment
- * ID
- *
- * @param executionId
- * Execution ID
- * @param deploymentId
- * Deployment ID
- * @return CloudifyExecutionList of size 1
- */
- public CloudifyExecutionList getExecution(String executionId, String deploymentId);
-
- /**
- * Starts a Cloudify execution.
- *
- * @param execution
- * Execution details
- * @return CloudifyExecution
- */
- public CloudifyExecution startExecution(CloudifyExecutionRequest execution);
-
- /**
- * Deletes the Cloudify execution with the specified ids.
- *
- * @param executionId
- * execution ID
- * @param deploymentId
- * Deployment ID
- * @param action
- * either "cancel" or "force-cancel"
- * @return Status code; e.g., 200, 202, 204.
- */
- public int cancelExecution(String executionId, String deploymentId, String action);
-
- /**
- * Registers a service with Consul for health check.
- *
- * @param registration
- * Details about the service to be registered.
- * @return Result of registering a service
- */
- public URI registerService(ConsulHealthServiceRegistration registration);
-
- /**
- * Deregisters a service with Consul for health check.
- *
- * @param serviceName
- * Name of the service to be deregistered.
- * @return Response code
- */
- public int deregisterService(String serviceName);
-
- /**
- * Gets all the services that are monitored by Consul.
- *
- * @return List of ConsulServiceHealth
- */
- public List<ConsulServiceInfo> getServices();
-
- /**
- * Gets the status for the specified service on all nodes.
- *
- * @param serviceName
- * Service name
- * @return List of ConsulServiceHealth
- */
- public List<ConsulServiceHealth> getServiceHealth(String serviceName);
-
- /**
- * Gets the status for the specified service on all nodes for the specified
- * time window.
- *
- * @param serviceName
- * Service name
- * @param start
- * Start (earliest point) of the time window
- * @param end
- * End (latest point) of the time window
- * @return List of ConsulServiceHealth
- */
- public List<ConsulServiceHealthHistory> getServiceHealthHistory(String serviceName, Instant start, Instant end);
-
- /**
- * Gets all the nodes that are monitored by Consul.
- *
- * @return List of ConsulNodeHealth
- */
- public List<ConsulNodeInfo> getNodes();
-
- /**
- * Gets the status for all registered services running on the specified
- * node.
- *
- * @param nodeId
- * Node ID
- * @return List of ConsulServiceHealth
- */
- public List<ConsulServiceHealth> getNodeServicesHealth(String nodeId);
-
- /**
- * Gets all the data centers that are monitored by Consul.
- *
- * @return List of ConsulDatacenter objects
- */
- public List<ConsulDatacenter> getDatacenters();
-
+ String blueprintsPath = "blueprints";
+ String viewBlueprintsPath = "viewblueprints";
+ String deploymentsPath = "deployments";
+ String executionsPath = "executions";
+ String healthServicesPath = "healthservices";
+
+ /**
+ * Gets the list of Cloudify blueprints.
+ *
+ * @return CloudifyBlueprintList
+ */
+ CloudifyBlueprintList getBlueprints();
+
+ /**
+ * Gets the Cloudify blueprint metadata for the specified ID
+ *
+ * @param id
+ * Blueprint ID
+ * @return CloudifyBlueprintList of size 1; null if not found
+ */
+ CloudifyBlueprintList getBlueprint(String id);
+
+ /**
+ * Gets the Cloudify blueprint content for the specified ID
+ *
+ * @param id
+ * Blueprint ID
+ * @return Blueprint content
+ */
+ CloudifyBlueprintContent viewBlueprint(String id);
+
+ /**
+ * Uploads a Cloudify blueprint.
+ *
+ * @param blueprint
+ * Cloudify Blueprint to upload
+ * @return CloudifyBlueprintList of size 1; null if not found
+ */
+ CloudifyBlueprintList uploadBlueprint(CloudifyBlueprintUpload blueprint);
+
+ /**
+ * Deletes the Cloudify blueprint with the specified id.
+ *
+ * @param id
+ * Blueprint ID
+ * @return Status code; e.g., 200, 202, 204.
+ */
+ int deleteBlueprint(String id);
+
+ /**
+ * Gets the list of Cloudify deployments.
+ *
+ * @return CloudifyDeploymentList
+ */
+ CloudifyDeploymentList getDeployments();
+
+ /**
+ * Gets the Cloudify deployment for the specified ID
+ *
+ * @param id
+ * Deployment ID
+ * @return CloudifyDeploymentList of size 1; null if not found.
+ */
+ CloudifyDeploymentList getDeployment(String id);
+
+ /**
+ * Creates a Cloudify deployment.
+ *
+ * @param deployment
+ * Deployment details
+ * @return CloudifyDeploymentList of size 1
+ */
+ CloudifyDeploymentList createDeployment(CloudifyDeploymentRequest deployment);
+
+ /**
+ * Deletes the Cloudify deployment with the specified id.
+ *
+ * @param id
+ * Deployment ID
+ * @param ignoreLiveNodes
+ * Boolean indicator whether to delete even if live nodes exist
+ * @return Status code; e.g., 200, 202, 204.
+ */
+ int deleteDeployment(String id, boolean ignoreLiveNodes);
+
+ /**
+ * Gets the Cloudify executions for the specified deployment ID
+ *
+ * @param deploymentId
+ * Deployment ID
+ * @return CloudifyExecutionList
+ */
+ CloudifyExecutionList getExecutions(String deploymentId);
+
+ /**
+ * Gets the Cloudify execution for the specified execution ID and deployment
+ * ID
+ *
+ * @param executionId
+ * Execution ID
+ * @param deploymentId
+ * Deployment ID
+ * @return CloudifyExecutionList of size 1
+ */
+ CloudifyExecutionList getExecution(String executionId, String deploymentId);
+
+ /**
+ * Starts a Cloudify execution.
+ *
+ * @param execution
+ * Execution details
+ * @return CloudifyExecution
+ */
+ CloudifyExecution startExecution(CloudifyExecutionRequest execution);
+
+ /**
+ * Deletes the Cloudify execution with the specified ids.
+ *
+ * @param executionId
+ * execution ID
+ * @param deploymentId
+ * Deployment ID
+ * @param action
+ * either "cancel" or "force-cancel"
+ * @return Status code; e.g., 200, 202, 204.
+ */
+ int cancelExecution(String executionId, String deploymentId, String action);
+
+ /**
+ * Registers a service with Consul for health check.
+ *
+ * @param registration
+ * Details about the service to be registered.
+ * @return Result of registering a service
+ */
+ URI registerService(ConsulHealthServiceRegistration registration);
+
+ /**
+ * Deregister a service with Consul for health check.
+ *
+ * @param serviceName
+ * Name of the service to be deregister.
+ * @return Response code
+ */
+ int deregisterService(String serviceName);
+
+ /**
+ * Gets all the services that are monitored by Consul.
+ *
+ * @return List of ConsulServiceHealth
+ */
+ List<ConsulServiceInfo> getServices();
+
+ /**
+ * Gets the status for the specified service on all nodes.
+ *
+ * @param serviceName
+ * Service name
+ * @return List of ConsulServiceHealth
+ */
+ List<ConsulServiceHealth> getServiceHealth(String serviceName);
+
+ /**
+ * Gets the status for the specified service on all nodes for the specified
+ * time window.
+ *
+ * @param serviceName
+ * Service name
+ * @param start
+ * Start (earliest point) of the time window
+ * @param end
+ * End (latest point) of the time window
+ * @return List of ConsulServiceHealth
+ */
+ List<ConsulServiceHealthHistory> getServiceHealthHistory(String serviceName, Instant start, Instant end);
+
+ /**
+ * Gets all the nodes that are monitored by Consul.
+ *
+ * @return List of ConsulNodeHealth
+ */
+ List<ConsulNodeInfo> getNodes();
+
+ /**
+ * Gets the status for all registered services running on the specified
+ * node.
+ *
+ * @param nodeId
+ * Node ID
+ * @return List of ConsulServiceHealth
+ */
+ List<ConsulServiceHealth> getNodeServicesHealth(String nodeId);
+
+ /**
+ * Gets all the data centers that are monitored by Consul.
+ *
+ * @return List of ConsulDatacenter objects
+ */
+ List<ConsulDatacenter> getDatacenters();
}