commiting code for document changes 03/18003/1
authorrn509j <rn509j@att.com>
Tue, 10 Oct 2017 16:22:25 +0000 (12:22 -0400)
committerrn509j <rn509j@att.com>
Tue, 10 Oct 2017 16:24:10 +0000 (12:24 -0400)
DMAAP-153
Signed-off-by: rn509j <rn509j@att.com>
Change-Id: I55c02ec2b963fa1721ffca83d2f6bbd9551be103

docs/message router.jpg [new file with mode: 0644]
docs/message-router/message-router.rst

diff --git a/docs/message router.jpg b/docs/message router.jpg
new file mode 100644 (file)
index 0000000..100973d
Binary files /dev/null and b/docs/message router.jpg differ
index 4289a61..fbd7015 100644 (file)
@@ -1,6 +1,18 @@
 ============================================\r
 Message Router (MR) API Guide\r
 ============================================\r
+Architecture\r
+-------------\r
+\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
+\r
 \r
 HTTP Service APIs\r
 ------------------\r
@@ -206,7 +218,7 @@ Request Parameters:
 +-------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-------------------------------------------------+\r
 | Name        | Description                     |  Param Type      |  data type |   MaxLen     |  Req\92d      |  Format     |  Valid/Example Values                           |\r
 |                        |                                                             |                                  |            |              |             |             |                                                                                             |\r
-+-------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-------------------------------------------------+\r
++=============+=================================+==================+============+==============+=============+=============+=================================================+\r
 | Topicname   | topic name to be posted         |     Path         |   String   |        40    |     Y       | namespace.  |                                                                                            |\r
 |                        |                                                                     |                                  |            |              |             |  String     |                                                 |\r
 +-------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-------------------------------------------------+        \r
@@ -259,7 +271,7 @@ Response Parameters:
 |\r
 +-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
 | Error code              |  HTTP Code      |  Description               |Issue reason                                                                                        |\r
-+-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
++=========================+=================+============================+====================================================================================================+\r
 | DMaaP\_MR\_ERR\_3008    | 413             | Request Entity too large   | Message size exceeds the batch limit <limit>.Reduce the batch size and try again                   | +-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
 | DMaaP\_MR\_ERR\_3009    | 500             | Internal Server Error      | Unable to publish messages. Please contact administartor                                           | +-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
 | DMaaP\_MR\_ERR\_3010    | 400             | Bad Request                | Incorrect Batching format. Please correct the batching format and try again                        | +-------------------------+-----------------+----------------------------+----------------------------------------------------------------------------------------------------+\r
@@ -295,7 +307,7 @@ Request Parameters:
 +----------------+---------------------------------+------------------+------------+--------------+-------------+-------------+-----------------------------------+\r
 | Name           | Description                     |  Param Type      |  data type |   MaxLen     |  Req\92d      |  Format     |  Valid/Example Values             |\r
 |                           |                                                             |                              |            |              |             |             |                                                   |\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
@@ -323,7 +335,7 @@ Request Parameters:
 \r
 +-------------------------+-----------------+--------------------------------------------------+\r
 | Error code              |  HTTP Code      |  Description                                     |\r
-+-------------------------+-----------------+--------------------------------------------------+\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\_5003    | 500             |Failed to create topic:<topicName>                | +-------------------------+-----------------+--------------------------------------------------+\r
@@ -466,7 +478,45 @@ ex: http://<hostname>:3904/dmaap/v1/topics/com.att.dmaap.mr.testopic
 \r
 +-------------------------+---------------------------------------------+----------------------+\r
 | Error code              |    Description                              |HTTP code             |\r
-+-------------------------+---------------------------------------------+----------------------+\r
++=========================+=============================================+======================+\r
 |  DMaaP\_MR\_ERR\_5004   |  Failed to delete topic:<topicName>         |   500                |   \r
 +-------------------------+---------------------------------------------+----------------------+\r
 \r
+API Inventory\r
+------------- \r
+\r
++-----------+-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           |   API Name        |   API Method                            |   REST API Path                       |                | Comments                         |\r
++===========+===================+=========================================+=======================================+================+==================================+\r
+| Topics    | GetAll Topics List|  getTopics()                            | /topics                               | GET            |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           | Get All Topics    |                                         |                                       |                |                                  |\r
+|           |List with details  | getAllTopics()                          | /topics/listAll                       | GET            |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           | Get individual    |                                         |                                       |                |                                  |\r
+|           | Topic Details     | getTopic(String topicName)              | /topics/{topicName}                   | GET            |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           | Create Topic      | createTopic(TopicBean topicBean)        | /topics/create                        | POST           |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           | Delete Topic      | deleteTopicString topicName)            | /topics/{topicName}                   | DELETE         |  Not used in current MR version  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r
+|           | Get Publishers for| getPublishersByTopicName                |                                       |                |                                  |\r
+|           | a Topic           | (String topicName)                      | /topics/{topicName}/producers         | GET            |  UEB Backward Compatibility      |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+                                  |\r
+|           | Add a Publisher to|permitPublisherForTopic(String topicName,| /topics/{topicName}/producers/        |                |                                  |\r
+|           |write ACLon a Topic|     String producerId)                  |    {producerId}                       | PUT            |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+                                  |\r
+|           | Remove a Publisher|denyPublisherForTopic(String   topicName,|/topics/{topicName}/producers/         |                |                                  | \r
+|           |from write   ACL on|String producerId)                       |{producerId}                           |   DELETE       |                                  |\r
+|           | a Topic           |                                         |                                       |                |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+                                  |\r
+|           |Get Consumers for a| getConsumersByTopicName                 |  /topics/{topicName}/consumers        |       GET      |                                  |\r
+|           |  Topic            | (String topicName)                      |                                       |                |                                  |\r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+                                  |\r
+|           | Add a Consumer to | permitConsumerForTopic(String topicName,|   /topics/{topicName}/consumers/      |      PUT       |                                  |\r
+|           |read ACL on a Topic|      String consumerId)                 |       {consumerId}                    |                |                                  |    \r
+|           +-------------------+-----------------------------------------+---------------------------------------+----------------+                                  |\r
+|           | Remove a consumer |denyPublisherForTopic(String   topicName,|/topics/{topicName}/consumers/         |                |                                  | \r
+|           |from write   ACL on|String consumerId)                       |{consumerId}                           |                |                                  |\r
+|           | a Topic           |                                         |                                       |    DELETE      |                                  |\r
++-----------+-------------------+-----------------------------------------+---------------------------------------+----------------+----------------------------------+\r