8000 fix: add handle_frame_error/2 to all gateway implementations by terry-xiaoyu · Pull Request #14068 · emqx/emqx · GitHub
[go: up one dir, main page]

Skip to content

Conversation

@terry-xiaoyu
Copy link
Member

Fixes https://emqx.atlassian.net/browse/EMQX-13324

Release version: v/e5.8.2

Summary

Add handle_frame_error/2 to all gateway implementations. The log msg before this improvement:

peername: 165.154.187.159:33277, pid: <0.6272732.0>, mfa: {proc_lib,crash_report,4}, line: 584, domain: ["otp","sasl"], error_logger: {"type":"crash_report","tag":"error_report"}, logger_formatter: {"title":"CRASH REPORT"}, msg: crasher: initial call: emqx_gateway_conn:init/6, pid: <0.6272732.0>, registered_name: [], exit: {#{context => function_clause,stacktrace => [{emqx_coap_tm,handle_response,[{frame_error,{case_clause,<<119,15,15,50,114,49,58,121,49,58,113,101>>}},#{seq_id => 1,next_msg_id => 46596}],[{file,"emqx_coap_tm.erl"},{line,107}]},{emqx_coap_session,call_transport_manager,3,[{file,"emqx_coap_session.erl"},{line,210}]},{emqx_coap_channel,call_session,3,[{file,"emqx_coap_channel.erl"},{line,660}]},{emqx_gateway_conn,with_channel,3,[{file,"emqx_gateway_conn.erl"},{line,764}]},{emqx_gateway_conn,process_msg,2,[{file,"emqx_gateway_conn.erl"},{line,405}]},{emqx_gateway_conn,process_msg,2,[{file,"emqx_gateway_conn.erl"},{line,411}]},{emqx_gateway_conn,handle_recv,3,[{file,"emqx_gateway_conn.erl"},{line,368}]},{proc_lib,wake_up,3,[{file,"proc_lib.erl"},{line,251}]}],exception => error},[{emqx_gateway_conn,terminate,2,[{file,"emqx_gateway_conn.erl"},{line,589}]},{proc_lib,wake_up,3,[{file,"proc_lib.erl"},{line,251}]}]}, ancestors: [<0.79807.0>,esockd_sup,<0.7918.0>], message_queue_len: 0, messages: [], links: [<0.79807.0>], dictionary: [{guid,{1717780864255652,280534385145564,0}},{'$logger_metadata$',#{peername => "165.154.187.159:33277"}},{recv_pkt,1},{rand_seed,{#{max => 288230376151711743,type => exsplus,next => #Fun<rand.5.65977474>,jump => #Fun<rand.3.65977474>},[146379038149129835|181989433281042079]}},{incoming_bytes,75}], trap_exit: false, status: running, heap_size: 2586, stack_size: 28, reductions: 7455; neighbours: 
    

PR Checklist

Please convert it to a draft if any of the following conditions are not met. Reviewers may skip over until all the items are checked:

  • Added tests for the changes
  • Added property-based tests for code which performs user input validation
  • Changed lines covered in coverage report
  • Change log has been added to changes/(ce|ee)/(feat|perf|fix|breaking)-<PR-id>.en.md files
  • For internal contributor: there is a jira ticket to track this change
  • Created PR to emqx-docs if documentat 8000 ion update is required, or link to a follow-up jira ticket
  • Schema changes are backward compatible

Checklist for CI (.github/workflows) changes

  • If changed package build workflow, pass this action (manual trigger)
  • Change log has been added to changes/ dir for user-facing artifacts update

@terry-xiaoyu terry-xiaoyu requested review from a team and lafirest as code owners October 24, 2024 04:06
@terry-xiaoyu terry-xiaoyu requested a review from HJianBo October 24, 2024 05:45
@terry-xiaoyu terry-xiaoyu force-pushed the improve-log-readability-gateway-frame-error branch from b062b9e to a76ed41 Compare October 24, 2024 06:11
@terry-xiaoyu terry-xiaoyu force-pushed the improve-log-readability-gateway-frame-error branch from a76ed41 to 4003689 Compare October 24, 2024 06:13
@terry-xiaoyu terry-xiaoyu merged commit ce433e7 into emqx:release-58 Oct 24, 2024
195 checks passed
@terry-xiaoyu terry-xiaoyu deleted the improve-log-readability-gateway-frame-error branch October 24, 2024 07:37
@emqxqa
Copy link
emqxqa commented Oct 28, 2024

TestExecution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

0