You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
kafka/bin/kafka-topics.sh --zookeeper localhost:2181 --delete --topic test
138
+
kafka/bin/kafka-topics.sh --bootstrap-server localhost:9092 --delete --topic test
137
139
138
140
139
141
Stop local instance:
140
142
141
143
# Either <Ctrl-C> in the kafka terminal, then in the zookeeper terminal
142
-
144
+
143
145
# Or:
144
146
sh stop_all.sh
145
-
147
+
146
148
For more, see https://kafka.apache.org/documentation.html
147
149
148
150
@@ -158,7 +160,7 @@ It will create these topics:
158
160
* "Accelerator": Alarm configuration and state (compacted)
159
161
* "AcceleratorCommand": Commands like "acknowledge" from UI to the alarm server (deleted)
160
162
* "AcceleratorTalk": Annunciations (deleted)
161
-
163
+
162
164
The command messages are unidirectional from the alarm UI to the alarm server.
163
165
The talk messages are unidirectional from the alarm server to the alarm annunciator.
164
166
Both command and talk topics are configured to delete older messages, because only new messages are relevant.
@@ -181,8 +183,8 @@ More on this in http://www.shayne.me/blog/2015/2015-06-25-everything-about-kafka
181
183
You can track the log cleaner runs via
182
184
183
185
tail -f logs/log-cleaner.log
184
-
185
-
186
+
187
+
186
188
Start Alarm Server
187
189
------------------
188
190
@@ -224,8 +226,8 @@ The messages in the config topic consist of a path to the alarm tree item that i
224
226
Example key:
225
227
226
228
config:/Accelerator/Vacuum/SomePV
227
-
228
-
The message always contains the user name and host name of who is changing the configuration.
229
+
230
+
The message always contains the user name and host name of who is changing the configuration.
229
231
230
232
The full config topic JSON format for a alarm tree leaf:
231
233
@@ -268,7 +270,7 @@ Deleting an item consists of marking a path with a value of null. This "tombston
268
270
For example:
269
271
270
272
config:/path/to/pv : null
271
-
273
+
272
274
This process variable is now marked as deleted. However, there is an issue. We do not know why, or by whom it was deleted. To address this, a message including the missing relevant information is sent before the tombstone is set.
273
275
This message consists of a user name, host name, and a delete message.
274
276
The delete message may offer details on why the item was deleted.
@@ -280,12 +282,12 @@ The config delete message JSON format:
280
282
"host": String,
281
283
"delete": String
282
284
}
283
-
285
+
284
286
The above example of deleting a PV would then look like this:
The message about who deleted the PV would obviously be compacted and deleted itself, but it would be aggregated into the long term topic beforehand thus preserving a record of the deletion.
290
292
______________
291
293
- Type `state:`, State Topic:
@@ -315,7 +317,7 @@ The state topic JSON format for an alarm tree node:
315
317
"mode": String,
316
318
}
317
319
318
-
At minimum, state updates this always contain a "severity".
320
+
At minimum, state updates this always contain a "severity".
319
321
320
322
The "latch" entry will only be present when an alarm that
321
323
is configured to latch is actually latching, i.e. entering an alarm severity
@@ -332,7 +334,7 @@ Example messages that could appear in a state topic:
332
334
In this example, the first message is issued when the alarm latches to the MAJOR severity.
333
335
The following update indicates that the PV's current severity dropped to MINOR, while the alarm severity, message, time and value
334
336
continue to reflect the latched state.
335
-
337
+
336
338
________________
337
339
- Type `command:`, Command Topic:
338
340
@@ -345,7 +347,7 @@ The command topic JSON format:
345
347
"host": String,
346
348
"command": String
347
349
}
348
-
350
+
349
351
An example message that could appear in a command topic:
@@ -404,6 +406,150 @@ it can lock the UI while the internal TreeView code gets to traverse all 'siblin
404
406
This has been observed if there are 10000 or more siblings, i.e. direct child nodes to one node of the alarm tree.
405
407
It can be avoided by for example adding sub-nodes.
406
408
409
+
Encryption, Authentication and Authorization
410
+
--------------------------------------------
411
+
412
+
The default setup as described so far connects to Kafka without encryption nor authentication.
413
+
While this may be acceptable for a closed control system network, you can enable encryption,
414
+
authentication and authorization for extended security.
415
+
Kafka allows many authentication schemes. Below outlines the setup for SSL encryption with
416
+
either two-way TSL authentication or user/password (a.k.a SASL PLAIN).
417
+
418
+
### Prerequistes
419
+
420
+
To enable SSL encryption at least the kafka server requires a SSL certificate.
421
+
You can create your own self signed root CA to sign these certificates.
422
+
Then add this rootCA to a truststore, create a certificate for the server, sign it
423
+
and add it to a keystore.
424
+
Confluent provides a good [step-by-step documentation](https://docs.confluent.io/platform/current/security/security_tutorial.html#creating-ssl-keys-and-certificates).
0 commit comments