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
Copy file name to clipboardExpand all lines: README.adoc
+14-10Lines changed: 14 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -6,26 +6,30 @@ Unfortunately there are few to nothing libraries natively suitable to be used in
6
6
7
7
The Moquette library is Java MQTT broker based on an eventing model with Netty. The library has a good performance and is desegned with embedding support out of the box. Its configuration is compatible with well known Mosquitto Open Source MQTT server.
8
8
9
-
Being combained together there and empowered by Clojure - these tools open the way to painless M2M communications for services written in Clojure.
9
+
When being combined - these tools open the way to painless M2M communications for services written in Clojure.
10
+
11
+
As always we prefer to have things tiny and as simple as possible.
10
12
11
13
== Compatibility
12
14
13
-
The following implementations are successfully passes production tests:
15
+
The following implementations are successfully passed production tests:
14
16
15
17
- Moquette
16
18
- Mosquitto
17
19
- Paho
18
20
- MQTT.js
19
21
- DKD/Brownie
20
22
23
+
any other tool that conform MQTT specs should pass too, we believe.
24
+
21
25
== Usage
22
26
23
27
The usage pattern is simple:
24
28
25
29
- define handlers
26
30
- create broker instance
27
31
- start the service
28
-
- serve messages
32
+
- start serve messages
29
33
30
34
=== Defining handlers
31
35
@@ -42,7 +46,7 @@ The handlers record should implement `InterceptHandler` interface
@@ -58,9 +62,9 @@ The `ALL_MESSAGE_TYPES` vector contains the whole bunch of the related messages
58
62
59
63
=== Creating instance
60
64
61
-
The library contains default `SimpleBroker` implementation written in Java that requires resources' configuration file name to be passed into construtor.
65
+
The library contains default `SimpleBroker` implementation written in Java that requires resources' configuration file name to be passed into constructor.
62
66
63
-
In order to manage the instance itnshould be passed as a parameter into the Clojure record implements `CljBroker` interface.
67
+
In order to manage the instance comfortably it should be passed as a parameter into the Clojure record implements `CljBroker` interface.
64
68
65
69
.CljBroker interface definition
66
70
[source, clojure]
@@ -84,10 +88,10 @@ so the instantiation of the complete Broker is looks like:
84
88
85
89
=== Starting the service
86
90
87
-
The clojure interface support two approaches:
91
+
The Clojure interface supports two approaches:
88
92
89
-
. controling the instance by calling `start`/`stop` methods (that fully corresponds to its Java interface)
90
-
. controling the instance by `with-open` macro
93
+
. controlling the instance by calling `start`/`stop` methods (that fully corresponds to its Java interface)
94
+
. controlling the instance by `with-open` macro
91
95
92
96
.start/stop
93
97
[source,clojure]
@@ -121,4 +125,4 @@ The clojure interface support two approaches:
0 commit comments