You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix minor documentation issues and deprecate GitHub pages (#264)
* Status code 415 is not documented (#203)
Adds documention of HTTP status code 415.
* Status code 415 added to table of codes
* Available status codes fixed in swagger
* Status code 415 is not documented (#203)
Adds documention of HTTP status code 415.
* Status code 415 added to table of codes
* Available status codes fixed in swagger
* Available status codes fixed in swagger
* Available status codes fixed in swagger
* Available status codes fixed in swagger
* Available status codes fixed in swagger
CHANGELOG.md modified to reflect version number.
* Documentation cleanup and reformatting
REMReM Publish is a microservice allowing sending of messages to a topic based exchange on a RabbitMQ Server. It has endpoints that must be called as a relative links. Further documentation is provided at the following link: [https://eiffel-community.github.io/eiffel-remrem-publish](https://eiffel-community.github.io/eiffel-remrem-publish)
27
+
REMReM Publish is a microservice allowing sending of messages to a topic based exchange on a RabbitMQ Server. It has endpoints that must be called as a relative links.
28
28
29
29
# About this repository
30
30
The contents of this repository are licensed under the [Apache License 2.0](./LICENSE).
| /producer/msg | POST | mp - message protocol, required msgType - message type, required ud - user domain, not required tag - not required rk - routing key, not required | { "meta": { # Matches the meta object }, "data": { # Matches the data object }, "links": { # Matches the links object } } | This endpoint is used to publish already generated Eiffel event to message bus. **Note:** This endpoint will not validate the message. It will check only if the message contains eventId and eventType. |
211
-
| /generateAndPublish | POST | mp - message protocol, required ud - user domain, not required tag - not required rk - routing key, not required failIfMultipleFound - default: false, failIfNoneFound - default: false, lookupInExternalERs - default: false, lookupLimit - default: 1| { "msgParams": { "meta": { # Matches the meta object } }, "eventParams": { "data": { # Matches the data object }, "links": { # Matches the links object } } } | This endpoint is used to generate and publish Eiffel events to message bus. It provides single endpoint for both REMReM Generate and REMReM Publish. The service works on the relative link /generateAndPublish if run as standalone application or /publish/generateAndPublish if run as tomcat app. |
212
-
| /versions | GET ||| This endpoint is used to get versions of publish service and all loaded protocols. |
213
-
214
-
**generateAndPublish endpoint is provided with four options for Lookups:**
| failIfMultipleFound: | False | If value is set to True and multiple event ids are found through any of the provided lookup definitions, then no event will be generated. |
219
-
| failIfNoneFound: | False | If value is set to True and no event id is found through (at least one of) the provided lookup definitions, then no event will be generated. |
220
-
| lookupInExternalERs: | False | If value is set to True then REMReM will query external ERs and not just the locally used ER. The reason for the default value to be False is to decrease the load on external ERs. Here local ER means Single ER which is using REMReM generate. External ER means multiple ER's which are configured in Local ER.|
221
-
| lookupLimit: | 1 | The number of events returned, through any lookup definition given, is limited to this number. |
208
+
### `/versions`
209
+
This endpoint is used to get versions of publish service and all loaded protocols.
210
+
211
+
##### HTTP Method
212
+
GET
213
+
214
+
### `/producer/msg`
215
+
This endpoint is used to publish already generated Eiffel event to message bus.
216
+
217
+
Note: This endpoint will not validate the message. It will check only if the message contains eventId and eventType.
218
+
219
+
##### HTTP Method
220
+
POST
221
+
222
+
##### Parameters
223
+
224
+
| Name | Description | Required |
225
+
|------|-------------|----------|
226
+
|`mp`| message protocol | yes |
227
+
|`msgType`| message type | yes |
228
+
|`ud`| user domain | no |
229
+
|`tag`|| no |
230
+
|`rk`| routing key | no|
231
+
232
+
##### Request
233
+
```
234
+
{
235
+
"meta": {
236
+
# Matches the meta object
237
+
},
238
+
"data": {
239
+
# Matches the data object
240
+
},
241
+
"links": {
242
+
# Matches the links object
243
+
}
244
+
}
245
+
```
246
+
247
+
### `/generateAndPublish`
248
+
This endpoint is used to generate and publish Eiffel events to message bus.
249
+
It provides single endpoint for both REMReM Generate and REMReM Publish.
250
+
The service works on the relative link `/generateAndPublish` if run as standalone
251
+
application or `/publish/generateAndPublish` if run as Tomcat app.
|`failIfMultipleFound`| If value is set to `truea and multiple event ids are found through any of the provided lookup definitions, then no event will be generated .| no |`false`|
264
+
|`failIfNoneFound`| If value is set to `true` and no event id is found through (at least one of) the provided lookup definitions, then no event will be generated .| no |`false`|
265
+
|`lookupInExternalERs`| If value is set to True then REMReM will query external ERs and not just the locally used ER. The reason for the default value to be `false` is to decrease the load on external ERs. Here local ER means single ER which is using REMReM generate. External ER means multiple ER's which are configured in local ER. | no |`false`|
266
+
|`lookupLimit`| The number of events returned, through any lookup definition given, is limited to this number. | no |`1`|
267
+
268
+
##### Request
269
+
```
270
+
{
271
+
"msgParams": {
272
+
"meta": {
273
+
# Matches the meta object
274
+
}
275
+
},
276
+
"eventParams": {
277
+
"data": {
278
+
# Matches the data object
279
+
},
280
+
"links": {
281
+
# Matches the links object
282
+
}
283
+
}
284
+
}
285
+
```
222
286
223
287
## Examples
224
288
@@ -311,7 +375,7 @@ Result:
311
375
{"timestamp":"Dec 2, 2021 7:44:31 PM","status":400,"error":"Bad Request","message":"Could not read JSON: ..."}
312
376
```
313
377
314
-
### Examples for /generateAndPublish endpoint
378
+
### Examples for ``/generateAndPublish`` endpoint
315
379
316
380
**Correct message:**
317
381
@@ -349,7 +413,7 @@ Result:
349
413
{"result":"error","message":"Unknown event type requested..."}
350
414
```
351
415
352
-
### Examples for `/versions` endpoint
416
+
### Examples for ``/versions`` endpoint
353
417
354
418
```
355
419
curl -H "Content-Type: application/json" -X GET http://localhost:8080/generate/versions
0 commit comments