@itentialopensource/adapter-kafkav2 0.16.8 → 0.17.0

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/AUTH.md ADDED
@@ -0,0 +1,26 @@
1
+ ## Authenticating Kafka Adapter
2
+
3
+ This document will go through the steps for authenticating the Kafkav2 adapter with. Properly configuring the properties for an adapter in IAP is critical for getting the adapter online. You can read more about adapter authentication <a href="https://docs.itential.com/opensource/docs/authentication" target="_blank">HERE</a>.
4
+
5
+ ### Database Library Authentication
6
+ The Kafka adapter supports SASL Authentication for Kafka server. If you change authentication methods, you should change this section accordingly and merge it back into the adapter repository.
7
+
8
+ STEPS
9
+ 1. Ensure you have access to a Kafka server and that it is running
10
+ 2. Follow the steps in the README.md to import the adapter into IAP if you have not already done so
11
+ 3. Use the properties below for the ```properties.client.sasl``` field
12
+ ```json
13
+ "sasl": {
14
+ "mechanism": "PLAIN",
15
+ "username": "foo",
16
+ "password": "bar"
17
+ }
18
+
19
+ ```
20
+ For more details on sasl authentication follow the CONFIGURATION.md
21
+ 4. Restart the adapter. If your properties were set correctly, the adapter should go online.
22
+
23
+ ### Troubleshooting
24
+ - Make sure you copied over the correct username and password.
25
+ - Turn on debug level logs for the adapter in IAP Admin Essentials.
26
+ - Investigate the logs
package/CHANGELOG.md CHANGED
@@ -1,4 +1,12 @@
1
1
 
2
+ ## 0.17.0 [01-08-2024]
3
+
4
+ * Migration changes
5
+
6
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!18
7
+
8
+ ---
9
+
2
10
  ## 0.16.8 [12-10-2023]
3
11
 
4
12
  * Fix bug to check allowed partition
@@ -8,19 +8,19 @@ In the interest of fostering an open and welcoming environment, we as contributo
8
8
 
9
9
  Examples of behavior that contributes to creating a positive environment include:
10
10
 
11
- * Using welcoming and inclusive language
12
- * Being respectful of differing viewpoints and experiences
13
- * Gracefully accepting constructive criticism
14
- * Focusing on what is best for the community
15
- * Showing empathy towards other community members
11
+ - Using welcoming and inclusive language
12
+ - Being respectful of differing viewpoints and experiences
13
+ - Gracefully accepting constructive criticism
14
+ - Focusing on what is best for the community
15
+ - Showing empathy towards other community members
16
16
 
17
17
  Examples of unacceptable behavior by participants include:
18
18
 
19
- * The use of sexualized language or imagery and unwelcome sexual attention or advances
20
- * Trolling, insulting/derogatory comments, and personal or political attacks
21
- * Public or private harassment
22
- * Publishing others' private information, such as a physical or electronic address, without explicit permission
23
- * Other conduct which could reasonably be considered inappropriate in a professional setting
19
+ - The use of sexualized language or imagery and unwelcome sexual attention or advances
20
+ - Trolling, insulting/derogatory comments, and personal or political attacks
21
+ - Public or private harassment
22
+ - Publishing others' private information, such as a physical or electronic address, without explicit permission
23
+ - Other conduct which could reasonably be considered inappropriate in a professional setting
24
24
 
25
25
  ## Our Responsibilities
26
26
 
@@ -34,15 +34,10 @@ This Code of Conduct applies both within project spaces and in public spaces whe
34
34
 
35
35
  ## Enforcement
36
36
 
37
- Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [support@itential.com](mailto:support@itential.com). All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
37
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at support@itential.com. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38
38
 
39
39
  Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40
40
 
41
41
  ## Attribution
42
42
 
43
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
44
-
45
- [homepage]: http://contributor-covenant.org
46
- [version]: http://contributor-covenant.org/version/1/4/
47
-
48
- _return to [README](../README.md)_
43
+ This Code of Conduct is adapted from the <a href="http://contributor-covenant.org" target="_blank">Contributor Covenant</a>, version 1.4, available at <a href="http://contributor-covenant.org/version/1/4/" target="_blank">version</a>
package/CONTRIBUTING.md CHANGED
@@ -1,158 +1,13 @@
1
1
  # Contributing
2
2
 
3
- :+1: :tada: First off, thanks for taking the time to contribute! :tada: :+1:
3
+ First off, thanks for taking the time to contribute!
4
4
 
5
5
  The following is a set of rules for contributing.
6
6
 
7
- ## Table Of Contents
8
-
9
- [Code of Conduct](#code-of-conduct)
10
-
11
- [How Can I Contribute?](#how-can-i-contribute)
12
-
13
- * [Reporting Bugs](#reporting-bugs)
14
- * [Your First Code Contribution](#your-first-code-contribution)
15
- * [Merge Requests](#merge-requests)
16
-
17
- [Styleguides](#styleguides)
18
-
19
- * [Git Commit Messages](#git-commit-messages)
20
- * [JavaScript Styleguide](#javascript-styleguide)
21
- * [Tests Styleguide](#tests-styleguide)
22
- * [Documentation Styleguide](#documentation-styleguide)
23
-
24
7
  ## Code of Conduct
25
8
 
26
- This project and everyone participating in it is governed by the [Code of Conduct](./CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code. Please report unacceptable behavior to [support@itential.com](mailto:support@itential.com).
9
+ This project and everyone participating in it is governed by the Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior to support@itential.com.
27
10
 
28
11
  ## How to Contribute
29
12
 
30
- ### Reporting Bugs
31
-
32
- This section guides you through submitting a bug report. Following these guidelines helps maintainers understand your report :pencil:, reproduce the behavior :computer: :left_right_arrow: :computer:, and find related reports :mag_right:.
33
-
34
- Before creating bug reports, please check [this list](#before-submitting-a-bug-report) as you might find out that you don't need to create one. When you are creating a bug report, please [include as many details as possible](#how-do-i-submit-a-good-bug-report). If you have an Itential support contract, please create an Itential Service Desk ticket. If you don't have an Itential support contract, please send an email of the issue to [support@itential.com](mailto:support@itential.com).
35
-
36
- #### Before Submitting A Bug Report
37
-
38
- * **Check the [User Guide](README.md).** You might be able to find the cause of the problem and fix things yourself. Most importantly, check if you can reproduce the problem __in the latest version__.
39
- * **Work through the troubleshooting process.** Troubleshooting will include changing the log level of Itential Automation Platform (IAP) and adapters and checking the logs to see what the issues are. These logs should be included in any ticket you open for this issue.
40
- * **Check for resolutions to the issue.** Check the [Itential Knowledge Base](https://itential.atlassian.net/servicedesk/customer/kb/view/286883841?applicationId=605994d2-2cb2-3174-af59-ed5b23ff5fd5&spaceKey=PKB&src=1187380921) to see if there is a known resolution for the issue you are having.
41
- * **Ask around in chat if you are an Itential employee** to see if others are experiencing the same issue.
42
-
43
- #### How to Submit a (Good) Bug Report
44
-
45
- Bugs are tracked through the Itential Service Desk. Explain the problem and include additional details to help maintainers reproduce the problem:
46
-
47
- * **Use a clear and descriptive title** for the issue to identify the problem.
48
- * **Describe the exact steps which reproduce the problem** in as much detail as possible. For example, start by explaining how you configured the adapter (e.g., which properties you used and how they were set) or how you are using an artifact.
49
- * **Provide specific examples to demonstrate the steps**. Include logs, or copy/paste snippets, in your examples.
50
- * **Describe the behavior you observed after following the steps** and point out what exactly is the problem with that behavior.
51
- * **Explain which behavior you expected to see instead and why.**
52
- * **Include screenshots and animated GIFs** which show you following the described steps and clearly demonstrate the problem. You can use [this tool](https://www.cockos.com/licecap/) to record GIFs on macOS and Windows. Use [this tool](https://github.com/colinkeenan/silentcast) or [program](https://github.com/rhcarvalho/byzanz-guiz) on Linux.
53
- * **If the problem wasn't triggered by a specific action**, describe what you were doing before the problem happened and share more information using the guidelines below.
54
-
55
- Provide more context by answering these questions:
56
-
57
- * **Did the problem start happening recently** (e.g. after updating to a new version/tag) or was this always a problem?
58
- * If the problem started happening recently, **can you reproduce the problem in an older version/tag?** What's the most recent version in which the problem does not happen?
59
- * **Can you reliably reproduce the issue?** If not, provide details about how often the problem happens and under which conditions it normally happens.
60
-
61
- Include details about your configuration and environment:
62
-
63
- * **Which version of the adapter/artifact are you using?** You can get the exact version by checking the project version in the package.json file.
64
- * **What's the name and version of the OS you're using**?
65
- * **Are you running or using IAP in a virtual machine?** If so, which VM software are you using and which operating systems and versions are used for the host and guest?
66
- * **Are there firewalls between IAP and any other system you are integrating with?** If so, have you tried running curl from the system IAP is on to the other system to verify you have connectivity between the systems?
67
-
68
- ### Your First Code Contribution
69
-
70
- #### Local development
71
-
72
- This project can be developed locally on all operating systems. For instructions on how to do this, follow the steps highlighted in the [User Guide](README.md). The [User Guide](README.md)provides many more details on cloning the repository for local development, how to lint and test your changes.
73
-
74
- #### Development Process
75
-
76
- The following provides a local copy of the repository along with dependencies.
77
-
78
- ```json
79
- go to the repository you are interested in working on
80
- click on the Clone button to get the link(s) you can use to clone the repository
81
- git clone <link to clone the project>
82
- npm install
83
- ```
84
-
85
- Prior to making changes you should create a branch to work in. The branch should be named with the type of change (major, minor or patch) and then a Jira issue number or a description of the issue.
86
-
87
- ```json
88
- git checkout -b <name_of_your_new_branch>
89
- ```
90
-
91
- Make all of the desired changes.
92
-
93
- > **Note:** All code changes should be accompanied by additional Unit and Integration tests to minimize the likelihood that any changes will negatively impact the adapter/artifact as well as to ensure the desired functionality is achieved.
94
-
95
- | Files | Changes |
96
- | ------- | ------- |
97
- | .codeclimate.yml, .eslintignore, .eslintrc.js, .gitignore, .gitlab-ci.yml, .jshintrc, .npmignore | These are foundational files that are used in linting and building of the adapter. Changes to these files are heavily scrutinized and may be implemented in a different manner so that the changes can be implemented across all adapters.|
98
- | CODE_OF_CONDUCT.md, CONTRIBUTING.md, LICENSE, README.md | These are license and process files for the repository. Changes to these files may require legal review and may also be implemented in a different manner so that the changes can be implemented across all adapters.|
99
- | utils/*, adapterBase.js | Changes to these files will rarely be accepted. These are process files that need to be changed through the builder process and migration.|
100
- | adapter.js | Changes to this file are code changes. They should be accompanied by the appropriate unit and integration tests. If new methods are added, they should also be added to the pronghorn.json file, otherwise integration tests are likely to fail.|
101
- | error.json, propertiesSchema.json | These files are utilized by the Itential Runtime libraries. You can make changes to these files, but the changes should be appending of new errors or properties. Removal of errors and properties can result in rejection of the changes.|
102
- | pacakge.json, package-lock.json | The package-lock.json is automatically generated and should only be updated when the dependencies inside of the package.json are modified. You can make changes to the package.json to add additional scripts, add new dependencies, modify names, etc. However, changing the scripts or dependencies that are Itential specific will be overriden during the acceptance process.|
103
- | pronghorn.json | Changes to this file are made for integration into IAP. The most common change here is adding new methods that shoud be exposed to the IAP Workflow.|
104
- | entities/* | Changes to these files include adding new capabilities, updating existing capabilities, or removing deprecated capabilities in the adapter. Translation configuration can also be modified here.|
105
- | test/* | Changes to these files include adding, updating, or removing unit and integration tests in the adapter. Tests should never be removed unless the methods that are being tested are removed also. Both the unit and integration test file should have a marker that identifies where modification can take place. Modifications above that marker are likely to be rejected or implemented in a different manner.|
106
-
107
- > **Note:** It is a best practice to lint and test your code prior to committing changes into the repository. You can lint your code by running **npm run lint** and test it by running **node utils/testRunner.sh**. However, there are pre-commit hooks that will run these scripts when you commit your changes.
108
-
109
- Commit the changes to the repository.
110
-
111
- ```json
112
- git commit -a -m "<descriptive message>"
113
- ```
114
-
115
- > **Note:** There are pre-commit hooks in place. If the pre-commit hooks fail, you will need to address those issues before moving forward.
116
-
117
- Push the changes into the repository. This should only be done after the commit has successfully completed.
118
-
119
- ```json
120
- git push origin <name_of_your_new_branch>
121
- ```
122
-
123
- Create a [Merge Request](#merge-request).
124
-
125
- ### Merge Requests
126
-
127
- * Fill out the provided merge request template.
128
- * Reference related issues and merge requests liberally.
129
- * Include screenshots and animated GIFs in your merge request whenever possible.
130
- * Follow the project [Styleguide](#styleguides).
131
- * End all files with a newline.
132
-
133
- ## Styleguide
134
-
135
- ### Git Commit Messages
136
-
137
- * Use the present tense ("Add feature" not "Added feature")
138
- * Use the imperative mood ("Move cursor to..." not "Moves cursor to...")
139
- * Consider starting the commit message with an applicable emoji _(not required)_:
140
- * :art: `:art:` When improving the format/structure of the code.
141
- * :racehorse: `:racehorse:` When improving performance
142
- * :non-potable_water: `:non-potable_water:` When plugging memory leaks.
143
- * :memo: `:memo:` When writing documentation.
144
- * :penguin: `:penguin:` When fixing something on Linux.
145
- * :apple: `:apple:` When fixing something on macOS.
146
- * :checkered_flag: `:checkered_flag:` When fixing something on Windows.
147
- * :bug: `:bug:` When fixing a bug.
148
- * :fire: `:fire:` When removing code or files.
149
- * :green_heart: `:green_heart:` When fixing the CI build.
150
- * :white_check_mark: `:white_check_mark:` When adding tests,
151
- * :lock: `:lock:` When dealing with security.
152
- * :arrow_up: `:arrow_up:` When upgrading dependencies.
153
- * :arrow_down: `:arrow_down:` When downgrading dependencies.
154
- * :shirt: `:shirt:` When removing linter warnings.
155
-
156
- __Avoid installing unnecessary packages.__ Do not install packages just because they might be "nice to have". Itential Opensource projects are supposed to be minimal, specific, and compact by design.
157
-
158
- _return to [README](./README.md)_
13
+ Follow the contributing guide (here)[https://gitlab.com/itentialopensource/adapters/contributing-guide]
package/ENHANCE.md ADDED
@@ -0,0 +1,69 @@
1
+ ## Enhancements
2
+
3
+ ### Adding a Second Instance of an Adapter
4
+
5
+ You can add a second instance of this adapter without adding new code on the file system. To do this go into the IAP Admin Essentials and add a new service config for this adapter. The two instances of the adapter should have unique ids. In addition, they should point to different instances (unique host and port) of the other system.
6
+
7
+ ### Adding Adapter Calls
8
+
9
+ There are multiple ways to add calls to an existing adapter.
10
+
11
+ The easiest way would be to use the Adapter Builder update process. This process takes in a Swagger or OpenAPI document, allows you to select the calls you want to add and then generates a zip file that can be used to update the adapter. Once you have the zip file simply put it in the adapter directory and execute `npm run adapter:update`.
12
+
13
+ ```bash
14
+ mv updatePackage.zip adapter-kafka
15
+ cd adapter-kafka
16
+ npm run adapter:update
17
+ ```
18
+
19
+ If you do not have a Swagger or OpenAPI document, you can use a Postman Collection and convert that to an OpenAPI document using APIMatic and then follow the first process.
20
+
21
+ If you want to manually update the adapter that can also be done the key thing is to make sure you update all of the right files. Within the entities directory you will find 1 or more entities. You can create a new entity or add to an existing entity. Each entity has an action.json file, any new call will need to be put in the action.json file. It will also need to be added to the enum for the ph_request_type in the appropriate schema files. Once this configuration is complete you will need to add the call to the adapter.js file and, in order to make it available as a workflow task in IAP, it should also be added to the pronghorn.json file. You can optionally add it to the unit and integration test files. There is more information on how to work on each of these files in the <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a> on our Documentation Site.
22
+
23
+ ```text
24
+ Files to update
25
+ * entities/<entity>/action.json: add an action
26
+ * entities/<entity>/schema.json (or the schema defined on the action): add action to the enum for ph_request_type
27
+ * adapter.js: add the new method and make sure it calls the proper entity and action
28
+ * pronghorn.json: add the new method
29
+ * test/unit/adapterTestUnit.js (optional but best practice): add unit test(s) - function is there, any required parameters error when not passed in
30
+ * test/integration/adapterTestIntegration.js (optional but best practice): add integration test
31
+ ```
32
+
33
+ ### Adding Adapter Properties
34
+
35
+ While changing adapter properties is done in the service instance configuration section of IAP, adding properties has to be done in the adapter. To add a property you should edit the propertiesSchema.json with the proper information for the property. In addition, you should modify the sampleProperties to have the new property in it.
36
+
37
+ ```text
38
+ Files to update
39
+ * propertiesSchema.json: add the new property and how it is defined
40
+ * sampleProperties: add the new property with a default value
41
+ * test/unit/adapterTestUnit.js (optional but best practice): add the property to the global properties
42
+ * test/integration/adapterTestIntegration.js (optional but best practice): add the property to the global properties
43
+ ```
44
+
45
+ ### Changing Adapter Authentication
46
+
47
+ Often an adapter is built before knowing the authentication and authentication processes can also change over time. The adapter supports many different kinds of authentication but it does require configuration. Some forms of authentication can be defined entirely with the adapter properties but others require configuration.
48
+
49
+ ```text
50
+ Files to update
51
+ * entities/.system/action.json: change the getToken action as needed
52
+ * entities/.system/schemaTokenReq.json: add input parameters (external name is name in other system)
53
+ * entities/.system/schemaTokenResp.json: add response parameters (external name is name in other system)
54
+ * propertiesSchema.json: add any new property and how it is defined
55
+ * sampleProperties: add any new property with a default value
56
+ * test/unit/adapterTestUnit.js (optional but best practice): add the property to the global properties
57
+ * test/integration/adapterTestIntegration.js (optional but best practice): add the property to the global properties
58
+ ```
59
+
60
+ ### Enhancing Adapter Integration Tests
61
+
62
+ The adapter integration tests are written to be able to test in either stub (standalone) mode or integrated to the other system. However, if integrating to the other system, you may need to provide better data than what the adapter provides by default as that data is likely to fail for create and update. To provide better data, edit the adapter integration test file. Make sure you do not remove the marker and keep custom code below the marker so you do not impact future migrations. Once the edits are complete, run the integration test as it instructs you to above. When you run integrated to the other system, you can also save mockdata for future use by changing the isSaveMockData flag to true.
63
+
64
+ ```text
65
+ Files to update
66
+ * test/integration/adapterTestIntegration.js: add better data for the create and update calls so that they will not fail.
67
+ ```
68
+
69
+ As mentioned previously, for most of these changes as well as other possible changes, there is more information on how to work on an adapter in the <a href="https://docs.itential.com/opensource/docs/adapters" target="_blank">Adapter Technical Resources</a> on our Documentation Site.
@@ -0,0 +1,72 @@
1
+
2
+ ## 0.16.8 [12-10-2023]
3
+
4
+ * Fix bug to check allowed partition
5
+
6
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!17
7
+
8
+ ---
9
+
10
+ ## 0.16.7 [09-27-2023]
11
+
12
+ * Big fixes logLevel and adapter restart
13
+
14
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
15
+
16
+ ---
17
+
18
+ ## 0.16.6 [09-18-2023]
19
+
20
+ * Big fixes logLevel and adapter restart
21
+
22
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
23
+
24
+ ---
25
+
26
+ ## 0.16.5 [09-08-2023]
27
+
28
+ * Big fixes logLevel and adapter restart
29
+
30
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
31
+
32
+ ---
33
+
34
+ ## 0.16.4 [09-08-2023]
35
+
36
+ * Big fixes logLevel and adapter restart
37
+
38
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
39
+
40
+ ---
41
+
42
+ ## 0.16.3 [09-05-2023]
43
+
44
+ * Big fixes logLevel and adapter restart
45
+
46
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
47
+
48
+ ---
49
+
50
+ ## 0.16.2 [08-29-2023]
51
+
52
+ * Big fixes logLevel and adapter restart
53
+
54
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!15
55
+
56
+ ---
57
+
58
+ ## 0.16.1 [08-24-2023]
59
+
60
+ * Handle empty topics file
61
+
62
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!13
63
+
64
+ ---
65
+
66
+ ## 0.16.0 [08-23-2023]
67
+
68
+ * Add logic to clean topics.json from service config
69
+
70
+ See merge request itentialopensource/adapters/notification-messaging/adapter-kafkav2!11
71
+
72
+ ---
package/error.json CHANGED
@@ -96,6 +96,12 @@
96
96
  "displayString": "Invalid properties: $VARIABLE$",
97
97
  "recommendation": "Verify the properties for the adapter"
98
98
  },
99
+ {
100
+ "key": "Missing Properties",
101
+ "icode": "AD.306",
102
+ "displayString": "Property $VARIABLE$ is required",
103
+ "recommendation": "Please provide the required property"
104
+ },
99
105
  {
100
106
  "key": "Query Not Translated",
101
107
  "icode": "AD.310",
@@ -168,6 +174,12 @@
168
174
  "displayString": "Failure response received for $VARIABLE$",
169
175
  "recommendation": "Check the reason for failure in the stack trace"
170
176
  },
177
+ {
178
+ "key": "Suspended Adapter",
179
+ "icode": "AD.600",
180
+ "displayString": "Adapter is suspended",
181
+ "recommendation": "Check if external system is functional and unsuspend if appropriate"
182
+ },
171
183
  {
172
184
  "key": "Caught Exception",
173
185
  "icode": "AD.900",
package/metadata.json ADDED
@@ -0,0 +1,71 @@
1
+ {
2
+ "name": "adapter-kafkav2",
3
+ "vendor": "kafkav2",
4
+ "product": "kafkav2",
5
+ "osVersion": [],
6
+ "apiVersions": [],
7
+ "iapVersions": [
8
+ "2021.1.x",
9
+ "2021.2.x",
10
+ "2022.1.x",
11
+ "2023.1.x"
12
+ ],
13
+ "method": "Library",
14
+ "type": "Adapter",
15
+ "domains": [],
16
+ "tags": [],
17
+ "useCases": [],
18
+ "deprecated": {
19
+ "isDeprecated": false
20
+ },
21
+ "brokerSince": "",
22
+ "documentation": {
23
+ "storeLink": "",
24
+ "npmLink": "https://www.npmjs.com/package/@itentialopensource/adapter-kafkav2",
25
+ "repoLink": "https://gitlab.com/itentialopensource/adapters/notification-messaging/adapter-kafkav2",
26
+ "docLink": "",
27
+ "demoLinks": [],
28
+ "trainingLinks": [],
29
+ "faqLink": "https://docs.itential.com/opensource/docs/troubleshooting-an-adapter",
30
+ "contributeLink": "https://gitlab.com/itentialopensource/adapters/contributing-guide",
31
+ "issueLink": "https://itential.atlassian.net/servicedesk/customer/portals",
32
+ "webLink": "",
33
+ "vendorLink": "",
34
+ "productLink": "",
35
+ "apiLinks": []
36
+ },
37
+ "assets": [],
38
+ "relatedItems": {
39
+ "adapters": [],
40
+ "integrations": [],
41
+ "ecosystemApplications": [],
42
+ "workflowProjects": [
43
+ {
44
+ "name": "Receive Message Using Kafkav2 Adapter",
45
+ "webName": "Receive Message Using Kafkav2 Adapter",
46
+ "overview": "This pre-built is configured to run by an event trigger named `Kafka Message Event Trigger` in the Operations Manager application. This event type is configured as a Kafka message from the KafkaV2 adapter. When a Kafka message is received, the trigger will start the workflow `Main Kafka Receiver`. This workflow contains two child jobs. One of the child jobs will run based on the evaluation task in the workflow. The evaluation task is configured to do the following: - If the message string value contains `workflowA`, the automation will take the success path and trigger `workflow A`- If the message string value contains `workflowB`, the automation will take the failure path and trigger `workflow B`",
47
+ "isDependency": false,
48
+ "versions": [
49
+ "0.1.2"
50
+ ],
51
+ "repoLink": "https://gitlab.com/itentialopensource/pre-built-automations/receive-message-using-kafkav2-adapter",
52
+ "docLink": "",
53
+ "webLink": "https://www.itential.com/automations/receive-message-using-kafkav2-adapter/"
54
+ },
55
+ {
56
+ "name": "Send Message With Kafkav2 Adapter",
57
+ "webName": "Send Message With Kafkav2 Adapter",
58
+ "overview": "This pre-built is designed to send a Kafka message using the Kafka v2 adapter. This automation consists of a manual trigger in Operations Manager, which uses a JSON form to allow the user to create a message under a specific topic. The output of this JSON form will be mapped to the variables required by the workflow `Kafka Message Producer` to send the Kafka message.",
59
+ "isDependency": false,
60
+ "versions": [
61
+ "0.1.2"
62
+ ],
63
+ "repoLink": "https://gitlab.com/itentialopensource/pre-built-automations/send-message-with-kafkav2-adapter",
64
+ "docLink": "",
65
+ "webLink": "https://www.itential.com/automations/send-message-with-kafkav2-adapter/"
66
+ }
67
+ ],
68
+ "transformationProjects": [],
69
+ "exampleProjects": []
70
+ }
71
+ }
package/package.json CHANGED
@@ -1,14 +1,15 @@
1
1
  {
2
2
  "name": "@itentialopensource/adapter-kafkav2",
3
- "version": "0.16.8",
3
+ "version": "0.17.0",
4
4
  "description": "Itential adapter to connect to kafka",
5
5
  "main": "adapter.js",
6
6
  "wizardVersion": "2.35.0",
7
7
  "engineVersion": "1.40.2",
8
8
  "scripts": {
9
9
  "artifactize": "npm i && node utils/packModificationScript.js",
10
- "preinstall": "node utils/setup.js && npm install --package-lock-only --ignore-scripts",
11
- "lint": "eslint . --ext .json --ext .js",
10
+ "preinstall": "node utils/setup.js",
11
+ "deinstall": "node utils/removeHooks.js",
12
+ "lint": "node --max_old_space_size=4096 ./node_modules/eslint/bin/eslint.js . --ext .json --ext .js",
12
13
  "lint:errors": "node --max_old_space_size=4096 ./node_modules/eslint/bin/eslint.js . --ext .json --ext .js --quiet",
13
14
  "test:baseunit": "mocha test/unit/adapterBaseTestUnit.js --LOG=error",
14
15
  "test:unit": "mocha test/unit/adapterTestUnit.js --LOG=error",
@@ -0,0 +1,14 @@
1
+ [
2
+ {
3
+ "type": "encryption",
4
+ "pointer": "/authentication/password"
5
+ },
6
+ {
7
+ "type": "encryption",
8
+ "pointer": "/authentication/token"
9
+ },
10
+ {
11
+ "type": "encryption",
12
+ "pointer": "/mongo/password"
13
+ }
14
+ ]
Binary file
@@ -0,0 +1,206 @@
1
+ #!/usr/bin/env node
2
+ /* @copyright Itential, LLC 2019 */
3
+ /* eslint global-require:warn */
4
+ /* eslint import/no-dynamic-require:warn */
5
+ /* eslint prefer-destructuring:warn */
6
+
7
+ const path = require('path');
8
+ const fs = require('fs-extra');
9
+
10
+ /**
11
+ * This script will determine the information about the adapter and store
12
+ * it into a file in the adapter.
13
+ */
14
+
15
+ /**
16
+ * get adapter information
17
+ */
18
+ function adapterInfo() {
19
+ // set the base pase of the adapter - tool shoud be one level up in utils
20
+ let adaptdir = __dirname;
21
+ const infoRes = {};
22
+
23
+ if (adaptdir.endsWith('/utils')) {
24
+ adaptdir = adaptdir.substring(0, adaptdir.length - 6);
25
+ }
26
+ const pack = require(`${adaptdir}/package.json`);
27
+ infoRes.version = pack.version;
28
+
29
+ let configCount = 0;
30
+ if (fs.existsSync(`${adaptdir}/pronghorn.json`)) {
31
+ const cFile = fs.readFileSync(`${adaptdir}/pronghorn.json`, 'utf8');
32
+ configCount += cFile.split('\n').length;
33
+ } else {
34
+ console.log('Missing - pronghorn.json');
35
+ }
36
+ if (fs.existsSync(`${adaptdir}/propertiesSchema.json`)) {
37
+ const cFile = fs.readFileSync(`${adaptdir}/propertiesSchema.json`, 'utf8');
38
+ configCount += cFile.split('\n').length;
39
+ } else {
40
+ console.log('Missing - propertiesSchema.json');
41
+ }
42
+ if (fs.existsSync(`${adaptdir}/error.json`)) {
43
+ const cFile = fs.readFileSync(`${adaptdir}/error.json`, 'utf8');
44
+ configCount += cFile.split('\n').length;
45
+ } else {
46
+ console.log('Missing - error.json');
47
+ }
48
+ const entitydir = path.join(adaptdir, '/entities');
49
+ if (fs.existsSync(entitydir) && fs.statSync(entitydir).isDirectory()) {
50
+ const entities = fs.readdirSync(entitydir);
51
+ // need to go through each entity in the entities directory
52
+ for (let e = 0; e < entities.length; e += 1) {
53
+ if (fs.statSync(`${entitydir}/${entities[e]}`).isDirectory()) {
54
+ const cfiles = fs.readdirSync(entitydir);
55
+ for (let c = 0; c < cfiles.length; c += 1) {
56
+ if (cfiles[c].endsWith('.json')) {
57
+ const ccFile = fs.readFileSync(`${entitydir}/${entities[e]}/${cfiles[c]}`, 'utf8');
58
+ configCount += ccFile.split('\n').length;
59
+ }
60
+ }
61
+ }
62
+ }
63
+ } else {
64
+ console.log('Could not find the entities directory');
65
+ }
66
+ infoRes.configLines = configCount;
67
+
68
+ let scodeCount = 0;
69
+ if (fs.existsSync(`${adaptdir}/utils/artifactize.js`)) {
70
+ const sFile = fs.readFileSync(`${adaptdir}/utils/artifactize.js`, 'utf8');
71
+ scodeCount += sFile.split('\n').length;
72
+ } else {
73
+ console.log('Missing - utils/artifactize.js');
74
+ }
75
+ if (fs.existsSync(`${adaptdir}/utils/basicGet.js`)) {
76
+ const sFile = fs.readFileSync(`${adaptdir}/utils/basicGet.js`, 'utf8');
77
+ scodeCount += sFile.split('\n').length;
78
+ } else {
79
+ console.log('Missing - utils/basicGet.js');
80
+ }
81
+ if (fs.existsSync(`${adaptdir}/utils/checkMigrate.js`)) {
82
+ const sFile = fs.readFileSync(`${adaptdir}/utils/checkMigrate.js`, 'utf8');
83
+ scodeCount += sFile.split('\n').length;
84
+ } else {
85
+ console.log('Missing - utils/checkMigrate.js');
86
+ }
87
+ if (fs.existsSync(`${adaptdir}/utils/findPath.js`)) {
88
+ const sFile = fs.readFileSync(`${adaptdir}/utils/findPath.js`, 'utf8');
89
+ scodeCount += sFile.split('\n').length;
90
+ } else {
91
+ console.log('Missing - utils/findPath.js');
92
+ }
93
+ if (fs.existsSync(`${adaptdir}/utils/modify.js`)) {
94
+ const sFile = fs.readFileSync(`${adaptdir}/utils/modify.js`, 'utf8');
95
+ scodeCount += sFile.split('\n').length;
96
+ } else {
97
+ console.log('Missing - utils/modify.js');
98
+ }
99
+ if (fs.existsSync(`${adaptdir}/utils/packModificationScript.js`)) {
100
+ const sFile = fs.readFileSync(`${adaptdir}/utils/packModificationScript.js`, 'utf8');
101
+ scodeCount += sFile.split('\n').length;
102
+ } else {
103
+ console.log('Missing - utils/packModificationScript.js');
104
+ }
105
+ if (fs.existsSync(`${adaptdir}/utils/setup.js`)) {
106
+ const sFile = fs.readFileSync(`${adaptdir}/utils/setup.js`, 'utf8');
107
+ scodeCount += sFile.split('\n').length;
108
+ } else {
109
+ console.log('Missing - utils/setup.js');
110
+ }
111
+ if (fs.existsSync(`${adaptdir}/utils/tbScript.js`)) {
112
+ const sFile = fs.readFileSync(`${adaptdir}/utils/tbScript.js`, 'utf8');
113
+ scodeCount += sFile.split('\n').length;
114
+ } else {
115
+ console.log('Missing - utils/tbScript.js');
116
+ }
117
+ if (fs.existsSync(`${adaptdir}/utils/tbUtils.js`)) {
118
+ const sFile = fs.readFileSync(`${adaptdir}/utils/tbUtils.js`, 'utf8');
119
+ scodeCount += sFile.split('\n').length;
120
+ } else {
121
+ console.log('Missing - utils/tbUtils.js');
122
+ }
123
+ if (fs.existsSync(`${adaptdir}/utils/testRunner.js`)) {
124
+ const sFile = fs.readFileSync(`${adaptdir}/utils/testRunner.js`, 'utf8');
125
+ scodeCount += sFile.split('\n').length;
126
+ } else {
127
+ console.log('Missing - utils/testRunner.js');
128
+ }
129
+ if (fs.existsSync(`${adaptdir}/utils/troubleshootingAdapter.js`)) {
130
+ const sFile = fs.readFileSync(`${adaptdir}/utils/troubleshootingAdapter.js`, 'utf8');
131
+ scodeCount += sFile.split('\n').length;
132
+ } else {
133
+ console.log('Missing - utils/troubleshootingAdapter.js');
134
+ }
135
+ infoRes.scriptLines = scodeCount;
136
+
137
+ let codeCount = 0;
138
+ if (fs.existsSync(`${adaptdir}/adapter.js`)) {
139
+ const aFile = fs.readFileSync(`${adaptdir}/adapter.js`, 'utf8');
140
+ codeCount += aFile.split('\n').length;
141
+ } else {
142
+ console.log('Missing - utils/adapter.js');
143
+ }
144
+ if (fs.existsSync(`${adaptdir}/adapterBase.js`)) {
145
+ const aFile = fs.readFileSync(`${adaptdir}/adapterBase.js`, 'utf8');
146
+ codeCount += aFile.split('\n').length;
147
+ } else {
148
+ console.log('Missing - utils/adapterBase.js');
149
+ }
150
+ infoRes.codeLines = codeCount;
151
+
152
+ let tcodeCount = 0;
153
+ let ttestCount = 0;
154
+ if (fs.existsSync(`${adaptdir}/test/integration/adapterTestBasicGet.js`)) {
155
+ const tFile = fs.readFileSync(`${adaptdir}/test/integration/adapterTestBasicGet.js`, 'utf8');
156
+ tcodeCount += tFile.split('\n').length;
157
+ ttestCount += tFile.split('it(\'').length;
158
+ } else {
159
+ console.log('Missing - test/integration/adapterTestBasicGet.js');
160
+ }
161
+ if (fs.existsSync(`${adaptdir}/test/integration/adapterTestConnectivity.js`)) {
162
+ const tFile = fs.readFileSync(`${adaptdir}/test/integration/adapterTestConnectivity.js`, 'utf8');
163
+ tcodeCount += tFile.split('\n').length;
164
+ ttestCount += tFile.split('it(\'').length;
165
+ } else {
166
+ console.log('Missing - test/integration/adapterTestConnectivity.js');
167
+ }
168
+ if (fs.existsSync(`${adaptdir}/test/integration/adapterTestIntegration.js`)) {
169
+ const tFile = fs.readFileSync(`${adaptdir}/test/integration/adapterTestIntegration.js`, 'utf8');
170
+ tcodeCount += tFile.split('\n').length;
171
+ ttestCount += tFile.split('it(\'').length;
172
+ } else {
173
+ console.log('Missing - test/integration/adapterTestIntegration.js');
174
+ }
175
+ if (fs.existsSync(`${adaptdir}/test/unit/adapterBaseTestUnit.js`)) {
176
+ const tFile = fs.readFileSync(`${adaptdir}/test/unit/adapterBaseTestUnit.js`, 'utf8');
177
+ tcodeCount += tFile.split('\n').length;
178
+ ttestCount += tFile.split('it(\'').length;
179
+ } else {
180
+ console.log('Missing - test/unit/adapterBaseTestUnit.js');
181
+ }
182
+ if (fs.existsSync(`${adaptdir}/test/unit/adapterTestUnit.js`)) {
183
+ const tFile = fs.readFileSync(`${adaptdir}/test/unit/adapterTestUnit.js`, 'utf8');
184
+ tcodeCount += tFile.split('\n').length;
185
+ ttestCount += tFile.split('it(\'').length;
186
+ } else {
187
+ console.log('Missing - test/unit/adapterTestUnit.js');
188
+ }
189
+ infoRes.testLines = tcodeCount;
190
+ infoRes.testCases = ttestCount;
191
+ infoRes.totalCodeLines = scodeCount + codeCount + tcodeCount;
192
+
193
+ if (fs.existsSync(`${adaptdir}/pronghorn.json`)) {
194
+ // Read the entity schema from the file system
195
+ const phFile = path.join(adaptdir, '/pronghorn.json');
196
+ const prong = require(phFile);
197
+ infoRes.wfTasks = prong.methods.length;
198
+ } else {
199
+ console.log('Missing - pronghorn.json');
200
+ }
201
+
202
+ console.log(JSON.stringify(infoRes));
203
+ fs.writeFileSync(`${adaptdir}/report/adapterInfo.json`, JSON.stringify(infoRes, null, 2));
204
+ }
205
+
206
+ adapterInfo();
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  /* @copyright Itential, LLC 2019 */
3
3
 
4
- const fs = require('fs-extra');
5
4
  const path = require('path');
5
+ const fs = require('fs-extra');
6
6
 
7
7
  async function createBundle(adapterOldDir) {
8
8
  // set directories
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
  /* @copyright Itential, LLC 2019 */
3
3
 
4
- const fs = require('fs-extra');
5
4
  const path = require('path');
6
5
  const { spawnSync } = require('child_process');
6
+ const fs = require('fs-extra');
7
7
  const { createBundle } = require('./artifactize');
8
8
 
9
9
  const nodeEntryPath = path.resolve('.');
@@ -0,0 +1,20 @@
1
+ const fs = require('fs');
2
+
3
+ /**
4
+ * This script will uninstall pre-commit or pre-push hooks in case there's ever a need to
5
+ * commit/push something that has issues
6
+ */
7
+
8
+ const precommitPath = '.git/hooks/pre-commit';
9
+ const prepushPath = '.git/hooks/pre-push';
10
+ fs.unlink(precommitPath, (err) => {
11
+ if (err && err.code !== 'ENOENT') {
12
+ console.log(`${err.message}`);
13
+ }
14
+ });
15
+
16
+ fs.unlink(prepushPath, (err) => {
17
+ if (err && err.code !== 'ENOENT') {
18
+ console.log(`${err.message}`);
19
+ }
20
+ });
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
  /* @copyright Itential, LLC 2019 */
3
3
 
4
+ const execute = require('child_process').exec;
4
5
  const fs = require('fs-extra');
5
6
  const rl = require('readline-sync');
6
- const execute = require('child_process').exec;
7
7
 
8
8
  /**
9
9
  * This script will determine the type of integration test to run
@@ -47,11 +47,11 @@ function replaceTestVars(test) {
47
47
  let intTest = fs.readFileSync(test, 'utf8');
48
48
 
49
49
  // replace stub variable but check if it exists first
50
- let sindex = intTest.indexOf('const stub');
50
+ let sindex = intTest.indexOf('samProps.stub');
51
51
  let eindex = intTest.indexOf(';', sindex);
52
52
  let replStr = intTest.substring(sindex, eindex + 1);
53
53
  if (sindex > -1) {
54
- intTest = intTest.replace(replStr, `const stub = ${stub};`);
54
+ intTest = intTest.replace(replStr, `samProps.stub = ${stub};`);
55
55
  }
56
56
 
57
57
  // replace isRapidFail variable but check if it exists first
@@ -71,46 +71,46 @@ function replaceTestVars(test) {
71
71
  }
72
72
 
73
73
  // replace host variable
74
- sindex = intTest.indexOf('const host');
74
+ sindex = intTest.indexOf('samProps.host');
75
75
  eindex = intTest.indexOf(';', sindex);
76
76
  replStr = intTest.substring(sindex, eindex + 1);
77
- intTest = intTest.replace(replStr, `const host = '${host}';`);
77
+ intTest = intTest.replace(replStr, `samProps.host = '${host}';`);
78
78
 
79
79
  // replace username variable
80
- sindex = intTest.indexOf('const username');
80
+ sindex = intTest.indexOf('samProps.authentication.username');
81
81
  eindex = intTest.indexOf(';', sindex);
82
82
  replStr = intTest.substring(sindex, eindex + 1);
83
- intTest = intTest.replace(replStr, `const username = '${username}';`);
83
+ intTest = intTest.replace(replStr, `samProps.authentication.username = '${username}';`);
84
84
 
85
85
  // replace password variable
86
- sindex = intTest.indexOf('const password');
86
+ sindex = intTest.indexOf('samProps.authentication.password');
87
87
  eindex = intTest.indexOf(';', sindex);
88
88
  replStr = intTest.substring(sindex, eindex + 1);
89
- intTest = intTest.replace(replStr, `const password = '${password}';`);
89
+ intTest = intTest.replace(replStr, `samProps.authentication.password = '${password}';`);
90
90
 
91
91
  // replace protocol variable
92
- sindex = intTest.indexOf('const protocol');
92
+ sindex = intTest.indexOf('samProps.protocol');
93
93
  eindex = intTest.indexOf(';', sindex);
94
94
  replStr = intTest.substring(sindex, eindex + 1);
95
- intTest = intTest.replace(replStr, `const protocol = '${protocol}';`);
95
+ intTest = intTest.replace(replStr, `samProps.protocol = '${protocol}';`);
96
96
 
97
97
  // replace port variable
98
- sindex = intTest.indexOf('const port');
98
+ sindex = intTest.indexOf('samProps.port');
99
99
  eindex = intTest.indexOf(';', sindex);
100
100
  replStr = intTest.substring(sindex, eindex + 1);
101
- intTest = intTest.replace(replStr, `const port = ${port};`);
101
+ intTest = intTest.replace(replStr, `samProps.port = ${port};`);
102
102
 
103
103
  // replace sslenable variable
104
- sindex = intTest.indexOf('const sslenable');
104
+ sindex = intTest.indexOf('samProps.ssl.enabled');
105
105
  eindex = intTest.indexOf(';', sindex);
106
106
  replStr = intTest.substring(sindex, eindex + 1);
107
- intTest = intTest.replace(replStr, `const sslenable = ${sslenable};`);
107
+ intTest = intTest.replace(replStr, `samProps.ssl.enabled = ${sslenable};`);
108
108
 
109
109
  // replace sslinvalid variable
110
- sindex = intTest.indexOf('const sslinvalid');
110
+ sindex = intTest.indexOf('samProps.ssl.accept_invalid_cert');
111
111
  eindex = intTest.indexOf(';', sindex);
112
112
  replStr = intTest.substring(sindex, eindex + 1);
113
- intTest = intTest.replace(replStr, `const sslinvalid = ${sslinvalid};`);
113
+ intTest = intTest.replace(replStr, `samProps.ssl.accept_invalid_cert = ${sslinvalid};`);
114
114
 
115
115
  console.log(`Updates to ${test} complete`);
116
116
  fs.writeFileSync(test, intTest);
@@ -1 +0,0 @@
1
- {"name":"kafka_test","tasks":{"3678":{"name":"resumeConsumer","summary":"Resume the consumer","description":"Resume the consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"adapter_id":"Kafka"},"outgoing":{"result":null}},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.6906740535549399,"y":0.1601423487544484},"6409":{"name":"pauseTopics","summary":"PauseTopics the consumer","description":"PauseTopics the consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topics":["test6"],"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.16528162511542013,"y":0.12455516014234876,"scheduled":false},"9815":{"name":"resumeTopics","summary":"ResumeTopics the consumer","description":"ResumeTopics the consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topics":["test6"],"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.407202216066482,"y":0.3718861209964413,"scheduled":false},"workflow_start":{"name":"workflow_start","groups":[],"x":0,"y":0.5},"workflow_end":{"name":"workflow_end","groups":[],"x":1,"y":0.5},"e07":{"name":"createTopics","summary":"create topics on the Kafka server","description":"create topics on the Kafka server","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topics":[{"topic":"test6","partitions":1,"replicationFactor":1}],"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.15881809787626963,"y":0.5889679715302492,"scheduled":false},"c5dc":{"name":"subscribe","summary":"subscribe topics to current consumer","description":"subscribe topics to current consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topics":["test6"],"event":"event01","adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.1634349030470914,"y":0.3665480427046263,"scheduled":false},"31e1":{"name":"sendMessage","summary":"send message","description":"send message","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"payloads":[{"topic":"test6","messages":"hello world66","partitions":1}],"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.3961218836565097,"y":0.11743772241992882,"scheduled":false},"ef3c":{"name":"unsubscribe","summary":"unsubscribe topics from current consumer","description":"remove topics from current consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topics":["test6"],"event":"event01","adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.6989843028624192,"y":0.6281138790035588,"scheduled":false},"593e":{"name":"pauseConsumer","summary":"Pause the consumer","description":"Pause the consumer","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.6906740535549399,"y":0.3879003558718861,"scheduled":false},"b417":{"name":"setOffset","summary":"Set offset of the given topic","description":"Set offset of the given topic","location":"Adapter","locationType":"Kafka","app":"Kafka","displayName":"Kafka","type":"automatic","variables":{"incoming":{"topic":"test6","partition":1,"offset":1,"adapter_id":"Kafka"},"outgoing":{"result":null},"error":""},"deprecated":false,"matched":[],"groups":[],"actor":"Pronghorn","x":0.41920590951061865,"y":0.6387900355871886,"scheduled":false}},"transitions":{"3678":{"workflow_end":{"type":"standard","state":"success"}},"5982":{},"6409":{"31e1":{"type":"standard","state":"success"}},"9815":{"b417":{"type":"standard","state":"success"}},"workflow_start":{"e07":{"type":"standard","state":"success"}},"workflow_end":{},"f78a":{},"e07":{"c5dc":{"type":"standard","state":"success"}},"c5dc":{"6409":{"type":"standard","state":"success"}},"31e1":{"9815":{"type":"standard","state":"success"}},"ef3c":{"593e":{"type":"standard","state":"success"}},"2e22":{},"593e":{"3678":{"type":"standard","state":"success"}},"b417":{"ef3c":{"type":"standard","state":"success"}}},"font_size":12,"created":"2019-09-30T21:33:32.271Z","created_by":{"provenance":"Local AAA","username":"admin@pronghorn","firstname":"admin","inactive":false,"email":""},"groups":[],"last_updated":"2019-10-15T18:35:53.047Z","last_updated_by":{"provenance":"Local AAA","username":"admin@pronghorn","firstname":"admin","inactive":false,"email":""},"type":"automation","description":null}