This method retrieves a configuration stored in a partition.
Properties
|
Option |
Type |
Default |
Description |
|---|---|---|---|
|
|
string |
|
Name of the parameter to retrieve. Mandatory. |
|
|
string |
pricefx |
Connection name to use. If empty, the default connection is used. |
|
|
string |
|
If filled, result of the retrieval will be returned into the given header instead of the exchange body. |
|
|
string |
|
If filled, this value will be returned if the response from retrieval is null. |
Requirements
-
A defined connection (or default 'pricefx') must exist within the application connection pools.
-
The component itself is the producer, thus must be used in to routes.
Component Usage
The component is used to store/retrieve data to/from Pricefx and use them as required. Think of it as basic persistent storage.
Examples
To retrieve a value:
<route id="r1">
<from uri="direct:exportPriceAdjustments"/>
<setHeader name="nowDate"><simple>${date:now:yyyy-MM-dd'T'HH:mm:ss'.000Z'}</simple></setHeader>
<log message="Fetching advancedConfiguration key 'INTEGRATION_CPQ_PriceAdjustments_lastExportedDate' and assigning resolved value to header 'lastExportedDate'. If there will be no value or key then defaultValue 1900-01-01T00:00:00Z will be assigned"/>
<to uri="pfx-config:get?name=INTEGRATION_CPQ_PriceAdjustments_lastExportedDate&toHeader=lastExportedDate&defaultValue=1900-01-01T00:00:00Z"/>
<log message="Content of header 'lastExportedDate': ${header.lastExportedDate}"/>
<to uri="file://{{rootFolder-outbound-toCPQ}}?fileName=${header[CamelFileName]}"/>
</route>