Skip to content
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

Map options for mod_muc_light #3580

Merged
merged 7 commits into from
Mar 9, 2022
Merged

Map options for mod_muc_light #3580

merged 7 commits into from
Mar 9, 2022

Conversation

chrzaszcz
Copy link
Member

@chrzaszcz chrzaszcz commented Mar 8, 2022

Put mod_muc_light opts in a map with defaults.

Other changes:

  • It was necessary to remove deps from mod_inbox - see the commit message for details.

@mongoose-im

This comment was marked as outdated.

@codecov
Copy link

codecov bot commented Mar 8, 2022

Codecov Report

Merging #3580 (06a1100) into master (7aff549) will increase coverage by 1.58%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3580      +/-   ##
==========================================
+ Coverage   79.26%   80.84%   +1.58%     
==========================================
  Files         424      424              
  Lines       32274    32265       -9     
==========================================
+ Hits        25581    26085     +504     
+ Misses       6693     6180     -513     
Impacted Files Coverage Δ
src/inbox/mod_inbox.erl 87.77% <100.00%> (-0.34%) ⬇️
src/muc_light/mod_muc_light.erl 85.50% <100.00%> (-0.22%) ⬇️
src/muc_light/mod_muc_light_cache.erl 85.71% <100.00%> (ø)
src/muc_light/mod_muc_light_room.erl 94.04% <100.00%> (ø)
src/muc_light/mod_muc_light_utils.erl 91.00% <100.00%> (ø)
src/muc_light/mod_muc_light_db_mnesia.erl 89.47% <0.00%> (-2.11%) ⬇️
src/domain/mongoose_domain_loader.erl 89.28% <0.00%> (-0.90%) ⬇️
src/mod_muc_room.erl 76.80% <0.00%> (-0.29%) ⬇️
src/pubsub/mod_pubsub.erl 73.31% <0.00%> (+0.17%) ⬆️
src/mod_roster.erl 79.23% <0.00%> (+0.47%) ⬆️
... and 16 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7aff549...06a1100. Read the comment docs.

@chrzaszcz chrzaszcz changed the title WIP Map options for mod_muc_light Mar 8, 2022
@chrzaszcz chrzaszcz force-pushed the mod_muc_light-map branch 2 times, most recently from fe288ea to 9702d83 Compare March 9, 2022 09:00
@mongoose-im

This comment was marked as outdated.

@mongoose-im

This comment was marked as outdated.

@mongoose-im

This comment was marked as outdated.

@chrzaszcz chrzaszcz force-pushed the mod_muc_light-map branch from 30e851b to b564b05 Compare March 9, 2022 10:35
Motivation:
- The new config with defaults would make deps without opts fail
- These modules should not be started implicitly anyway.

We should consider a new kind of dependency in the future, called
'required', that will require the user to configure the modules explicitly.
Also:
- Make the schema error more user-friendly
@chrzaszcz chrzaszcz force-pushed the mod_muc_light-map branch from b564b05 to c196d55 Compare March 9, 2022 10:38
@mongoose-im

This comment was marked as outdated.

@mongoose-im

This comment was marked as outdated.

- Do not set the host when the default one is used
- Save, ensure and restore modules in push_SUITE
- Remove unused code
There is no reason for them to be different.
@chrzaszcz chrzaszcz force-pushed the mod_muc_light-map branch from c196d55 to 06a1100 Compare March 9, 2022 10:55
@mongoose-im
Copy link
Collaborator

mongoose-im commented Mar 9, 2022

small_tests_24 / small_tests / 06a1100
Reports root / small


small_tests_23 / small_tests / 06a1100
Reports root / small


dynamic_domains_mysql_redis_24 / mysql_redis / 06a1100
Reports root/ big
OK: 2756 / Failed: 0 / User-skipped: 150 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / 06a1100
Reports root/ big
OK: 2773 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / 06a1100
Reports root/ big
OK: 2773 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


ldap_mnesia_24 / ldap_mnesia / 06a1100
Reports root/ big
OK: 1503 / Failed: 1 / User-skipped: 399 / Auto-skipped: 0

sm_SUITE:parallel_unacknowledged_message_hook:unacknowledged_message_hook_bounce
{error,
  {{assertion_failed,assert,is_chat_message,
     [<<"msg-1">>],
     {xmlel,<<"message">>,
       [{<<"from">>,
         <<"bOb_unacknowledged_message_hook_bounce_1395@localhost/escalus-default-resource">>},
        {<<"to">>,
         <<"alicE_unacknowledged_message_hook_bounce_1398@localhost">>},
        {<<"xml:lang">>,<<"en">>},
        {<<"type">>,<<"chat">>}],
       [{xmlel,<<"body">>,[],[{xmlcdata,<<"msg-2">>}]},
        {xmlel,<<"delay">>,
          [{<<"xmlns">>,<<"urn:xmpp:delay">>},
           {<<"stamp">>,<<"2022-03-09T11:09:51.705770Z">>},
           {<<"from">>,<<"localhost">>}],
          [{xmlcdata,<<"SM Storage">>}]}]},
     "<message from='bOb_unacknowledged_message_hook_bounce_1395@localhost/escalus-default-resource' to='alicE_unacknowledged_message_hook_bounce_1398@localhost' xml:lang='en' type='chat'><body>msg-2</body><delay xmlns='urn:xmpp:delay' stamp='2022-03-09T11:09:51.705770Z' from='localhost'>SM Storage</delay></message>"},
   [{escalus_new_assert,assert_true,2,
      [{file,
         "/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_new_assert.erl"},
       {line,84}]},
    {sm_SUITE,unacknowledged_message_hook_common,2,
      [{file,"/home/circleci/project/big_tests/tests/sm_SUITE.erl"},
       {line,805}]},
    {test_server,ts_tc,3,[{file,"test_server.erl"},{line,1783}]},
    {test_server,run_test_case_eval1,6,
      [{file,"test_server.erl"},{line,1292}]},
    {test_server,run_test_case_eval,9,
      [{file,"tes...

Report log


dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / 06a1100
Reports root/ big
OK: 2773 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


ldap_mnesia_23 / ldap_mnesia / 06a1100
Reports root/ big
OK: 1504 / Failed: 0 / User-skipped: 399 / Auto-skipped: 0


internal_mnesia_24 / internal_mnesia / 06a1100
Reports root/ big
OK: 1545 / Failed: 0 / User-skipped: 358 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / 06a1100
Reports root/ big
OK: 3147 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / 06a1100
Reports root/ big
OK: 1846 / Failed: 0 / User-skipped: 366 / Auto-skipped: 0


pgsql_mnesia_23 / pgsql_mnesia / 06a1100
Reports root/ big
OK: 3147 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


mysql_redis_24 / mysql_redis / 06a1100
Reports root/ big
OK: 3142 / Failed: 0 / User-skipped: 147 / Auto-skipped: 0


mssql_mnesia_24 / odbc_mssql_mnesia / 06a1100
Reports root/ big
OK: 3147 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


riak_mnesia_24 / riak_mnesia / 06a1100
Reports root/ big
OK: 1692 / Failed: 0 / User-skipped: 365 / Auto-skipped: 0


ldap_mnesia_24 / ldap_mnesia / 06a1100
Reports root/ big
OK: 1504 / Failed: 0 / User-skipped: 399 / Auto-skipped: 0

@chrzaszcz chrzaszcz marked this pull request as ready for review March 9, 2022 11:20
Copy link
Contributor

@gustawlippa gustawlippa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! 👍

@gustawlippa gustawlippa merged commit 6e3fd8a into master Mar 9, 2022
@gustawlippa gustawlippa deleted the mod_muc_light-map branch March 9, 2022 13:59
@Premwoik Premwoik added this to the 5.1.0 milestone May 25, 2022
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.

4 participants