adding filter document
[dmaap/messagerouter/messageservice.git] / docs / message-router / message-router.rst
index fbd7015..d8c597b 100644 (file)
@@ -6,13 +6,10 @@ Architecture
 \r
 In DMaaP Message Router, Restful web service is exposed to client to perform any needed action with Kafka. After getting the request it calls the Message router service layer which is created using AJSC ( AT&T Java Service Container) . AJSC finally calls Kafka services and response is sent back.\r
 \r
-|image0|\r
-\r
-.. |image0| image:: message router.jpg\r
-   :height: 600px\r
-   :width: 800px\r
-\r
+   |image0|\r
 \r
+   .. |image0| image:: image1.png\r
+   \r
 \r
 HTTP Service APIs\r
 ------------------\r
@@ -65,8 +62,8 @@ are not inspected for content.
 | Content-Type            |  Description                                                                                                   |\r
 +=========================+================================================================================================================+\r
 | text/plain              | Each line in the POST body is treated as a separate message. No partition key is specified, and therefore no   |\r
-|                                                |     order is guaranteed. This format is mainly for test, as messages are highly likely to be re-ordered when       |\r
-|                                                | delivered through the Kafka cluster.                                                                           |\r
+|                                |     order is guaranteed. This format is mainly for test, as messages are highly likely to be re-ordered when       |\r
+|                            | delivered through the Kafka cluster.                                                                           |\r
 +-------------------------+----------------------------------------------------------------------------------------------------------------+\r
 | application/json        | The payload maybe a single JSON object or a JSON array of JSON objects. Each object is handled as an individual|\r
 |                                                | message..Note that use of this format may result in equivalent but altered JSON objects sent to consumers.     | \r
@@ -112,7 +109,7 @@ Request Parameters
 | partitionKey             |                                 |  QueryParam      | String     |           | N           | String value                   |?Partitionkey=123            |\r
 +--------------------------+---------------------------------+------------------+------------+-----------+-------------+--------------------------------+-----------------------------+\r
 \r
-**NOTE:** Publishers/user should have access on the topics. The user (id) and\r
+**NOTE **: Publishers/user should have access on the topics. The user (id) and\r
 permissions details needs to be in AAF.\r
 \r
 Response Parameters\r
@@ -210,14 +207,13 @@ Subscribers
 Request URL:\r
 ============\r
 \r
-GET http(s)://{HOST:PORT}}/events/{topicname}/{consumegroup}/{consumerid}?{timeout=x}\r
+GET http(s)://{HOST:PORT}}/events/{topicname}/{consumegroup}/{consumerid}/{timeout=x}\r
 \r
 Request Parameters:\r
 ==================\r
 \r
 +-------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-------------------------------------------------+\r
 | Name        | Description                     |  Param Type      |  data type |   MaxLen     |  Req\92d      |  Format     |  Valid/Example Values                           |\r
-|                        |                                                             |                                  |            |              |             |             |                                                                                             |\r
 +=============+=================================+==================+============+==============+=============+=============+=================================================+\r
 | Topicname   | topic name to be posted         |     Path         |   String   |        40    |     Y       | namespace.  |                                                                                            |\r
 |                        |                                                                     |                                  |            |              |             |  String     |                                                 |\r
@@ -237,7 +233,7 @@ Request Parameters:
 | Password    |                                 | Header           | String     | 1            | N           |             |                                                 |\r
 +-------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-------------------------------------------------+       \r
 \r
-**NOTE1:**Subscribers /user should have access on the topics. The user () and\r
+**NOTE1**:Subscribers /user should have access on the topics. The user () and\r
 permissions details needs to be in AAF.\r
 \r
 Response Parameters:\r
@@ -258,7 +254,7 @@ Response Parameters:
 +------------------+--------------------------------+------------+--------------+-----------------------------------------------------------+\r
 | ResponseBody     | Messages consumed from topic   | Json       | Json         |                                                           |\r
 +------------------+--------------------------------+------------+--------------+-----------------------------------------------------------+\r
-|\r
+\r
 +---------------------------+------------------------------------+\r
 | Response statusCode       | Response statusMessage             |\r
 +===========================+====================================+\r
@@ -268,7 +264,7 @@ Response Parameters:
 +---------------------------+------------------------------------+\r
 | 500-599                   | the DMaaP service has a problem    |\r
 +---------------------------+------------------------------------+\r
-|\r
+\r
 +-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
 | Error code              |  HTTP Code      |  Description               |Issue reason                                                                                        |\r
 +=========================+=================+============================+====================================================================================================+\r
@@ -306,18 +302,17 @@ Request Parameters:
 \r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+\r
 | Name           | Description                     |  Param Type      |  data type |   MaxLen     |  Req\92d      |  Format     |  Valid/Example Values             |\r
-|                           |                                                             |                              |            |              |             |             |                                                   |\r
 +================+=================================+==================+============+==============+=============+=============+===================================+\r
 | Topicname      | topicname to be created in MR   |     Body         |   String   |        20    |     Y       | Json        |                com.att.dmaap.mr.metrics      |\r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+       \r
-|topicDescription|   description for topic         |      Body        |   String   |     15       | Y           |             |                                   |\r
+|topicDescription|   description for topic         |      Body        |   String   |     15       |     Y       |             |                                   |\r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+  \r
 |partitionCount  |   Kafka topic partition         |     Body         |   String   |     1        | Y           |             |                                   |\r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+ \r
 |replicationCount|   Kafka topic replication       |     Body         |   String   |     1        | Y           |             |  3 (Default -for 3 node Kafka )   |\r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+ \r
 |transaction     |to create transaction id for     |     Body         | Boolean    |              |             |             |                                   |\r
-|                               |      each message transaction       |                  |            |      1       |        N    |             |   true                            |\r
+|                |     each message transaction       |                  |            |      1       |        N    |             |   true                            |\r
 | Enabled        |                                 |                  |            |              |             |             |                                   | \r
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+ \r
 |Content-Type    |   application/json              |     Header       |   String   |              |             |             |  application/json                 |\r
@@ -337,7 +332,7 @@ Request Parameters:
 | Error code              |  HTTP Code      |  Description                                     |\r
 +=========================+=================+==================================================+\r
 | DMaaP\_MR\_ERR\_5001    | 500             | Failed to retrieve list of all topics            | +-------------------------+-----------------+--------------------------------------------------+\r
-| DMaaP\_MR\_ERR\_5002    | 500             | Failed to retrieve details of topic:<topicName>  |     |+-------------------------+----------------+--------------------------------------------------+\r
+| DMaaP\_MR\_ERR\_5002    | 500             | Failed to retrieve details of topic:<topicName>  |     +-------------------------+-----------------+--------------------------------------------------+\r
 | DMaaP\_MR\_ERR\_5003    | 500             |Failed to create topic:<topicName>                | +-------------------------+-----------------+--------------------------------------------------+\r
 | DMaaP\_MR\_ERR\_5004    | 500             | Failed to delete topic:<topicName>               | +-------------------------+-----------------+--------------------------------------------------+\r
 \r
@@ -349,7 +344,7 @@ Response Parameters
 +==================+================================+============+==============+===========================================================+\r
 | httpStatusCode   |                                |            |              | 200, 201 etc.                                             |\r
 +------------------+--------------------------------+------------+--------------+-----------------------------------------------------------+\r
-| mrErrorCode      | Numeric error code             |            |              |5005                                                       |\r
+| mrErrorCode      | Numeric error code             |            |              | 5005                                                       |\r
 +------------------+--------------------------------+------------+--------------+-----------------------------------------------------------+\r
 | errorMessage     |                                |            |              | SUCCESS, or error message.                                |\r
 +------------------+--------------------------------+------------+--------------+-----------------------------------------------------------+\r
@@ -366,19 +361,19 @@ Sample Request:
 +-----------------------------------------------------------------------------------+\r
 | POST   http://<hostname>:3904/topic/create                                        |\r
 |Request Body                                                                       |\r
-|{"topicName":"com.att.dmaap.mr.topicname","description":"This is a SAPTopic ",     |\r
+|{"topicName":"com.abc.dmaap.mr.topicname","description":"This is a SAPTopic ",     |\r
 | "partitionCount":"1","replicationCount":"3","transactionEnabled":"true"}          |\r
 | Content-Type: application/json                                                    |\r
 |Example:                                                                           |\r
 |curl -u XXXc@csp.abc.com:xxxxx$  -H 'Content-Type:application/json' -X POST -d     |\r
-|@topicname.txt  http://mrlocal00.dcae.proto.research.att.com:3904/topics/create    |\r
+|@topicname.txt  http://mrlocal00.dcae.proto.research.abc.com:3904/topics/create    |\r
 |{                                                                                  |\r
 |    "writerAcl": {                                                                 |\r
 |        "enabled": false,                                                          |\r
 |        "users": []                                                                |\r
 |    },                                                                             |\r
 |    "description": "This is a TestTopic",                                          |\r
-|    "name": "com.att.ecomp_test.crm.Load9",                                        |\r
+|    "name": "com.abc.ecomp_test.crm.Load9",                                        |\r
 |    "readerAcl": {                                                                 |\r
 |        "enabled": false,                                                          |\r
 |        "users": []                                                                |\r
@@ -400,7 +395,7 @@ Request Parameters
 +--------------------------+---------------------------------+------------------+------------+-----------+-------------+-----------------+-----------------------------+\r
 | Name                     | Description                     | Param Type       | Data type  | Max Len   | Req\92d       | Format          | Valid/EXample values        |\r
 +==========================+=================================+==================+============+===========+=============+=================+=============================+\r
-| Topicname                | topic name details              | Body             | String     | 20        | Y           |  Json           | com.att.dmaap.mr.metrics    |\r
+| Topicname                | topic name details              | Body             | String     | 20        | Y           |  Json           | com.abc.dmaap.mr.metrics    |\r
 +--------------------------+---------------------------------+------------------+------------+-----------+-------------+-----------------+-----------------------------+\r
 \r
 \r
@@ -410,7 +405,7 @@ Response Parameters
 +------------------+------------------------+------------+----------+---------+--------------------------+\r
 | Name             | Description            | ParamType  | datatype |Format   | Valid/Example Values     |\r
 +==================+========================+============+==========+=========+==========================+\r
-| topicname        |  topic name details    |      Body  |   String |   Json  | com.att.dmaap.mr.metrics | \r
+| topicname        |  topic name details    |      Body  |   String |   Json  | com.abc.dmaap.mr.metrics | \r
 +------------------+------------------------+------------+----------+---------+--------------------------+\r
 | description      |                        |            |   String |         |                          | \r
 +------------------+------------------------+------------+----------+---------+--------------------------+\r
@@ -442,14 +437,14 @@ Sample Request:
 |    {                                                                              |\r
 |       "txenabled": true,                                                          |\r
 |        "description": "This is a TestTopic",                                      |\r
-|      "owner": "rs857c@csp.att.com",                                               |\r
-|        "topicName": "com.att.ecomp_test.crm.Load9"                                |\r
+|      "owner": "XXXX@csp.abc.com",                                               |\r
+|        "topicName": "com.abc.ecomp_test.crm.Load9"                                |\r
 |    },                                                                             |\r
 |    {                                                                              |\r
 |        "txenabled": false,                                                        |\r
 |        "description": "",                                                         |\r
 |        "owner": "",                                                               |\r
-|        "topicName": "com.att.ecomp_test.crm.Load1"                                |\r
+|        "topicName": "com.abc.ecomp_test.crm.Load1"                                |\r
 |    },                                                                             |\r
 +-----------------------------------------------------------------------------------+\r
 \r