Commit Graph

108 Commits

Author SHA1 Message Date
Shawn
bcf5f499da feat(connector): add APIs for connector 2021-11-22 17:35:33 +08:00
Zaiming Shi
6ca6d60858 fix(dashboard): change hash from sha3_256 to sha256
old version os has no support for it
2021-11-20 21:21:11 +01:00
Zaiming Shi
6edd862dd5 refactor: no more EMQX_ENTERPRISE compile flag
The compile flag was introduced in EQM X 4.3 series
where CE and EE code was diverged large enough which made
non-practicle to determin edition at runtime.

such approach made testing quite challenging as we'll have to
build with different compile flags inorder to run per-edition
test cases

In this commit, we try to retrieve edition info from EMQX's
description text, (put to PT for fast access) at runtime
so we can test ALL editions from a super-set edition (EE).
2021-11-20 20:41:06 +01:00
JimMoen
e361cd5733
Fix dashboard APIs return (#6177)
* fix(dashboard_api): delete non-exist user wrongly return 204

* fix(dashboard): dashboard user should use `tags` not `tag`

* fix(dashboard): create/update user return 200 with full users list

* fix(dashboard): logout status code 204

* fix(dashboard): update pwd status code 204

* test: test suite for dashboard APIs

* refactor(dashboard): user info mnesia record name use description

* style: make elvis happy

* fix(api): dashboard swagger check request should not override env

* fix(dashboard): add/modify dashboard returns single record

* ci: update emqx-fvt version to new tag 1.0.2-dev1
2021-11-18 14:36:12 +08:00
JimMoen
b3f9220d02 style: make elvis happy 2021-11-15 16:30:44 +08:00
JimMoen
106aa559e0 fix(api): DELETE success wrongly returned code 200 2021-11-15 16:30:44 +08:00
DDDHuang
1476accd63
fix: monitor bad mnesia write & rpc call (#6060) 2021-11-15 15:28:19 +08:00
DDDHuang
bc6e49804f
feat: support CORS request
feat: support CORS request
2021-11-11 20:27:39 +08:00
zhongwencool
7a5da76197
Mgmt http api banned (#5998)
* fix(swagger): don't transform [log,publish] to a list.pwd

* chore: replace banned-api by hocon schema

* fix(api): code style warning
2021-11-11 16:35:29 +08:00
zhongwencool
eea789451b
feat: sha3_256 dashboard account's password (#6084) 2021-11-09 15:41:28 +08:00
Ilya Averyanov
796553b5ea fix(authn api): eliminate possible atom leak 2021-11-01 16:51:48 +03:00
Ilya Averyanov
800b4b32c7
refactor(authn api): use config schemas for request validations (#5999) 2021-11-01 17:52:03 +08:00
zhongwencool
e62fde321c
Emqx alarm (#5994)
* chore(alarm): normalize_message outside emqx_alarm

* chore(alarm): don't cache config in emqx_alarm; remove dirty_write/read; add desc/example to alarm; add more test

* chore(alarm_api): alarm_api with hocon schema

* fix: activted's nullable is true

* fix(swagger): translate map to object

* fix(cluster_rpc): debug failed cluster_rpc test

* fix: Update schema description

Co-authored-by: Zaiming (Stone) Shi <zmstone@gmail.com>

Co-authored-by: Zaiming (Stone) Shi <zmstone@gmail.com>
2021-10-28 18:03:51 +08:00
Zaiming (Stone) Shi
4dbe3ccf71
refactor(dashboard): rename 'password' field to 'pwdhash' (#5990)
* refactor(dashboard): rename 'password' field to 'pwdhash'

rename as it is not plaintext password stored in db

* refactor(emqx_dashboard): rename records

* test(emqx_dashboard_token): add test case to cover match specs
2021-10-26 20:41:33 +08:00
zhongwencool
90795a6f42
Rewrite http api with hocon schema (#5980)
* feat: rewrite http api with hocon

* fix: crash when default_username is empty

* chore: udpate rewrite api with emqx_conf's cluster_rpc

* fix: spec wrong
2021-10-22 17:01:29 +08:00
zhongwencool
d784e63b9f
emqx_conf (#5939)
* feat(emqx_conf): move conf manager for emqx_machine to emqx_conf

* chore(emqx_conf): change emqx:get_config/2 to emqx_conf:get/2

* fix: common test failed

* fix: badmatch by typo wrong key

* fix(emqx_conf): get the wrong core nodes

* fix(emqx_conf): get core node's tnx_id not latest tnx_id

* fix: add ro_transation when copy conf file

* fix: delete debug info

* fix: change ekka_rlog to mria_rlog

* fix: remove cluster_rpc from emqx_machine.

* fix: don't call ekka:start/0 explicitly

* fix: ekka should be start in emqx_machine
2021-10-21 18:08:51 +08:00
k32
37a1c45af0 fix(dialyzer): Fix problems found by dialyzer 2021-10-18 22:04:05 +02:00
k32
07ea6e5689 fix(mria): Fix startup sequence 2021-10-18 22:04:05 +02:00
k32
d14b8e7da9 chore(mria): ekka_rlog -> mria_rlog 2021-10-18 22:04:05 +02:00
k32
326923850c chore(mria): Get rid of copy_mnesia callback 2021-10-18 22:04:05 +02:00
k32
e14a62d4d6 chore(mria): ekka_mnesia:start/stop -> mria:start/stop 2021-10-18 22:04:05 +02:00
k32
9965d6e028 chore(mria): ekka_mnesia:create_table -> mria:create_table 2021-10-18 22:04:05 +02:00
k32
ae2056da1b chore(mria): Fix clear_table and ro_transaction calls 2021-10-18 22:04:05 +02:00
k32
ff48322e0c chore(mria): ekka_mnesia:running_nodes -> mria:running_nodes 2021-10-18 22:04:05 +02:00
k32
b515a45a4f chore(mria): Rename module: ekka_mnesia -> mria 2021-10-18 22:04:05 +02:00
zhongwencool
c73205a589
Ct helpers migrate (#5943)
* chore: common test

* chore: delete emqx_ct_helpers deps
2021-10-18 13:45:52 +08:00
Tobias Lindahl
aa19c2a908 chore: Remove emqx_ct_helpers as dependency 2021-10-15 10:40:57 +02:00
Zaiming (Stone) Shi
c5b2bc86a2
chore(dashboard): enable by default (#5926) 2021-10-14 21:05:02 +08:00
lafirest
8a2c5e2422 feat(rate_limiter): implement hierarchical token buckets 2021-10-14 10:20:05 +08:00
zhongwencool
d80f20aca3
feat(swagger): define mgmt config_api by hocon schema (#5814)
* feat(swagger): define mgmt config_api by hocon schema

* fix: enum can't defined by integer, use union.

* fix: hocon schema union to enum
2021-10-13 14:04:43 +08:00
lafirest
3524942766 fix: change all ~s in io format to ~ts
we should use unicode to replace latin1
2021-10-12 15:09:24 +08:00
Zaiming Shi
e9991dca02 chore(dashboard): Allow test mode of the dashboard 2021-09-30 09:28:47 +02:00
DDDHuang
e62af95d0d fix: close dashboard before beta 1 2021-09-30 09:45:48 +08:00
zhongwencool
776604a90b chore(dashboard): make dirty operation into ekka_mnesia transation 2021-09-26 21:42:26 +08:00
zhongwencool
cae79a0584 feat(swagger): move public page/limit/error_code to emqx_dashboard_swagger module 2021-09-24 21:51:53 +08:00
zhongwencool
7e494afd98 fix(swagger): desc must be binary 2021-09-24 15:55:49 +08:00
zhongwencool
8c441673c2 feat(delayed_api): support hocon schema 2021-09-24 15:22:05 +08:00
Zaiming Shi
97e1cf65b7 refactor(schema): make a client ssl options schema
client and server ssl options share some common fields
this commit make an abstraction for the common fields
then export server_ssl_options_schema/2 and client_ssl_options_schema/1
for other schema modules to call
2021-09-23 16:56:02 +02:00
Zaiming Shi
fbd5701989 fix(emqx_schema): make ssl config schema right 2021-09-23 16:56:02 +02:00
zhongwencool
29b96bae2e fix(dashboard): create user return 405 2021-09-23 11:25:02 +08:00
zhongwencool
085d8e8efa chore(schema): restore space 2021-09-22 16:41:00 +08:00
zhongwencool
96fad3d225 chore(swagger): support check_schema option, default is false. 2021-09-22 13:37:08 +08:00
zhongwencool
39423665e9 chore(swagger): check hocon schema with #{override_env => false} 2021-09-22 09:07:14 +08:00
zhongwencool
dab5fbf285 feat(swagger): swagger support hocon schema 2021-09-21 21:41:16 +08:00
JimMoen
deac54c847 chore(for editor): Add comments for Emacs major mode. 2021-09-16 15:43:30 +08:00
DDDHuang
9a09bf7964
fix: logout api delete token (#5686) 2021-09-10 09:20:16 +08:00
DDDHuang
f87a41a54f
fix: api support basic auth (#5687) 2021-09-08 19:58:04 +08:00
DDDHuang
e2d9d9bfcb
fix: banned api rfc time & login hidden error type (#5681) 2021-09-08 17:53:52 +08:00
Zaiming Shi
ec13463f4a refactor(schema): prepare for hocon schema doc generation 2021-09-03 11:02:31 +02:00
DDDHuang
c4e279bb76
fix: support https (#5606)
* fix: support https
2021-09-01 16:44:34 +08:00