Commit Graph

170 Commits

Author SHA1 Message Date
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
Feng Lee 26fb809dbe Fix issue#1293 - the retained flags should be propagated for bridge. 2017-11-29 14:09:46 +08:00
Feng Lee 2cec86eba7 Merge with version 2.3.0 2017-11-21 14:14:12 +08:00
Feng Lee d41fd94abb Format the 'trie_node' record 2017-11-17 20:55:57 +08:00
Feng Lee 4b8cd18f5d Merge with EMQ X project 2017-10-09 19:43:06 +08:00
turtled d3f52898ee Add Hot configuration plugin 2017-09-05 16:52:07 +08:00
turtled 9e6c63b91b REST API add modify_config/config_list 2017-08-17 15:51:20 +08:00
turtled 7c1ee6610d Add http management APIs 2017-08-09 10:14:29 +08:00
Feng Lee 66c3c26d8b Support 'mountpoint' 2017-03-23 15:04:37 +08:00
Feng Lee 0df59934c7 Fix the GPROC_POOL macro 2017-03-13 12:14:57 +08:00
Feng Lee bb91bc04c6 Merge pull request #941 from callbay/issue#935
Fix Issue#935
2017-03-13 11:41:22 +08:00
Frank Feng 7cb3b7ca8a Id -> I 2017-03-12 23:07:45 +08:00
Feng Lee 35e08df735 Change the default QoS of will message to QOS_1 2017-03-06 18:17:07 +08:00
Feng Lee c3919a64e6 Format 'trie_node' record 2017-03-06 18:13:07 +08:00
Feng Lee 98e15ebbf4 Prepare for MQTT/5.0 2017-03-06 18:11:09 +08:00
Feng 9309baf17c Rename mqtt_msgid() type to mqtt_msg_id() 2017-02-23 22:59:26 +08:00
Feng Lee 73847b96fc Add 'FULLSWEEP_OPTS' macro 2017-02-23 17:16:55 +08:00
Feng Lee 088adeda3b Fix issue #916 - add 'mqtt_msg_from()' type 2017-02-22 14:11:10 +08:00
Feng 6c50a59cad Rename macro 'MAX_PACKET_LEN' to 'MAX_PACKET_SIZE' 2017-02-22 00:32:22 +08:00
Feng Lee de12c58af0 Rename 'MAX_LEN' to 'MAX_PACKET_LEN' 2017-02-21 20:09:31 +08:00
Feng Lee 4df2a71c27 Update copyright, format record, add 'AUTH' packet type for MQTT 5.0 2017-02-16 10:53:51 +08:00
huangdan 8092543efb Copyright (c) 2012-2017 2017-01-11 19:34:48 +08:00
Feng 7819d235b7 add mqtt_subscription record 2016-10-31 18:59:41 +08:00
Feng Lee a1ed02499c mqtt_topic 2016-08-21 16:21:45 +08:00
huangdan 7206e18621 mqtt_topic 2016-08-21 13:52:53 +08:00
Feng Lee 354ab5ad21 msgid -> id 2016-08-18 10:57:00 +08:00
Feng Lee c72a07dbb8 mqtt_delivery, mqtt_message 2016-08-16 13:41:53 +08:00
Feng Lee 123f9b444c mqtt_message, mqtt_delivery 2016-08-15 17:30:27 +08:00
Feng Lee 38daaa2f5c server -> pubsub -> router 2016-08-10 21:29:55 +08:00
Feng Lee 6686139bc6 mqtt_trie, mqtt_trie_node 2016-08-10 15:04:26 +08:00
Feng 226933018a improve the design of pubsub and router 2016-08-08 13:49:52 +08:00
Feng 285421f073 rm emqttd_backend.erl 2016-08-01 15:07:38 +08:00
Feng Lee 0b7b9aff37 #mqtt_credential{} 2016-07-30 21:23:15 +08:00
Feng Lee 3f9de8c073 fix plugins 2016-07-22 11:38:48 +08:00
Feng 4900641a89 extra 2016-04-30 14:18:16 +08:00
Feng 34493b6fec update PRINT_CMD 2016-03-08 13:17:04 +08:00
Feng e7c1d85d91 add mqtt_route record 2016-03-08 13:16:35 +08:00
Feng 569e8c3ec5 merge trie records from emqttd_trie.erl to this header file 2016-02-13 14:27:11 +08:00
Feng 1b79ebf232 0.16.0 - fix format/comments, add PROC_NAME/2 macro 2016-02-11 14:33:06 +08:00
Feng add9f0619e IF macro 2016-02-10 12:52:37 +08:00
Feng 94c3e69b44 Licensed under the Apache, Version 2.0 2016-02-05 14:26:17 +08:00
Feng 1e852ded91 0.16 - support static subscriptions 2016-02-02 13:36:52 +08:00
Feng 21cb2bea6e 2016 2016-01-15 13:43:22 +08:00
Feng b69b3e7938 iolist() 2015-12-28 20:16:55 +08:00
Feng fc6a49415f UNEXPECTED 2015-12-05 15:43:37 +08:00
Feng 80117c1e8a rewrite pubsub, router 2015-12-03 12:56:13 +08:00
Feng 16f23406a4 0.14 2015-12-02 18:01:26 +08:00
Feng Lee e05f0cb5b1 Merge pull request #382 from emqtt/chat
QOS0/1/2, Pooler Error
2015-11-14 10:46:45 +08:00
Feng 860183f931 chat 2015-11-12 13:07:46 +08:00
Feng 4fb018203e fix issue #377 2015-11-11 09:46:23 +08:00
Feng 22889f552c fix issue #163 - Protocol Compliant - Session Present Flag 2015-11-05 12:29:29 +08:00
Feng 8d3b7b4c24 client monitor 2015-10-30 21:19:35 +08:00
Feng Lee 4ee2abdbcf record_to_proplist/3 2015-10-30 18:00:36 +08:00
Feng f6636a9783 refactor client 2015-10-30 16:03:25 +08:00
Feng Lee 51a10328f3 PUBLISH_PACKET 2015-10-14 18:56:23 +08:00
Feng d3e39ae9a3 src/emqttd_mod_rewrite.erl 2015-10-13 21:01:53 +08:00
Feng 1ce01bdf7a space 2015-10-12 21:07:19 +08:00
Feng Lee 1935b414c7 issue #282 - improve sm 2015-10-10 13:12:00 +08:00
Feng 1a8056df22 USAGE 2015-10-01 11:18:00 +08:00