forked from SolaceLabs/solace-ai-connector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.yaml
68 lines (63 loc) · 2.13 KB
/
config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
---
# Simple loopback flow
# Solace -> Pass Through -> Solace
# Make sure to have all the ${} environment variables set
log:
stdout_log_level: DEBUG
log_file_level: DEBUG
log_file: solace_ai_connector.log
shared_config:
- broker_config: &broker_connection
broker_type: solace
broker_url: ${SOLACE_BROKER_URL}
broker_username: ${SOLACE_BROKER_USERNAME}
broker_password: ${SOLACE_BROKER_PASSWORD}
broker_vpn: ${SOLACE_BROKER_VPN}
# List of flows
flows:
- name: test_flow
trace_level: DEBUG
components:
# Input from a Solace broker
- component_name: solace_sw_broker
component_module: broker_input
component_config:
<<: *broker_connection
broker_queue_name: my_queue
broker_subscriptions:
- topic: my/topic1
qos: 1
payload_encoding: utf-8
payload_format: text
- component_name: pass_through
component_module: pass_through
component_config:
input_transforms:
- type: copy
source_expression: input.payload
dest_expression: user_data.temp:text
input_selection:
source_expression: user_data.temp:text
- component_name: solace_sw_broker
component_module: broker_output
component_config:
<<: *broker_connection
payload_format: json
input_transforms:
- type: copy
source_expression: input.payload
dest_expression: user_data.output:payload.original_payload
- type: copy
source_expression: input.user_properties
dest_expression: user_data.output:payload.user_properties
- type: copy
source_expression: input.topic
dest_expression: user_data.output:payload.topic
- type: copy
source_expression: template:response/{{input.topic}}
dest_expression: user_data.output:topic
- type: copy
source_expression: user_data.temp
dest_expression: user_data.output:user_properties
input_selection:
source_expression: user_data.output