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

Simplify specs for ejabberd_sup and let workers terminate (no brutal_kill) #4117

Merged
merged 1 commit into from
Sep 6, 2023

Conversation

NelsonVides
Copy link
Collaborator

@NelsonVides NelsonVides commented Sep 6, 2023

This will hit workers' terminate callbacks, increasing code coverage btw, but mostly also letting MIM properly cleanup on termination.
Also extracts common code to a bunch of helpers to create the children definitions.

@mongoose-im
Copy link
Collaborator

mongoose-im commented Sep 6, 2023

elasticsearch_and_cassandra_25 / elasticsearch_and_cassandra_mnesia / 98a6286
Reports root/ big
OK: 369 / Failed: 0 / User-skipped: 38 / Auto-skipped: 0


small_tests_24 / small_tests / 98a6286
Reports root / small


small_tests_25 / small_tests / 98a6286
Reports root / small


small_tests_25_arm64 / small_tests / 98a6286
Reports root / small


ldap_mnesia_24 / ldap_mnesia / 98a6286
Reports root/ big
OK: 2275 / Failed: 0 / User-skipped: 833 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / 98a6286
Reports root/ big
OK: 4236 / Failed: 0 / User-skipped: 84 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_25 / pgsql_mnesia / 98a6286
Reports root/ big
OK: 4236 / Failed: 0 / User-skipped: 84 / Auto-skipped: 0


ldap_mnesia_25 / ldap_mnesia / 98a6286
Reports root/ big
OK: 2275 / Failed: 0 / User-skipped: 833 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_25 / odbc_mssql_mnesia / 98a6286
Reports root/ big
OK: 4233 / Failed: 0 / User-skipped: 87 / Auto-skipped: 0


dynamic_domains_mysql_redis_25 / mysql_redis / 98a6286
Reports root/ big
OK: 4204 / Failed: 0 / User-skipped: 116 / Auto-skipped: 0


internal_mnesia_25 / internal_mnesia / 98a6286
Reports root/ big
OK: 2421 / Failed: 0 / User-skipped: 687 / Auto-skipped: 0


pgsql_cets_25 / pgsql_cets / 98a6286
Reports root/ big
OK: 4595 / Failed: 0 / User-skipped: 121 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / 98a6286
Reports root/ big
OK: 4625 / Failed: 0 / User-skipped: 91 / Auto-skipped: 0


pgsql_mnesia_25 / pgsql_mnesia / 98a6286
Reports root/ big
OK: 4625 / Failed: 0 / User-skipped: 91 / Auto-skipped: 0


mysql_redis_25 / mysql_redis / 98a6286
Reports root/ big
OK: 4605 / Failed: 0 / User-skipped: 111 / Auto-skipped: 0


mssql_mnesia_25 / odbc_mssql_mnesia / 98a6286
Reports root/ big
OK: 4620 / Failed: 2 / User-skipped: 94 / Auto-skipped: 0

s2s_SUITE:node1_tls_optional_node2_tls_required:simple_message
{error,
  {timeout_when_waiting_for_stanza,
    [{escalus_client,wait_for_stanza,
       [{client,<<"alice_simple_message_3272@localhost/res1">>,
          escalus_tcp,<0.20136.2>,
          [{event_manager,<0.20131.2>},
           {server,<<"localhost">>},
           {username,<<"alicE_simple_message_3272">>},
           {resource,<<"res1">>}],
          [{event_client,
             [{event_manager,<0.20131.2>},
            {server,<<"localhost">>},
            {username,<<"alicE_simple_message_3272">>},
            {resource,<<"res1">>}]},
           {resource,<<"res1">>},
           {username,<<"alice_simple_message_3272">>},
           {server,<<"localhost">>},
           {host,<<"localhost">>},
           {port,5222},
           {auth,{escalus_auth,auth_plain}},
           {wspath,undefined},
           {username,<<"alicE_simple_message_3272">>},
           {server,<<"localhost">>},
           {password,<<"matygrysa">>},
           {stream_id,<<"1de9375a9826e53e">>}]},
        10000],
       [{file,
          "/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_client.erl"},
        {line,136}]},
     {s2s_SUITE,'-simple_message/1-fun-0-',2,
       [{file,"/home/circleci/project/big_tests/tests/s2s_SUITE.erl"},
        {line,145}]},
     {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,178...

Report log

s2s_SUITE:node1_tls_optional_node2_tls_required_trusted_with_cachain:simple_message
{error,
  {timeout_when_waiting_for_stanza,
    [{escalus_client,wait_for_stanza,
       [{client,<<"alice_simple_message_3276@fed1/res1">>,escalus_tcp,
          <0.20351.2>,
          [{event_manager,<0.20244.2>},
           {server,<<"fed1">>},
           {username,<<"alice_simple_message_3276">>},
           {resource,<<"res1">>}],
          [{event_client,
             [{event_manager,<0.20244.2>},
            {server,<<"fed1">>},
            {username,<<"alice_simple_message_3276">>},
            {resource,<<"res1">>}]},
           {resource,<<"res1">>},
           {username,<<"alice_simple_message_3276">>},
           {server,<<"fed1">>},
           {host,<<"localhost">>},
           {port,5242},
           {auth,{escalus_auth,auth_plain}},
           {wspath,undefined},
           {username,<<"alice_simple_message_3276">>},
           {server,<<"fed1">>},
           {host,<<"localhost">>},
           {port,5242},
           {password,<<"makota2">>},
           {stream_id,<<"e13c5bfe4ec40c01">>}]},
        10000],
       [{file,
          "/home/circleci/project/big_tests/_build/default/lib/escalus/src/escalus_client.erl"},
        {line,136}]},
     {s2s_SUITE,'-simple_message/1-fun-0-',2,
       [{file,"/home/circleci/project/big_tests/tests/s2s_SUITE.erl"},
        {line,138}]},
     {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,[{f...

Report log


small_tests_25 / small_tests / 98a6286
Reports root / small


mssql_mnesia_25 / odbc_mssql_mnesia / 98a6286
Reports root/ big
OK: 4622 / Failed: 0 / User-skipped: 94 / Auto-skipped: 0

@codecov
Copy link

codecov bot commented Sep 6, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (a09755a) 83.91% compared to head (98a6286) 83.92%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #4117   +/-   ##
=======================================
  Coverage   83.91%   83.92%           
=======================================
  Files         552      552           
  Lines       33624    33628    +4     
=======================================
+ Hits        28216    28221    +5     
+ Misses       5408     5407    -1     
Files Changed Coverage Δ
src/ejabberd_sup.erl 88.57% <100.00%> (+1.47%) ⬆️

... and 7 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@arcusfelis arcusfelis left a comment

Choose a reason for hiding this comment

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

ok

@NelsonVides NelsonVides marked this pull request as ready for review September 6, 2023 14:00
Copy link
Contributor

@arcusfelis arcusfelis left a comment

Choose a reason for hiding this comment

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

yea, ok, hope it does not slow down CI (because some processes like to stuck and we restart MIM a lot).

@arcusfelis arcusfelis merged commit a82233e into master Sep 6, 2023
4 checks passed
@arcusfelis arcusfelis deleted the sup/clean_termination branch September 6, 2023 14:07
@chrzaszcz chrzaszcz added this to the 6.2.0 milestone Dec 11, 2023
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