Configuration component has a credential which is a text field with the following rules:
The screenshot below shows the configuration component Choose Credential stage during the integration flow design. The text field will be evaluated to check if the above conditions are met.
Afterwards, it emits a message with an object equivalent to the JSON in the configuration. So any data which is used in the flow and is repeated in multiple places can be configured (or later changed) in the single step. After that new values are used where it is needed.
Please Note: From the platform version 20.51 we deprecated the component
LOG_LEVEL
environment variable. Now you can control logging level per each step of the flow.
Configuration data should be specified as credentials of a JSON format. JSON must be valid in order for credentials to be verified (except arrays, see the Known limitations below). Credentials verification will fail otherwise.
Input data example. Consider the following example:
If the configuration component existed, you build flows of the following form:
ERP.GetPriceInfo()
-> Config.LoadConfig()
-> E-SHOP.SetPrice(price := ERPResults.Price * ConfigResults.ExchangeRate)
If one needed to change the exchange rate, that value could be edited by modifying the configuration credentials to include the new rate and then resetting the snapshot for all the price import flows. Currency rates sample:
{
"USDEUR": 0.881715,
"USDFJD": 2.115102,
"USDPLN": 3.787097,
"USDQAR": 3.641042,
"USDUAH": 30.718014,
"USDZWL": 322.355011
}
Then the currency rate can be used in any number of flows, where it is needed and then changed form the single place. That changes will affect all the flows where it is used.
The technical notes page gives some technical details about Configuration component like changelog.
The configuration component has no trigger functions. This means the component can not be selected as a first step in any integration flow.
Emit data
action emits the configuration data as a valid JSON object in a message.
The output json schema can have any complexity.
[
{
"Product Name": "Bowler Hat",
"ProductID": 858383,
"SKU": "0406654608",
"Description": {
"Colour": "Purple",
"Width": 300,
"Height": 200,
"Depth": 210,
"Weight": 0.75
},
"Price": 34.45,
"Quantity": 2
}
]
use something like:
{
"Product": [
{
"Product Name": "Bowler Hat",
"ProductID": 858383,
"SKU": "0406654608",
"Description": {
"Colour": "Purple",
"Width": 300,
"Height": 200,
"Depth": 210,
"Weight": 0.75
},
"Price": 34.45,
"Quantity": 2
}
]
}
Get your free 14-day elastic.io trial account to use this component.