-
Notifications
You must be signed in to change notification settings - Fork 8
Detailed Design







controller
public class FileController
The uploading file controller in the system.
| Modifier and Type | Field | Description |
|---|---|---|
| private Neo4jController | neo4jController | neo4j database controller |
postType
public Map<String, Object> postType(HttpServletRequest request, HttpServletResponse response, @RequestParam("name") String name)
Deal the system ontology file.
returns
Map<String, Object>
parameters
HttpServletRequest request, HttpServletResponse response,String name
postSystem
public Map<String, Object> postSystem(HttpServletRequest request, HttpServletResponse response, String name,String type)
Deal system instance file.
returns
Map<String, Object>
parameters
HttpServletRequest request, HttpServletResponse response, String name,String type

neo4jcontroller
public class Neo4jController
The neo4j database controller in the system.
| Modifier and Type | Field | Description |
|---|---|---|
| private NodeDAO | nodeDAO | Node data access object |
| private RelationDAO | relationDAO | Relation data access object |
sendEvent
public void sendEvent(String type,String time,String situation,String timeout,String command,String id)
add event node and then build the relationship between the event and the inject target node.
returns
void
parameters
String type,String time,String situation,String timeout,String command,String id
fileupdate
public String fileupdate(HttpServletRequest request,HttpServletResponse response, MultipartFile file, String system)
update system file.
returns
file access path
parameters
HttpServletRequest request,HttpServletResponse response, MultipartFile file, String system
importTtl
public void importTtl(String typePath, String systemPath)
import ttl file
returns
void
parameters
String typePath, String systemPath
addServiceNode
public int addServiceNode(String label, String port, String name, String nameSpace, String targetPort)
Add service node.
returns
node ID
parameters
String label, String port, String name, String nameSpace, String targetPort
addSystemNode
public int addSystemNode(String name)
Add system node.
returns
node ID
parameters
String name
addYamlRelation
public HashMap<String, Object> addYamlRelation(int deploymentID, int containnerID, int serviceID, int systemID)
Add relation of node included in yaml file.
returns
information of relation
parameters
int deploymentID, int containnerID, int serviceID, int systemID
addMetricNode
*public HashMap addMetricNode(String type, String podName, String metricName, String dataName, String relationName) *
Add metric node.
returns
node information
parameters
String type, String podName, String metricName, String dataName, String relationName
addMetricRelation
public HashMap<String, Object> addMetricRelation(int sourceID, int targetID, String relationship)
Add metric relation.
returns
relation information
parameters
int sourceID, int targetID, String relationship
addDataSetNode
public Boolean addDataSetNode(String filePath, String name, String system)
Add data set node.
returns
node information
parameters
String filePath, String name, String system
addServiceRelation
public Boolean addServiceRelation(String name, ArrayList<String> arrList)
Add service relation.
returns
relation information
parameters
String name, ArrayList<String> arrList
getLabel
public HashMap<String, List<HasMap<String, Object>>> getLable(String label)
Get.
returns
All nodes which have the same label and their relations.
parameters
String label
csvOperationData
public HashMap<String, ArrayList> csvOperationData(String filePath)
Get operation data time serial diagram needs.
returns
All operation data.
parameters
String filePath
podToMetric
public Boolean podToMetric(String type, int ID, String podName)
add pod to metric relation.
returns
success/fail
parameters
String type, int ID, String podName
metricToDataset
public Boolean metricToDataset(int ID, String dataBaseName, String, resultName)
add metric to dataset relation.
returns
success/fail
parameters
int ID, String dataBaseName, String, resultName

controller
public class InputRelController
The relation input controller in the system.
| Modifier and Type | Field | Description |
|---|---|---|
| private Neo4jController | neo4jController | neo4j database controller |
addMetric
public HashMap addMetric(String type, String podName, String metricName, String datasetName, String relationName)
Add the metric node.
returns
The information of the newly added metric node.
parameters
String type, String podName, String metricName, String datasetName, String relationName

controller
public class ViewController
The information view controller in the system.
| Modifier and Type | Field | Description |
|---|---|---|
| private Neo4jController | neo4jController | neo4j database controller |
getEntitiesAndRelations
public HashMap<String, List<HasMap<String, Object>>> getEntitiesAndRelations(String entityName)
Get all nodes which have the same label.
returns
All nodes which have the same label and their relations.
parameters
String entityName
addMetric
public HashMap<String, List<HasMap<String, List>>> getOperationData(String datasetName)
Get operation data time serial diagram needs.
returns
All operation data.
parameters
String datasetName

DAO
public class Neo4jDAO
The relation access object in the system.
getNodeAndLink
- public Map getNodeAndLink(String systemName)*
parameters
String systemName
get all nodes and links in the neo4j database that related to the provided system node.