-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34 from interTwin-eu/dev-slangarita
documentation of Component, Connections and Generics
- Loading branch information
Showing
14 changed files
with
8,407 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
sidebar_position: 5 | ||
--- | ||
# Component | ||
|
||
|
||
The component subsection is used in all Elements like Kafka, OSCAR, and the Generic one. A component alters the workflow's operation by employing Apache NiFi Processors. The Processor's name, execution time and the node on which it runs (ALL or PRIMARY) must be indicated. | ||
|
||
|
||
## Time Execution | ||
|
||
Time execution in Apache NiFi refers to the duration between executions of a Processor within a workflow. This interval determines how often a Processor runs and is crucial for managing resource utilization. | ||
|
||
## Node Options | ||
|
||
When a Processor is set to run on the ALL node option, it executes on all available nodes in the NiFi cluster. This helps distribute the workload evenly, enhancing parallel processing and improving throughput. | ||
|
||
Choosing the PRIMARY node option means the Processor will run only on the designated primary node. This is useful for limiting resource use or maintaining specific configurations that shouldn’t be duplicated across nodes. | ||
|
||
|
||
|
||
``` | ||
- name: dcache | ||
endpoint: <dcache-endpoint> | ||
user: <dcache-user> | ||
password: <dcache-password> | ||
folder: <input-folder> | ||
statefile: <file-that-save-state> | ||
components: | ||
- name: GetFile | ||
seconds: 2 | ||
node: (ALL | PRIMARY) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
sidebar_position: 7 | ||
--- | ||
|
||
# Connections | ||
|
||
The Connections section defines the links between Sources and Destinations. It is declared at the same level as Source and Destination, and you have to use the identifier name of the Element to create the connection. The use of [Alterations](/docs/Alterations) does not affect the connection between the elements; the connection is made transparently. | ||
|
||
Connections play a crucial role in managing the flow of data between different elements of the workflow, ensuring the order and integrity of the data. By utilizing Connections, workflows can be designed in a modular fashion, allowing for easy modifications, such as adding or removing components, without disrupting the overall flow. | ||
|
||
``` | ||
OSCAR: | ||
- name: OSCAROutput | ||
Kafka: | ||
- name: kafkaInput | ||
connection: | ||
- from: kafkaInput | ||
to: OSCAROutput | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
sidebar_position: 8 | ||
--- | ||
|
||
# Generic Element | ||
|
||
|
||
In this document, we focus on the concept of Generic Elements within NiFi, specifically how to deploy custom workflows using already created ProcessGroup files. Understanding these elements is essential for efficiently managing and automating data flows in Apache NiFi. | ||
|
||
|
||
The generic section creates a custom workflow by providing a ProcessGroup file (.json). The purpose of this element could be Source, Destination, Alteration, or even a complete data flow. The author of the file '.json' sets the purpose of the workflow. For the use of Generic Element, it is necessary to have knowledge in creating ProcessGroups in Apache NiFi. | ||
|
||
DCNiOS creates the specified workflow in Apache NiFi using the .json file, substitutes the environment variables, and uses the same configuration characteristics as other Elements such as Connections and Components. Additionally, make the connections with other Elements. Thus, the declarative .yaml file has the following structure: | ||
|
||
- An identifier name of the Element (ProcessGrop in NiFi). It must be unique. Required. | ||
- The path of your ProcessGroup (.json file).Required. | ||
- The variables that compose the workflow (as a list). | ||
|
||
Also, a generic element can use [Alterations](/docs/Alterations) if it is connected with another element, or the subsection `component` to modify the time execution or the node execution. The user must know the names of the NiFi Processor defined in the .json. | ||
|
||
To use a Generic Element that interacts with other elements, it is necessary to use an Input or Output port with the default name. Please use only one Input and one Output. | ||
|
||
|
||
|
||
``` | ||
generic: | ||
- name: <identifier> | ||
file: <file-of-process-group> | ||
variables: | ||
key1: value1 | ||
key2: value2 | ||
components: | ||
- name: GetFile | ||
seconds: 2 | ||
node: (ALL | PRIMARY) | ||
alterations: | ||
- action: Encode | ||
Encoding: base64 | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.