X-Git-Url: https://gerrit.onap.org/r/gitweb?p=aai%2Frouter-core.git;a=blobdiff_plain;f=README.md;fp=README.md;h=58e7d2fbe1f2346fee14c502035d6bd98a124672;hp=0000000000000000000000000000000000000000;hb=3e372947d497014b4aad4c2c1d04d6c50a74e2e0;hpb=42fcf3b1aff3efea329b61f1d5cc561d9a2490ae diff --git a/README.md b/README.md new file mode 100644 index 0000000..58e7d2f --- /dev/null +++ b/README.md @@ -0,0 +1,102 @@ +# Overview +This component contains a number of general Apache Camel components which are intended for use by the data-router. + +# Maven Dependency +To make use of the Camel components included in this repository, include the following artifact in your dependencies list: + + + org.openecomp + router-core + 1.0.0-SNAPSHOT + + +# How to Build: + + > mvn clean install + + +## Rest Client Component + +The REST client component provides a simple endpoint for sending HTTP requests to a REST endpoint. + +### URI Format + ecomp-rest:op[?options] + +Where, + +op = One of GET, PUT, POST, or DELETE + +### URI Options +The following option parameters must be passed in to the component for HTTPS communications: + +| Parameter | Description | +| --------- | ----------- | +| ecomp-client-cert | Fully qualified path to the client certificate to use for HTTPS communications. | +| ecomp-keystore | Fully qualified path to the keystore file to use for HTTP communications. | +| ecomp-keystore-password | Obfuscated password for the keystore. | + +### IN Message + +#### Ecomp-Rest Header Parameters +| Header Name | Description | +| ----------- | ----------- | +| ecomp-url | The fully qualified URL for the HTTP request to be send. This is mandatory. | + +#### HTTP Header Parameters +The following parameters, if they are present in the Exchange In Message Headers, will be included as header values +in the HTTP request generated by the component: + +| HTTP Header Name | +| ---------------- | +| X-FromAppId | +| X-TransactionId | +| resourceVersion | +| ETag | +| If-Match | +| If-None-Match | +| Accept | + +#### Message Body +For HTTP operations that require a content body, the body of the IN message will be used. + +### OUT Message + +#### Headers +The following header values are populated on the OUT message: + +| ecomp-response-code | The response code produced by the HTTP request. | +| ecomp-response-message | The response message produced by the HTTP request. | + +#### Message Body +For HTTP operations that produce a content body, the body of the OUT message will be populated with this result. + +### Example + +The following route file illustrates a simple example which takes console input and invokes the rest client, using the input from the +console as the content body for the REST request. + + + + + + + + + https://localhost:9509/services/search-data-service/v1/search/indexes/gdf/documents/88 + + + + + DataLayer + + + gdf1 + + + + + + + + +