You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I fixed a bug in the emqx.schema related to bridging.
Using a near-default emqx.conf:
## The Clean start flag of a remote bridge.
##
## Value: boolean
## Default: true
##
## NOTE: Some IoT platforms require clean_start
## must be set to 'true'
bridge.aws.clean_start = true
## The username for a remote bridge.
##
## Value: String
bridge.aws.username = user
## The password for a remote bridge.
##
## Value: String
bridge.aws.password = passwd
## Mountpoint of the bridge.
##
## Value: String
bridge.aws.mountpoint = bridge/aws/${node}/
## Forward message topics
##
## Value: String
## Example: topic1/#,topic2/#
bridge.aws.forwards = topic1/#,topic2/#
## Bribge to remote server via SSL.
##
## Value: on | off
bridge.aws.ssl = on
## PEM-encoded CA certificates of the bridge.
##
## Value: File
bridge.aws.cacertfile = {{ platform_etc_dir }}/certs/cacert.pem
## Client SSL Certfile of the bridge.
##
## Value: File
bridge.aws.certfile = {{ platform_etc_dir }}/certs/client-cert.pem
## Client SSL Keyfile of the bridge.
##
## Value: File
bridge.aws.keyfile = {{ platform_etc_dir }}/certs/client-key.pem
I was getting errors bridging because the sslopt was a deeply nested list due to a bug in emqx.schema.
I would happily submit a patch file in the future for stuff like this, or push directly to my own branch and make a pull request, but I don't have access and don't know how you all handle external contribution. Please let me know so that maybe next time I don't make an issue!
The text was updated successfully, but these errors were encountered:
Hate to keep bothering you all, but I believe I found 2 more bugs relating to the bridge..:
#1 was a Logging bug in emqx_bridge:351
?LOG(info, "Bridge p diconnectednreason=~p", [name(), Conn, Reason]), the ~n needs to be a ~p as there are 3 args.
#2 in emqx_message:set_headers, it doesn't properly handle the case where the headers are undefined due to the is_map() guard. So either we can remove the is_map guard or add a 3rd function overload:
set_headers(_Headers, Msg) ->
Msg;
I'm surprised no one has pointed these out because bridging seems impossible w/o these fixes
Thanks for your help!
We have done a major refactoring in bridge recently.
The schema issue was introduce 2 days ago which I do not know much in detail.
the other two embarrassing crashes are due to lack of test coverage.
Sending a PR to fix NOW.
Hi, I fixed a bug in the emqx.schema related to bridging.
Using a near-default emqx.conf:
I was getting errors bridging because the sslopt was a deeply nested list due to a bug in emqx.schema.
It's just one line, change:
I would happily submit a patch file in the future for stuff like this, or push directly to my own branch and make a pull request, but I don't have access and don't know how you all handle external contribution. Please let me know so that maybe next time I don't make an issue!
The text was updated successfully, but these errors were encountered: