Commit Graph

1580 Commits

Author SHA1 Message Date
Zaiming Shi
85f8ba10ce fix(emqx_machine_signal_handler): ignore unknown info 2021-08-06 08:21:06 +02:00
zhouzb
3761db0525 feat(authn redis): support authn with redis 2021-08-06 14:05:31 +08:00
Zaiming Shi
bee8f01ee8 feat(emqx_machine): add a kill signal handler
Now the signal from kill PID can also be handled gracefully
2021-08-06 02:12:21 +02:00
Zaiming Shi
4025d31295 refactor(emqx_machine): move code from _app module to to emqx_machine 2021-08-05 14:30:59 +02:00
Zaiming Shi
bc23ff5e47 feat: add graceful shutdown
prior to this cahnge emqx node shutdown is done by init:stop
which might have undesired stop order of the applications

in this change, emqx_machine_terminator is added to stop apps
in defined order and then terminate the node in infinite loop
2021-08-05 14:11:58 +02:00
Zaiming Shi
d453005d8b fix(emqx): pin quicer 0.0.7 2021-08-05 13:43:22 +02:00
Zaiming Shi
d3038c0b71 fix(exhook): BrokerInfo uptime is now a duration integer 2021-08-05 12:58:03 +02:00
Zaiming Shi
6f8ca4ce07 feat: allow disable listener from environment variable 2021-08-05 12:58:03 +02:00
Zaiming Shi
ce24696329 refactor(emqx_app): start quic listener condition
when the app is present, and when listners are configured
2021-08-05 12:58:03 +02:00
Zaiming Shi
bdb871cb9a refactor(emqx_listeners): simplify listing logic 2021-08-05 12:07:10 +02:00
DDDHuang
e7cb9491c6
Merge pull request #5306 from DDDHuang/sys_info
chore: sys uptime by millisecond
2021-08-05 13:51:06 +08:00
zhanghongtong
dba37513a1 fix(emqx_ctl): fix an error when "~" in the print content 2021-08-05 10:45:40 +08:00
JianBo He
835eb84b5d chore(gw): remove needless files 2021-08-05 09:47:17 +08:00
JianBo He
94e33c3917 chore(gw): adapt to authn config format 2021-08-05 09:47:17 +08:00
JianBo He
1b2f732f13 chore(gw): fix zone name 2021-08-05 09:47:17 +08:00
JianBo He
f36c523ae8 chore(gw): integrate with emqx-authn 2021-08-05 09:47:17 +08:00
Zaiming (Stone) Shi
58446217a6
Merge pull request #5341 from zmstone/split-emqx-app
Split emqx app
2021-08-04 09:43:10 +02:00
DDDHuang
b3ea7f9cce
Merge pull request #5378 from DDDHuang/clients_api_fix
fix: add cleints api query params doc & unsubscribe api
2021-08-04 15:07:51 +08:00
Zaiming Shi
781de7f2a7 test(authz): ensure config cleaned up after test 2021-08-04 08:40:09 +02:00
Zaiming Shi
e6232665a3 refactor(emqx): ensure app shutdown and reboot order
make use of application dependency to ensure start order.
also the same dependency top-sorted for shutdown and reboot order
2021-08-04 08:40:03 +02:00
DDDHuang
b99ec04267
Merge pull request #5379 from DDDHuang/listeners_api_fix
fix: listeners id param name
2021-08-04 14:39:45 +08:00
DDDHuang
ac2084daeb
Merge pull request #5382 from DDDHuang/publish_api_fix
fix: publish api params
2021-08-04 14:39:05 +08:00
Zaiming Shi
3cda69fa3f fix(logging): text log formatter avoid binary literals 2021-08-04 08:36:10 +02:00
Zaiming Shi
58d0717b2f fix: add debug log for apps stop 2021-08-04 08:36:10 +02:00
Zaiming Shi
e6907478ba test: move emqx_global_gc_SUITE to emqx_machine app 2021-08-04 08:36:10 +02:00
Zaiming Shi
5b5006e8ab refactor(emqx_sup): move global gc to emqx_machine app 2021-08-04 08:36:10 +02:00
Zaiming Shi
522d8e0a4a refactor(config): split config and schema 2021-08-04 08:36:10 +02:00
Zaiming Shi
4bbd398550 refactor(emqx): create emqx_machine app 2021-08-04 08:36:10 +02:00
JianBo He
7e00805af3 chore(gw-lwm2m): remove needless files 2021-08-04 10:10:22 +08:00
JianBo He
b16cf44bf6 refactor(gw-lwm2m): refine lwm2m 2021-08-04 10:10:22 +08:00
DDDHuang
07a4d54a25 fix: unsubscribe api; query params 2021-08-03 17:08:40 +08:00
JianBo He
82321da7ad chore(exhook): bump version 2021-08-03 14:06:58 +08:00
JianBo He
d7322aff19 chore(exhook): empty appup.src 2021-08-03 14:06:58 +08:00
JianBo He
604e282978 chore(exhook): fix dialyzer warnings 2021-08-03 14:06:58 +08:00
JianBo He
922aa7aae5 test(exhook): refine property-tests 2021-08-03 14:06:58 +08:00
JianBo He
7c46c8712b docs(exhook): renanme CheckAcl to Authorize 2021-08-03 14:06:58 +08:00
JianBo He
aa019b34ad test(exhook): refine tests 2021-08-03 14:06:58 +08:00
JianBo He
879c191e41 refactor(exhook): adapt to the hocon schmea 2021-08-03 14:06:58 +08:00
tigercl
58b39361b3
Merge pull request #5388 from tigercl/feat/authn-api
feat(authn api): support query authentication status
2021-08-03 11:05:12 +08:00
zhouzb
05b72157e2 test(authn): add test cases 2021-08-03 10:40:08 +08:00
zhouzb
99534e7212 feat(authn api): support query authentication status 2021-08-03 10:25:04 +08:00
lafirest
149ef6d7cc style(emqx_gateway): improve some emqx_coap code 2021-08-03 09:48:08 +08:00
zhouzb
5e9ed72975 chore(authn rename): missing name change 2021-08-03 09:24:49 +08:00
zhouzb
fb716ae8b2 chore(authn rename): rename emqx_authn to authentication 2021-08-03 09:21:07 +08:00
DDDHuang
8e2b1aed32 fix: publish api params 2021-08-02 17:20:15 +08:00
DDDHuang
52ff6e1b3e fix: listeners id param name 2021-08-02 15:54:25 +08:00
DDDHuang
ca50dfe686 fix: add cleints api query params doc 2021-08-02 10:03:28 +08:00
Zaiming Shi
b10fb4e95d refactor: unify all io:format calls to use the same macro 2021-08-01 09:36:59 +02:00
Zaiming Shi
5f51f68cc9 fix(mqttsn): do not call emqx_logger:Level directly 2021-08-01 09:36:59 +02:00
Zaiming Shi
683974e1c8 refactor(log/textfmt): print mfa metadata in text formatter 2021-08-01 09:36:59 +02:00
Zaiming Shi
2998a87a8d fix(log/jsonfmt): log map() reports at top level JSON fields 2021-08-01 09:36:59 +02:00
Zaiming Shi
5d59ac1f02 refactor(logging): delete log headers from all modules 2021-08-01 09:36:59 +02:00
Zaiming Shi
e57f99168b refactor(logger): delete log header parse-transform
because now we have MFA in log
2021-08-01 09:36:59 +02:00
Zaiming Shi
0f5c5db841 refactor(logger): stop using anonymous fun for logging 2021-08-01 09:36:59 +02:00
Zaiming Shi
df69a9c031 chore: upgrade to hocon 0.11.0 2021-08-01 09:36:59 +02:00
lafirest
137294db8f refactor(eqmx_gateway): port emqx_coap into emqx_gateway framework 2021-07-31 15:50:09 +08:00
zhanghongtong
9a03138e53 feat(hooks): emqx hooks support put 2021-07-30 19:01:24 +08:00
zhanghongtong
1f4ce31010 chore(release): update emqx release version 2021-07-30 17:52:35 +08:00
Zaiming Shi
40faa31241 test(authz): no need to mock emqx_config 2021-07-30 16:53:21 +08:00
tigercl
305142f991
Merge pull request #5361 from turtleDeng/plugins/module-attr
chore(plugins): delete emqx_plugins module attributes
2021-07-30 15:54:20 +08:00
JianBo He
e6a2770e2f chore(gw): rename emqx_gateway to gateway 2021-07-30 15:42:03 +08:00
JianBo He
602f0ebb60 feat(gw-sn): call subscribe/unsubscribe hook 2021-07-30 15:42:03 +08:00
JianBo He
c986f89319 test(gw): use emqx_config:init_load/2 2021-07-30 15:42:03 +08:00
JianBo He
ec72513cf8 feat(gw-stomp): call unsubscribe hook 2021-07-30 15:42:03 +08:00
JianBo He
f87bef9ffb feat(gw-stomp): run subscribe hooks 2021-07-30 15:42:03 +08:00
JianBo He
a116c0afd1 fix(gw-stomp): unify the hearbeat type name 2021-07-30 15:42:03 +08:00
JianBo He
c36cdf9682 refactor(gw): add bytes & packets metrics 2021-07-30 15:42:03 +08:00
JianBo He
80eb7f313d docs(gw): enrich README.md 2021-07-30 15:42:03 +08:00
JianBo He
67bb8d0564 chore(gw): some format improvement 2021-07-30 15:42:03 +08:00
JianBo He
6f084fe6cf fix(gw-cli): fix start/stop/lookup not works 2021-07-30 15:42:03 +08:00
Shawn
054623bd56 fix(authz): update the post_config_update callback 2021-07-30 15:37:09 +08:00
Shawn
dc1ba51935 fix(emqx_config): always check config files using richmap at emqx bootup 2021-07-30 15:37:09 +08:00
Shawn
35032e1d44 refactor(emqx_config): call MOD:post_config_update/3 after checking hocon schema 2021-07-30 15:37:09 +08:00
Turtle
9e97de04c9 chore(plugins): delete emqx_plugins module attributes 2021-07-30 14:32:01 +08:00
Turtle
d8eb8a36e0 test(modules/event_message): do not set fake config 2021-07-30 14:17:34 +08:00
Turtle
ef1b591532 chore: Dynamically get the app that starts by default 2021-07-30 13:43:25 +08:00
tigercl
e2d507cad9
Merge pull request #5356 from tigercl/feat/authn-mongo-api
feat(authn mongo api): add api spec for mongo authn
2021-07-30 13:16:31 +08:00
Turtle
485f1293fc chore(event_message): rename event_topic to event_message 2021-07-30 12:10:55 +08:00
Turtle
ebe31c79d4 feat(event-topic): Add more fields to disconnected event payload 2021-07-30 12:10:55 +08:00
Turtle
d6c375ab5b feat(event-topic): fix check dialyzer 2021-07-30 12:10:55 +08:00
Turtle
459d2154c7 feat(event-topic): add more test cases 2021-07-30 12:10:55 +08:00
Turtle
3903575435 feat(event-topic): support publish broker event topic 2021-07-30 12:10:55 +08:00
zhouzb
1c3d46d29e feat(authn api): add required spec 2021-07-30 12:01:17 +08:00
zhouzb
5c9dabc064 feat(authn mongo api): add api spec for mongo authn 2021-07-30 11:47:48 +08:00
Zaiming Shi
18fb18be89 test(modules/rewrite): do not set fake config
the hand-crafted fake raw config does not pass hocon schema check
this commit changes to use HOCON text as input for both test cases
2021-07-30 09:18:43 +08:00
Zaiming Shi
729f89f514 chore(rebar.config): update hocon version 0.10.5 2021-07-30 09:18:43 +08:00
Zaiming Shi
9dcb725898 fix(emqx_authz): update config with own schema module 2021-07-30 09:18:43 +08:00
Zaiming Shi
cf1246f026 feat(emqx_config): allow loading configs from binary
This will be helpful for tests
2021-07-30 09:18:43 +08:00
Turtle
740b729778 feat(api): support stats/metrics API aggregate 2021-07-30 09:09:45 +08:00
Zaiming (Stone) Shi
dcfc705811
Merge pull request #5342 from zmstone/refactor-config-store-per-root
refactor(emqx_config): store configs per root name
2021-07-29 17:38:33 +02:00
Zaiming Shi
4836d0a1fc test(exproto): delete unused code 2021-07-29 16:30:29 +02:00
zhouzb
336fe63c1c feat(enable authn): support enable authn by http api 2021-07-29 20:45:19 +08:00
Zaiming Shi
c0ffbd68c8 test(emqx_authz): adjust meck and app start order 2021-07-29 13:32:57 +02:00
Zaiming Shi
d0e9d4c4d5 fix(emqx_resource): raise error when failed to pick worker 2021-07-29 12:34:16 +02:00
Zaiming Shi
82df49d165 fix(emqx_config): handle default value correctly 2021-07-29 12:18:45 +02:00
Zaiming Shi
8d2f9d4e1c refactor(emqx_config): store configs per root name
Prior to this change, the global (a big map) config is saved
to persistent_term as one single term.

With this change, configs are keyed by their name spaces,
i.e. the root struct names in hocon schema.

This is to allow loading configs with more dynamic scope,
so we can start emqx app independently (without all merged configs),
and to allow external plugins to load their configs incrementally
at run-time.
2021-07-29 12:18:45 +02:00
Zaiming Shi
085d6c9ba0 fix(emqx_schema): resolve os env in translation
default value is a part of schema which should be static and
deterministic between different run-time or build-time environment
2021-07-29 12:18:45 +02:00
Turtle
2fcb9124bf chore(modules): fix check dialyzer 2021-07-29 16:57:14 +08:00
Turtle
76e3dd1905 chore(modules): Get the status by conf 2021-07-29 16:57:14 +08:00
Turtle
cdc8000493 chore(modules): presence/delayed/telemetry/rewrite/topic_metrics independent conf 2021-07-29 16:57:14 +08:00