From 0f987a9e1b8e79caef48015adf865eef36216dbc Mon Sep 17 00:00:00 2001 From: "serena.spinoso" Date: Sun, 29 Apr 2018 10:48:44 +0200 Subject: Add CLI in verigraph. JIRA: PARSER-180 Add CLI to select one of the available interfaces (i.e. REST or gRPC), one of the supported service descriptor formats (i.e. TOSCA/XML, TOSCA/YAML, JSON), and the operations to perform (i.e. read, create, update, delete graphs and run verifications). Change-Id: I02f4d86e221baf0ac583d0ffd0ebe028aa6209be Signed-off-by: serena.spinoso --- .../src/it/polito/verigraph/tosca/README_CLI.txt | 66 ++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 verigraph/src/it/polito/verigraph/tosca/README_CLI.txt (limited to 'verigraph/src/it/polito/verigraph/tosca/README_CLI.txt') diff --git a/verigraph/src/it/polito/verigraph/tosca/README_CLI.txt b/verigraph/src/it/polito/verigraph/tosca/README_CLI.txt new file mode 100644 index 0000000..6ee1332 --- /dev/null +++ b/verigraph/src/it/polito/verigraph/tosca/README_CLI.txt @@ -0,0 +1,66 @@ +** Verigraph Verification Service - Command Line Interface ** + +The CLI allows to interact with the Verigraph Verification Service using both the RESTful and gRPC interface. +The CLI allows CRUD operations on graphs and three kind of verification. + + +-- Available commands -- +> CONFIGURE -use -format -port -host +> HELP +> EXIT +> GETALL +> GET +> CREATE +> UPDATE +> DELETE +> VERIFY [ ] + + +-- CLI commands -- +> CONFIGURE -use -format +Allows to configure connection parameters (host and port ), the interface (REST or gRPC ) and the data format +(JSON, XML or YAML ) to be used to communicate with the verification service, XML and YAML formats exploit an extension +of TOSCA specification. At program start the default configuration uses the REST interface with XML data format. +Note that the JSON format is not supported by the grpc interface. + +> HELP +Prints on screen the CLI documentation. + +> EXIT +Closes REST/gRPC client and exits. + + +-- CRUD on graphs -- +> GETALL +Performs a request without specifying a particular graph id. The service will return +a list of graph templates in the currently selected format and will print them on screen. + +> GET +Performs a request for a specific graph whose id MUST be specified as a long integer +value. If present the graph will be returned and printed on screen in the currently selected format. + +> CREATE +Performs a create graph request providing a graph template as a file. +The must point to an existing file whose filenme must be coherent with the currently selected +data format. The server can accept or not the provided graph upon its validation against Tosca Verigraph specification +for XML/YAML or against Verigraph JSON schema. For further info see Verigraph Service documentation at [...]. + +> UPDATE +Performs an update request for a specific graph providing a graph template as a file. +The provided filename must be coherent with the currently selected data format and the must be a long integer +corresponding to one of the graphs previously created. The server can accept or not the provided graph upon its +validation against Tosca Verigraph specification for XML/YAML or against Verigraph JSON schema. +For further info see Verigraph Service documentation at [...]. + +> DELETE +Performs a delete request for a specific graph. +The provided id must be a long integer corresponding to a previously created graph. + + +-- Verification -- +> VERIFY [ ] +Performs a verification request for a specific graph. +The must be the long integer id of a previously created graph. Three types of verification services are +available: reachability, isolation and traversal. The source, destination and middlebox node parameters +must be provided as string and must correspond to the name of a Node in the specified graph. The middlebox parameter +must not be provided in case of reachability verification. \ No newline at end of file -- cgit 1.2.3-korg