Commit Graph

128 Commits

Author SHA1 Message Date
spring2maz
efc9e34033 Make use of BUMP_PACKET_ID the only way to generate packet IDs 2019-02-28 11:17:27 +08:00
spring2maz
67376727c9 Add batch send support for emqx_client:publish/2
also cover emqx_portal_mqtt with CT
2019-02-28 11:17:27 +08:00
spring2maz
fbe67e6784 Introduce new bridge impl 2019-02-28 11:17:27 +08:00
Gilbert
c3e6f3c3b2 Improve try catch syntax (#2263)
* Replace case catch.. with try ... catch
Prior to this change, case catch ... would cost a lot of performance
because it would retrieve the whole stacktrace. However, try...catch
will not retrieve the whole stacktrace. So try...catch syntax is better.
2019-02-28 09:54:28 +08:00
Feng Lee
269b74232a Introduce some common types 2019-02-19 17:16:11 +08:00
张奇怪
44d3eff094 Auto-pull-request-by-2019-02-19 (#2232)
* Update Copyright to 2019 (#2191)

* Disable bridges by default (#2189)

* Fix warning logger args emqx#2195

* Ambiguity elimination (#2217)

* Fix emqx_ws_connection: prevent crashes on pong (#2210)

* Issue#2184 (#2194)

* Delete dep-vsn-check

* Format app.src
2019-02-19 14:00:34 +08:00
turtled
31e95b56c4 Update Copyright to 2019 2019-01-29 10:43:25 +08:00
Feng Lee
d7254cdc7f Add more macros for logger 2019-01-04 17:30:27 +08:00
terry-xiaoyu
3b8eb41347 Remove the log header macro 2019-01-04 17:30:27 +08:00
Shawn
eeb0cab3e3 Update proc meta-data for empty clientid (#1980) 2018-11-23 18:11:46 +08:00
terry-xiaoyu
bc1464a33f Lazy logging without header 2018-11-19 11:17:58 +08:00
terry-xiaoyu
82b8047349 Helper funcs for adding proc meta-data 2018-11-19 11:17:58 +08:00
terry-xiaoyu
e8cc65ef40 Change logger micros 2018-11-19 11:17:58 +08:00
terry-xiaoyu
41315bff0d Log macros for lazy evaluation 2018-11-19 11:17:58 +08:00
Gilbert Wong
32d3826440 Replace macro QOS$i to QOS_$I
The two styles of qos macro name in one project is chaotic. It is not
a good practice.

So I change the QOS$i to QOS_$i
2018-11-08 20:42:31 +08:00
spring2maz
ae743ad1f0 Rewrite emqx_mqueue.erl
Fixed bugs:

- Priority queue lack of a `len + 1` logic in `in/2`

Changed behaviors:

- Topics not found in priority table (from config) will be treated with default priority,
  instead of hasing topic name to a priority number.
- Default priority is now configurable (it was always lower than all configured priorities)
- The dropped message due to reaching `max_len` is now returned from `in/2`,
  so the queue owner (`in/2` caller) can perform autopsy on it
2018-10-27 14:21:53 +02:00
Gilbert
4c40f75f4b Request & Response (broker and client) (#1819)
Add request & response support for CONNECT & CONNACK

Prior to this change, there is no validate and specified process for
Request-Response-Information and Response-Information

Also added basic Request/Response functionality to emqx_client implementation
2018-10-18 19:21:05 +02:00
terry-xiaoyu
dd8513ad35 Update for banned API
Use `mnesia:foldl` to traverse mnesia rather than `mnesia:first` and
`mnesia:next`, as a badarg exception would occur if the record was
deleted while travering the whole table.
2018-09-07 14:10:16 +08:00
周子博
83e11b6e39 Add emqx_banned test suite, and fix bugs in emqx_banned 2018-08-30 22:45:08 +08:00
Feng Lee
567aeb274f Define types in emqx_types, emqx_mqtt_types modules 2018-08-29 23:08:55 +08:00
turtled
6478f811bf Fix conflicts 2018-08-27 10:29:22 +08:00
turtled
95d36d0204 Fix share sub bug 2018-08-27 10:15:41 +08:00
Feng Lee
0e3728c940 Add emqx_types module and 'credentials' type 2018-08-26 16:24:51 +08:00
Feng Lee
b10f49b52c Add CONNACK macros for MQTT V3.1.1 2018-08-25 11:49:19 +08:00
Feng Lee
0f052ce352 Upgrade connection, protocol and session modules for MQTT 5.0 2018-08-24 18:39:59 +08:00
Feng Lee
6ab489a9b5 Change the MAX_CLIENTID_LEN to 65535 2018-08-10 15:38:08 +08:00
turtled
4d9e03a803 Refactor websocket conn using cowboy 2018-08-08 18:36:14 +08:00
Feng Lee
7d0cba9427 Add MQTT 5.0 supports for connection, protocol and session modules 2018-08-06 16:33:10 +08:00
Feng Lee
b110a154ef Upgrade header files for EMQ X 3.0 2018-07-18 14:27:11 +08:00
Feng Lee
bffdd2ba74 Upgrade esockd and add more test cases 2018-05-22 13:01:19 +08:00
Feng Lee
31bc091873 Implement MQTT Version 5.0 client 2018-05-06 17:45:18 +08:00
Feng Lee
dc7804a2dc Support MQTT Version 5.0 Client 2018-04-30 12:27:39 +08:00
Feng Lee
2a4ffc6645 Add more service modules for MQTT Version 5.0 2018-04-18 16:34:23 +08:00
Feng Lee
bbb66ff92e Refactor the broker, router modules 2018-04-10 18:17:07 +08:00
Feng Lee
bfb23ff0b2 Improve the design of MQTT session management 2018-04-08 15:16:05 +08:00
Feng Lee
39548cc399 Improve the session management 2018-04-04 15:28:01 +08:00
Feng Lee
2eed46310c Misc fix for the MQTT Version 5.0 2018-03-30 17:18:08 +08:00
Feng Lee
9976327c8d Add emqx_mqtt module 2018-03-23 18:13:09 +08:00
Feng Lee
56b88dd7f7 Improve the design of session management 2018-03-23 16:39:23 +08:00
Feng Lee
282e341433 EMQ X R3.0 - Improve the design of pubsub and router 2018-03-21 16:48:52 +08:00
Feng Lee
6a957e1b33 Support MQTT Version 5.0 2018-03-02 20:18:27 +08:00
Feng Lee
aef5a20697 Add 'message' and 'delivery' record 2018-03-01 21:04:00 +08:00
Feng Lee
d7eae533ac Merge the emqx-mqtt5 library 2018-02-28 21:22:39 +08:00
Feng Lee
f7f0f27e4d Parse and serialize MQTT 5.0 protocol packets 2018-02-27 23:45:55 +08:00
Feng Lee
f4fd6efe16 Merge the emqx-common, emqx-router libraries 2018-02-26 23:29:53 +08:00
Feng Lee
fcb2ec8427 Merge the latest enterprise branch 2018-02-24 15:56:32 +08:00
Feng Lee
b63c34ab14 Merge the latest master branch 2018-02-24 11:27:09 +08:00
Feng Lee
a3e97f798b Update Copyright to 2018 2018-01-16 08:57:46 +08:00
Feng Lee
a904dfd4f2 Comment the ERTS_MINIMUM macro 2017-12-07 16:26:32 +08:00
turtled
a42fcb2c39 Fix conflicts 2017-12-05 16:34:18 +08:00