Commit Graph

2071 Commits

Author SHA1 Message Date
Zaiming Shi
6f5aa88562 chore(emqx_connection): Add a test case to cover oom kill 2021-03-30 10:08:13 +02:00
Zaiming Shi
6e1a55e9ed perf(emqx_connection): no priority receive
Prior to this change the main message receive loop of emqx_connection
is a priority receive which selects system messages and parent EXIT
signals prior to other message.
This accidental (not intended) design may cause the receive operation
to scan potentially large mail box.
2021-03-30 10:08:13 +02:00
Zaiming Shi
66693d6846 fix(emqx_connection): connection OOM kill immediately
Prior to this change, connection process' OOM kill is a loopback
message, which results in a delayed kill when message queue length
is large.
In this change, the loopback message is changed to an exit signal.
2021-03-30 10:08:13 +02:00
wwhai
2e30d7803f fix(channel): fix keep-alive problem 2021-03-30 16:01:42 +08:00
Shawn
7bf6ee0f4b
fix(mqtt-sn): sleep mode not working #4434 (#4435) 2021-03-29 17:51:49 +08:00
Zaiming Shi
6c77fa1bf7 fix(emqx_channel): Receive Maximum spec compliance
According to MQTT 5.0 specification
If the Receive Maximum value is absent then its value defaults to
65,535.
2021-03-29 09:42:07 +02:00
Zaiming Shi
b10a60cddb fix(conninfo): Ensure receive_maximum do not exceed limit 2021-03-29 09:42:07 +02:00
JianBo He
496e5381fb chore(rule-engine): compatible with the lower case hash string 2021-03-25 09:10:05 +08:00
Zaiming Shi
a4b30ea77c feat(emqx): Add backtrace_depth configuration 2021-03-23 21:30:49 +01:00
Zaiming Shi
4c5273c1d1 style(emqx_inflight): elvis: User UPPER_CASE macro 2021-03-23 21:30:49 +01:00
JianBo He
277cab86d3 refactor: improve the speed of hexstr and binary conversions 2021-03-23 18:25:19 +08:00
Zaiming Shi
8201e4c820 feat(emqx.erl): Add a help function to load debug secret 2021-03-19 21:46:03 +01:00
Zaiming Shi
e06b54ff71 chore(boot-log): print a warning at boot when running on old otp 2021-03-19 15:39:11 +01:00
Zaiming Shi
2d150127d4 feat(listeners): Ensure no tlsv1.3 for otp 22 or earlier 2021-03-19 15:39:11 +01:00
zhanghongtong
72c1ee264c chore(elvis): fix elvis error 2021-03-19 16:11:23 +08:00
zhanghongtong
568f4de6e5 fix(channel): fix the wrong acl check order
when subscribe, check the acl rule before run 'client.subscribe' hooks
2021-03-19 16:11:23 +08:00
Shawn
81602c973c fix(emqx): deny pingreq when mqtt not connected #4370 2021-03-19 14:17:49 +08:00
Karol Kaczmarek
c7b44caa1d feat(acl): Add possibility to remove all acl cache 2021-03-17 19:48:42 +01:00
William Yang
d5886c0c66
chore(build): Get rel vsn fallback (#4339) 2021-03-16 09:49:11 +01:00
z8674558
e9180b9ce8 chore(emqx_messages): fix elvis 2021-03-11 16:01:35 +09:00
z8674558
9087f0c138 feat(emqx_message): add from_map 2021-03-11 16:01:30 +09:00
Shawn
b400571dbb fix(emqx): validate mqtt malformed varible byte integer 2021-03-10 10:41:57 +01:00
Zaiming Shi
582dea10f5 style(emqx_sys): make elvis happy 2021-03-09 20:22:48 +01:00
Zaiming Shi
e1979bf488 chore(build): Single source of EMQX_DESCRIPTION 2021-03-09 20:22:48 +01:00
Zaiming Shi
00a2daba19 chore(build): add more enterprise build support 2021-03-06 10:56:07 +01:00
Zaiming Shi
1af1dd17b5 chore(build): use 'EMQ X test' as app description for test runs 2021-03-06 08:41:50 +01:00
Zaiming Shi
73500a0983 chore(build): inject product description from makefile 2021-03-06 08:41:50 +01:00
Zaiming Shi
c752f3bec5
Refactor http lib add uri parse (#4292)
* feat(http_lib): Add uri parse to emqx_http_lib

* fix(webhook): call emqx_http_lib to parse uri

* fix(auth-http): Call emqx_http_lib to parse uri

* fix(rule-engine): call emqx_http_lib to parse uri
2021-03-06 13:35:02 +08:00
Zaiming Shi
9b3ab169ce chore(versioning): detach package version from emqx app version 2021-03-04 20:24:58 +01:00
Zaiming Shi
42098b497f
Merge pull request #4283 from zmstone/add-emqx-http-lib
refactor(http-lib): Add emqx_http_lib
2021-03-04 07:14:02 +01:00
zhanghongtong
67c8b2eed7 chore: update emqx.app.src version 2021-03-04 08:10:48 +08:00
Zaiming Shi
63c001a7aa refactor(http-lib): Add emqx_http_lib
So far only uri_encode and uri_decode APIs
2021-03-03 21:38:10 +01:00
z8674558
3daefe954b chore(src): fix elvis 2021-03-03 20:06:31 +09:00
z8674558
a8558bc7b5 chore(emqx_channel): ignore peer_cert_as/5 from dialyzer 2021-03-03 20:06:31 +09:00
z8674558
e1b915b91c chore(emqx_tracer): pass proper map 2021-03-03 20:06:31 +09:00
zhanghongtong
cae0849152 fix(emqx_channel): fix bug when publish deny
fix the bug of replying to puback when the publish message with Qos equal to 2 is deny
2021-03-02 17:54:22 +08:00
Zaiming Shi
dd06d70bce refactor(build): Move parse_transform module to root app
So we do not have to workaround the compile order issue
2021-03-02 08:40:19 +08:00
Zaiming Shi
6e0b53fbb9 fix(eunit): fix emqx_tls_lib_tests 2021-03-01 21:00:17 +08:00
Zaiming Shi
0a51bd4c2f fix(webhook): Call common lib for ssl options 2021-03-01 21:00:17 +08:00
Zaiming Shi
700fa71754 refactor(tls): abstract lib for tls options parsing 2021-03-01 21:00:17 +08:00
z8674558
64ac20eec5 chore(emqx_listeners): fix clauses for dialyzer 2021-03-01 16:56:21 +08:00
z8674558
6ea4501de4 chore(emqx_listeners): fix type 2021-03-01 16:56:21 +08:00
Zaiming Shi
3dfa9f45c4
Merge pull request #4183 from zmstone/merge-e4.2.4-to-dev-4.3.0
Merge e4.2.4 to dev 4.3.0
2021-02-19 10:26:47 +01:00
Zaiming Shi
71d02e8011 chore(emqx_connection): delete stale code 2021-02-19 10:20:16 +01:00
Benjamin Große
ca1d24a98d feature(mgmt): restart a listener
example:

```
emqx_ctl listener restart mqtt:ssl:external
```

or

```
PUT /api/v4/listeners/mqtt:ssl:external/restart
```

thank you @zmstone for providing the listener-identifier apis :)
2021-02-19 09:22:47 +01:00
Zaiming Shi
98b319a0c0
Merge pull request #4190 from zmstone/refactor-assing-names-to-listeners
feat(listeners): Add identifier to listeners
2021-02-19 07:50:27 +01:00
Zaiming Shi
64cfaf4385 improve(print): io:format error message without indentation
Avoid squeezing lines to the right.
2021-02-19 07:45:37 +01:00
Benjamin Große
28f9b4d519 feat(peer_cert_as_clientid): peer_cert_as_clientid = cn | dn | crt | pem | md5
pem is base64 encoded instead of binary crt

peer_cert_as_username=crt breaks exhook proto utf8 parsing of username

crt cannot be used in a topic name due to being invalid utf8
pem cannot be used in a topic name due to having slashes

peer_cert_as_clientid = md5 allows to e.g. subscribe to "t/%c" with ACL

existing peer_cert_as_username combinations are unaffected.
2021-02-19 10:53:11 +08:00
Zaiming Shi
d2bd9b4078
Merge pull request #4197 from zmstone/improve-shared-sup-random-start-point-for-roundrobin
improve(shared-sub): Randomise the startpoint for round-robin
2021-02-18 13:26:01 +01:00
Zaiming Shi
db461179c5 improve(shared-sub): Randomise the startpoint for round-robin 2021-02-17 19:10:37 +01:00