@itentialopensource/adapter-kafkav2 0.6.2 → 0.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/README.md +37 -0
- package/package.json +1 -1
- package/refs?service=git-upload-pack +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,20 @@
|
|
|
1
1
|
|
|
2
|
+
## 0.6.4 [05-19-2023]
|
|
3
|
+
|
|
4
|
+
* added support for separate topics files per adapter
|
|
5
|
+
|
|
6
|
+
See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!5
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## 0.6.3 [05-19-2023]
|
|
11
|
+
|
|
12
|
+
* added support for separate topics files per adapter
|
|
13
|
+
|
|
14
|
+
See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!5
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
2
18
|
## 0.6.2 [05-16-2023]
|
|
3
19
|
|
|
4
20
|
* added support for separate topics files per adapter
|
package/README.md
CHANGED
|
@@ -212,6 +212,31 @@ Example of adapter's configuration with multiple paritions and subscribers per t
|
|
|
212
212
|
```
|
|
213
213
|
Note that if no parition is supplied only messages on partition 0 will be consumed. Additionally, if no rabbit topic is supplied, events will be published to a topic with the same name as the Kafka topic. For example, topic `test-6` above will be published to the `test-6` rabbit topic.
|
|
214
214
|
|
|
215
|
+
Example of adapter configuration to pass partitions array for one subscriber:
|
|
216
|
+
|
|
217
|
+
Note that you can pass multiple partitions to be consumed under the same subscriber. See example below -
|
|
218
|
+
|
|
219
|
+
```json
|
|
220
|
+
"topics": [
|
|
221
|
+
{
|
|
222
|
+
"name": "test_topic",
|
|
223
|
+
"always": true,
|
|
224
|
+
"partitions": [
|
|
225
|
+
1,
|
|
226
|
+
2
|
|
227
|
+
],
|
|
228
|
+
"subscriberInfo": [
|
|
229
|
+
{
|
|
230
|
+
"subname": "default",
|
|
231
|
+
"filters": [],
|
|
232
|
+
"rabbit": "test_topic",
|
|
233
|
+
"throttle": {}
|
|
234
|
+
}
|
|
235
|
+
]
|
|
236
|
+
}
|
|
237
|
+
]
|
|
238
|
+
```
|
|
239
|
+
|
|
215
240
|
### Connection Properties
|
|
216
241
|
|
|
217
242
|
These base properties are used to connect to Kafka upon the adapter initially coming up. It is important to set these properties appropriately.
|
|
@@ -282,6 +307,18 @@ The `parseMessage` property allows the user to define how they want the Kafka me
|
|
|
282
307
|
|
|
283
308
|
`iap_apps_check_interval` (default 30000ms - 30s) allows the user to set the frequency in which to run IAP app healtcheck.
|
|
284
309
|
|
|
310
|
+
## Send message sample payload
|
|
311
|
+
|
|
312
|
+
```json
|
|
313
|
+
{
|
|
314
|
+
topic: 'topic-name',
|
|
315
|
+
messages: [
|
|
316
|
+
{ key: 'key1', value: 'hello world' },
|
|
317
|
+
{ key: 'key2', value: 'hey hey!' }
|
|
318
|
+
],
|
|
319
|
+
}
|
|
320
|
+
```
|
|
321
|
+
|
|
285
322
|
## Testing an Itential Product Adapter
|
|
286
323
|
|
|
287
324
|
Mocha is generally used to test all Itential Product Adapters. There are unit tests as well as integration tests performed. Integration tests can generally be run as standalone using mock data and running the adapter in stub mode, or as integrated. When running integrated, every effort is made to prevent environmental failures, however there is still a possibility.
|
package/package.json
CHANGED
|
Binary file
|