-
Notifications
You must be signed in to change notification settings - Fork 214
/
concierge.conf
168 lines (144 loc) · 4.72 KB
/
concierge.conf
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
ditto {
service-name = "concierge"
mapping-strategy.implementation = "org.eclipse.ditto.concierge.service.ConciergeMappingStrategies"
mapping-strategy.implementation = ${?MAPPING_STRATEGY_IMPLEMENTATION}
concierge {
caches {
# configuration for retrieval of policies/things during cache update via sharding
ask-with-retry {
# maximum duration to wait for answers from entity shard regions
ask-timeout = 3s
ask-timeout = ${?CONCIERGE_CACHES_ASK_TIMEOUT}
# one of: OFF, NO_DELAY, FIXED_DELAY, BACKOFF_DELAY
retry-strategy = BACKOFF_DELAY
retry-strategy = ${?CONCIERGE_CACHES_ASK_RETRY_STRATEGY}
retry-attempts = 3
retry-attempts = ${?CONCIERGE_CACHES_ASK_TIMEOUT_RETRIES}
fixed-delay = 5s
fixed-delay = ${?CONCIERGE_CACHES_ASK_FIXED_DELAY}
backoff-delay {
min = 100ms
max = 10s
# must be between 0.0 and 1.0:
random-factor = 0.5
}
}
id {
# how many relations to cache
maximum-size = 80000
maximum-size = ${?AUTHORIZATION_ID_CACHE_SIZE}
# maximum duration of inconsistency after losing a cache invalidation
expire-after-write = 1h
expire-after-write = ${?EXPIRE_AFTER_WRITE_ID_CACHE}
# prolonged on each cache access by that duration
expire-after-access = 15m
expire-after-access = ${?EXPIRE_AFTER_ACCESS_ID_CACHE}
}
enforcer {
# how many enforcers to cache
maximum-size = 20000
maximum-size = ${?AUTHORIZATION_ENFORCER_CACHE_SIZE}
# maximum duration of inconsistency after losing a cache invalidation
expire-after-write = 1h
expire-after-write = ${?EXPIRE_AFTER_WRITE_ENFORCER_CACHE}
# prolonged on each cache access by that duration
expire-after-access = 15m
expire-after-access = ${?EXPIRE_AFTER_ACCESS_ENFORCER_CACHE}
}
}
things-aggregator {
single-retrieve-thing-timeout = 30s
single-retrieve-thing-timeout = ${?THINGS_AGGREGATOR_SINGLE_RETRIEVE_THING_TIMEOUT}
max-parallelism = 20
max-parallelism = ${?THINGS_AGGREGATOR_MAX_PARALLELISM}
}
}
}
akka {
actor {
deployment {
/conciergeRoot/dispatcherActor/aggregator {
router = round-robin-pool
# nr-of-instances = 5
resizer {
lower-bound = 5
upper-bound = 100
messages-per-resize = 50
}
}
}
}
cluster {
sharding {
role = ${ditto.service-name}
}
roles = [
"concierge",
"blocked-namespaces-aware",
"live-signal-aware",
"acks-aware"
]
}
}
aggregator-internal-dispatcher {
# Dispatcher is the name of the event-based dispatcher
type = Dispatcher
# What kind of ExecutionService to use
executor = "fork-join-executor"
# Configuration for the fork join pool
fork-join-executor {
# Min number of threads to cap factor-based parallelism number to
parallelism-min = 4
# Parallelism (threads) ... ceil(available processors * factor)
parallelism-factor = 3.0
# Max number of threads to cap factor-based parallelism number to
parallelism-max = 32
parallelism-max = ${?DEFAULT_DISPATCHER_PARALLELISM_MAX}
}
# Throughput defines the maximum number of messages to be
# processed per actor before the thread jumps to the next actor.
# Set to 1 for as fair as possible.
throughput = 5
}
cached-namespace-invalidator-dispatcher {
# one thread per actor in case the actor blocks.
type = PinnedDispatcher
executor = "thread-pool-executor"
}
blocked-namespaces-dispatcher {
type = Dispatcher
executor = "fork-join-executor"
fork-join-executor {
# Min number of threads to cap factor-based parallelism number to
parallelism-min = 4
# Parallelism (threads) ... ceil(available processors * factor)
parallelism-factor = 3.0
# Max number of threads to cap factor-based parallelism number to
parallelism-max = 32
parallelism-max = ${?DEFAULT_DISPATCHER_PARALLELISM_MAX}
}
throughput = 5
}
thing-id-cache-dispatcher {
type = "Dispatcher"
executor = "thread-pool-executor"
thread-pool-executor {
keep-alive-time = 60s
fixed-pool-size = off
max-pool-size-max = 256
max-pool-size-max = ${?CACHE_DISPATCHER_POOL_SIZE_MAX}
max-pool-size-max = ${?THING_ID_CACHE_DISPATCHER_POOL_SIZE_MAX}
}
}
policy-enforcer-cache-dispatcher {
type = "Dispatcher"
executor = "thread-pool-executor"
thread-pool-executor {
keep-alive-time = 60s
fixed-pool-size = off
max-pool-size-max = 256
max-pool-size-max = ${?CACHE_DISPATCHER_POOL_SIZE_MAX}
max-pool-size-max = ${?POLICY_ENFORCER_CACHE_DISPATCHER_POOL_SIZE_MAX}
}
}
include "concierge-extension"