-
Notifications
You must be signed in to change notification settings - Fork 428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
C2s/refactor user send packet #3857
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
936c5c8
to
611afee
Compare
Codecov ReportBase: 72.11% // Head: 72.09% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## feature/mongoose_c2s #3857 +/- ##
========================================================
- Coverage 72.11% 72.09% -0.03%
========================================================
Files 534 534
Lines 34012 34009 -3
========================================================
- Hits 24527 24518 -9
- Misses 9485 9491 +6
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
small_tests_24 / small_tests / 611afee small_tests_25 / small_tests / 611afee ldap_mnesia_24 / ldap_mnesia / 611afee ldap_mnesia_25 / ldap_mnesia / 611afee dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / 611afee internal_mnesia_25 / internal_mnesia / 611afee pgsql_mnesia_24 / pgsql_mnesia / 611afee dynamic_domains_pgsql_mnesia_25 / pgsql_mnesia / 611afee mysql_redis_25 / mysql_redis / 611afee mod_event_pusher_rabbit_SUITE:group_chat_message_publish:group_chat_message_received_event_properly_formatted{error,
{{assertMatch,
[{module,mod_event_pusher_rabbit_SUITE},
{line,422},
{expression,
"get_decoded_message_from_rabbit ( AliceGroupChatMsgRecvRK )"},
{pattern,
"# { << \"from_user_id\" >> := BobRoomJID , << \"to_user_id\" >> := AliceFullJID , << \"message\" >> := Message }"},
{value,
#{<<"from_user_id">> => <<"muc_publish@muc.localhost">>,
<<"message">> => <<>>,
<<"to_user_id">> =>
<<"alice_unnamed_2052@localhost/res1">>}}]},
[{mod_event_pusher_rabbit_SUITE,
'-group_chat_message_received_event_properly_formatted/1-fun-1-',3,
[{file,
"/home/circleci/project/big_tests/tests/mod_event_pusher_rabbit_SUITE.erl"},
{line,422}]},
{escalus_story,story,4,
[{file,
"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
{line,72}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1782}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1291}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1223}]}]}} mod_event_pusher_rabbit_SUITE:group_chat_message_publish:group_chat_message_received_event_properly_formatted{error,
{{assertMatch,
[{module,mod_event_pusher_rabbit_SUITE},
{line,422},
{expression,
"get_decoded_message_from_rabbit ( AliceGroupChatMsgRecvRK )"},
{pattern,
"# { << \"from_user_id\" >> := BobRoomJID , << \"to_user_id\" >> := AliceFullJID , << \"message\" >> := Message }"},
{value,
#{<<"from_user_id">> =>
<<"muc_publish@muc.localhost/bob_unnamed_2053">>,
<<"message">> => <<"Hi there!">>,
<<"to_user_id">> =>
<<"alice_unnamed_2056@localhost/res1">>}}]},
[{mod_event_pusher_rabbit_SUITE,
'-group_chat_message_received_event_properly_formatted/1-fun-1-',3,
[{file,
"/home/circleci/project/big_tests/tests/mod_event_pusher_rabbit_SUITE.erl"},
{line,422}]},
{escalus_story,story,4,
[{file,
"/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_story.erl"},
{line,72}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1782}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1291}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1223}]}]}} dynamic_domains_mysql_redis_25 / mysql_redis / 611afee rest_SUITE:admin:session_can_be_kicked{error,{test_case_failed,[70,97,105,108,58,32,
[60,60,
"\"alice_session_can_be_kicked_2113@domain.example.com/res1\"",
62,62],
32,105,110,32,
[91,
[[60,60,
"\"alice_stanzas_are_sent_and_received_2116@domain.example.com/res1\"",
62,62],
44,10,
[32,
[[[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[60,60,
"\"alice_messages_can_be_paginated_2119@domain.example.com/res1\"",
62,62],
44,10,
[32,
[[[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[[32,[" ",32,32]," ",32,32],
32,
[" ",32,32],
" ",32,32],
[32,[" ",32,32]," ",32,32],
... elasticsearch_and_cassandra_25 / elasticsearch_and_cassandra_mnesia / 611afee dynamic_domains_mssql_mnesia_25 / odbc_mssql_mnesia / 611afee pgsql_mnesia_25 / pgsql_mnesia / 611afee dynamic_domains_mysql_redis_25 / mysql_redis / 611afee mysql_redis_25 / mysql_redis / 611afee mssql_mnesia_25 / odbc_mssql_mnesia / 611afee service_domain_db_SUITE:db:db_event_could_appear_with_lower_id{error,
{{badmatch,898},
[{service_domain_db_SUITE,db_event_could_appear_with_lower_id,1,
[{file,
"/home/circleci/project/big_tests/tests/service_domain_db_SUITE.erl"},
{line,723}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1782}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1291}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1223}]}]}} mssql_mnesia_25 / odbc_mssql_mnesia / 611afee |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good 👍
user_send_packet subscribers can really be split into different handlers for messages or presences as needed, considering most often they only need messages like in the case of MAM, inbox, or carbon-copies.
This PR also fixes usages of types that don't exist anymore:
mongoose_c2s:hook_result()
was moved tomongoose_c2s_hooks:hook_result()
, which in turn I here abbreviate tomongoose_c2s_hooks:result()
, as the module name already contains the fact that we're referring to hooks. Similarly for other types defined in thec2s_hooks
module.