Repository navigation
Expand file tree
/
Copy pathDeployConfig.json
More file actions
335 lines (335 loc) · 11.5 KB
/
Copy pathDeployConfig.json
File metadata and controls
335 lines (335 loc) · 11.5 KB
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
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
{
"description": "mod-orders-storage configuration template. Default values are calibrated against a reference bugfest environment (tebfcon-mod-orders-storage revision 17, image 14.0.4); see ADR-0013 (Module configuration management) for the governance model behind this file. mod-orders-storage is an RMB (Vert.x) storage module: it keeps orders data in PostgreSQL, publishes audit events to Kafka and consumes inventory and EDI export events. Resource values and JVM limits must be adjusted to the target host capacity.",
"moduleDefaults": {
"resources": [
{
"name": "cpu",
"value": "64",
"description": "CPU request/limit for the mod-orders-storage container"
},
{
"name": "memory",
"value": "1024",
"description": "Memory hard limit for the mod-orders-storage container in MiB"
},
{
"name": "memoryReservation",
"value": "896",
"description": "Memory reservation (soft limit) for the mod-orders-storage container in MiB"
}
],
"java": [
{
"name": "xmx",
"value": "700m",
"description": "Maximum Java heap size. Value taken from bugfest; with MaxMetaspaceSize it leaves under 200 MiB of the container for non-heap memory, so lower it if the container limit is reduced"
},
{
"name": "MaxMetaspaceSize",
"value": "128m",
"description": "Maximum Java metaspace size. Value taken from bugfest"
},
{
"name": "MetaspaceSize",
"value": "88m",
"description": "Threshold for the first metaspace garbage collection (not a limit). Value taken from bugfest"
}
],
"deployment": {
"isHaSupported": true,
"replicasRecommendedCount": 2,
"description": "All state is in PostgreSQL and Kafka consumers share one consumer group per event type, so replicas can run side by side; the only in-memory state is short-lived settings and consortium caches. Audit outbox processing and batch tracking cleanup are triggered by mod-scheduler."
},
"kong": {
"timeouts": {
"connect": "60s",
"send": "60s",
"read": "60s"
},
"description": "Default Kong proxy timeouts are sufficient for storage CRUD, batch and search endpoints."
},
"EnvVars": [
{
"name": "DB_HOST",
"value": null,
"description": "PostgreSQL database host",
"type": "DB",
"essential": true
},
{
"name": "DB_PORT",
"value": "5432",
"description": "PostgreSQL database port",
"type": "DB",
"essential": true
},
{
"name": "DB_USERNAME",
"value": null,
"description": "PostgreSQL database username (sourced from the secret store)",
"type": "DB",
"essential": true
},
{
"name": "DB_PASSWORD",
"value": null,
"description": "PostgreSQL database password (sourced from the secret store)",
"type": "DB",
"essential": true
},
{
"name": "DB_DATABASE",
"value": null,
"description": "PostgreSQL database name holding the per-tenant mod-orders-storage schemas",
"type": "DB",
"essential": true
},
{
"name": "DB_HOST_READER",
"value": null,
"description": "Optional read-replica host for read queries; used only together with DB_PORT_READER",
"type": "DB",
"essential": false
},
{
"name": "DB_PORT_READER",
"value": null,
"description": "Port of the read replica set in DB_HOST_READER",
"type": "DB",
"essential": false
},
{
"name": "DB_SERVER_PEM",
"value": null,
"description": "PEM certificate of the PostgreSQL server; when set, connections use TLSv1.3 with full verification",
"type": "DB",
"essential": false
},
{
"name": "DB_MAXPOOLSIZE",
"value": "20",
"description": "Maximum connections per tenant pool. Value taken from bugfest; RMB default is 4",
"type": "DB",
"essential": false
},
{
"name": "DB_MAXSHAREDPOOLSIZE",
"value": null,
"description": "When set, all tenants share one pool of this size instead of per-tenant pools of DB_MAXPOOLSIZE",
"type": "DB",
"essential": false
},
{
"name": "DB_CONNECTIONRELEASEDELAY",
"value": "60000",
"description": "Idle time in milliseconds before a pooled connection is closed (RMB default)",
"type": "DB",
"essential": false
},
{
"name": "DB_MAX_LIFETIME",
"value": "1800000",
"description": "Maximum lifetime of a pooled connection in milliseconds (RMB default)",
"type": "DB",
"essential": false
},
{
"name": "DB_RECONNECTATTEMPTS",
"value": "0",
"description": "Number of reconnect attempts when a database connection cannot be established (Vert.x default 0)",
"type": "DB",
"essential": false
},
{
"name": "DB_RECONNECTINTERVAL",
"value": "1000",
"description": "Interval in milliseconds between database reconnect attempts (Vert.x default)",
"type": "DB",
"essential": false
},
{
"name": "DB_EXPLAIN_QUERY_THRESHOLD",
"value": "300000",
"description": "Queries slower than this many milliseconds are logged with EXPLAIN ANALYZE. Value taken from bugfest; RMB default is 1000",
"type": "DB",
"essential": false
},
{
"name": "DB_ALLOW_SUPPRESS_OPTIMISTIC_LOCKING",
"value": null,
"description": "ISO-8601 timestamp until which clients may bypass optimistic locking (_version) on purchase orders, order lines and pieces; unset means never",
"type": "DB",
"essential": false
},
{
"name": "KAFKA_HOST",
"value": null,
"description": "Kafka broker host for audit event publishing and inventory / EDI export event consumers",
"type": "KAFKA",
"essential": true
},
{
"name": "KAFKA_PORT",
"value": "9092",
"description": "Kafka broker port",
"type": "KAFKA",
"essential": true
},
{
"name": "REPLICATION_FACTOR",
"value": "2",
"description": "Replication factor for Kafka topics created by this module. Value taken from bugfest; module default is 1",
"type": "KAFKA",
"essential": false
},
{
"name": "MAX_REQUEST_SIZE",
"value": "1048576",
"description": "Kafka producer max.request.size in bytes (module default)",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_PRODUCER_TENANT_COLLECTION",
"value": "ALL",
"description": "Enables tenant collection topics ({ENV}.Default.{value}.{EVENT}); must match [A-Z][A-Z0-9]{0,30} and be the same across modules. Value taken from bugfest; unset means per-tenant topics",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_TENANT_FILTER_ENABLED",
"value": "false",
"description": "Enables folio-kafka-wrapper filtering of consumed records by tenant entitlement (library default)",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_TENANT_FILTER_TENANT_DISABLED_STRATEGY",
"value": "SKIP",
"description": "Handling of records for a tenant without entitlement (ACCEPT, SKIP, FAIL). Applies when KAFKA_TENANT_FILTER_ENABLED is true",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_TENANT_FILTER_ALL_TENANTS_DISABLED_STRATEGY",
"value": "FAIL",
"description": "Handling of records when no tenant is entitled (ACCEPT, SKIP, FAIL). Applies when KAFKA_TENANT_FILTER_ENABLED is true",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_TENANT_FILTER_ENTITLEMENT_REFRESH_INTERVAL_SECONDS",
"value": "900",
"description": "Interval in seconds for refreshing the tenant entitlement list. Applies when KAFKA_TENANT_FILTER_ENABLED is true",
"type": "KAFKA",
"essential": false
},
{
"name": "KAFKA_TENANT_FILTER_ENTITLEMENT_LOOKUP_TIMEOUT_SECONDS",
"value": "5",
"description": "Timeout in seconds for a tenant entitlement lookup. Applies when KAFKA_TENANT_FILTER_ENABLED is true",
"type": "KAFKA",
"essential": false
},
{
"name": "ENV",
"value": null,
"description": "Logical deployment name used as the Kafka topic prefix; must match the other modules",
"type": "CONFIG",
"essential": true
},
{
"name": "OKAPI_URL",
"value": null,
"description": "Base URL (the module's sidecar on Eureka) for tenant entitlement lookups; used only when KAFKA_TENANT_FILTER_ENABLED is true",
"type": "CONFIG",
"essential": false
},
{
"name": "JAVA_OPTIONS",
"value": "-Dhttp.port=8082",
"description": "JVM options for the module process. -Dhttp.port=8082 moves RMB off its default port 8081, which the Eureka sidecar uses; it must match the sidecar's MODULE_URL. Heap sizing comes from the java block.",
"type": "CONFIG",
"essential": false
},
{
"name": "LOG4J_CONFIGURATION_FILE",
"value": null,
"description": "Location of an external Log4j2 configuration overriding the bundled log4j2.properties",
"type": "CONFIG",
"essential": false
}
]
},
"sidecarDefaults": {
"resources": [
{
"name": "cpu",
"value": "64",
"description": "CPU request/limit for the sidecar container"
},
{
"name": "memory",
"value": "1024",
"description": "Memory hard limit for the sidecar container in MiB"
},
{
"name": "memoryReservation",
"value": "512",
"description": "Memory reservation (soft limit) for the sidecar container in MiB"
}
],
"java": [
{
"name": "xms",
"value": "128m",
"description": "Initial Java heap size"
},
{
"name": "xmx",
"value": "256m",
"description": "Maximum Java heap size"
},
{
"name": "MaxMetaspaceSize",
"value": "96m",
"description": "Maximum Java metaspace size"
},
{
"name": "UseZGC",
"value": "true",
"description": "Use the ZGC low-pause collector"
}
],
"EnvVars": [
{
"name": "ENV",
"value": null,
"description": "Deployment environment identifier; must match the module's ENV",
"type": "CONFIG",
"essential": true
},
{
"name": "MODULE_NAME",
"value": "mod-orders-storage",
"description": "Name of the backend module the sidecar fronts",
"type": "CONFIG",
"essential": true
},
{
"name": "MODULE_URL",
"value": null,
"description": "Internal URL (host:port) at which the mod-orders-storage container is reachable from its sidecar",
"type": "CONFIG",
"essential": true
},
{
"name": "MODULE_VERSION",
"value": null,
"description": "Version of the mod-orders-storage module deployed alongside this sidecar",
"type": "CONFIG",
"essential": true
}
]
}
}