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

Try to stabilize rooms for rosters #2319

Merged
merged 2 commits into from
May 27, 2019

Conversation

aleklisi
Copy link
Contributor

This PR addresses #

Proposed changes include:

  • describe the functionality changes
  • describe new or updated tests
  • describe changes to the documentation

@codecov
Copy link

codecov bot commented May 26, 2019

Codecov Report

Merging #2319 into gdpr-retrieve-mam will decrease coverage by 13.98%.
The diff coverage is 100%.

Impacted file tree graph

@@                  Coverage Diff                   @@
##           gdpr-retrieve-mam    #2319       +/-   ##
======================================================
- Coverage              76.74%   62.76%   -13.99%     
======================================================
  Files                    334      334               
  Lines                  29154    29152        -2     
======================================================
- Hits                   22374    18297     -4077     
- Misses                  6780    10855     +4075
Impacted Files Coverage Δ
src/mod_roster.erl 75.98% <100%> (-4.12%) ⬇️
src/mod_auth_token_rdbms.erl 0% <0%> (-100%) ⬇️
src/mod_aws_sns.erl 0% <0%> (-100%) ⬇️
src/inbox/mod_inbox_rdbms_mysql.erl 0% <0%> (-100%) ⬇️
src/mam/mam_message_compressed_eterm.erl 0% <0%> (-100%) ⬇️
src/inbox/mod_inbox_muclight.erl 0% <0%> (-100%) ⬇️
src/inbox/mod_inbox_rdbms_pgsql.erl 0% <0%> (-100%) ⬇️
src/mam/mam_jid.erl 0% <0%> (-100%) ⬇️
src/mam/mam_jid_mini.erl 0% <0%> (-100%) ⬇️
src/inbox/mod_inbox_one2one.erl 0% <0%> (-100%) ⬇️
... and 127 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 070f079...e161e3c. Read the comment docs.

@DenysGonchar DenysGonchar force-pushed the Try-to-stabilize-rooms-for-rosters branch from 3616af3 to 0908a11 Compare May 26, 2019 15:42
@DenysGonchar
Copy link
Collaborator

it doesn't matter how much time we wait for the change in the roster. room doesn't appear at all. to repeate the issue we have to run 3 suites one after another:

  • gdpr
  • mam
  • muc_light

to reproduce locally run:
test-runner.sh --preset riak_mnesia --skip-small-tests --skip-cover gdpr mam muc_light

@DenysGonchar
Copy link
Collaborator

DenysGonchar commented May 27, 2019

to be more specific problem is caused by the failure in end_per_group/2 function for riak_timed_yz_buckets_muc_light group in the mam suite:

=== Reason: {badrpc,timeout}
  in function  escalus_rpc:call_with_cookie_match/6
     called as escalus_rpc:call_with_cookie_match(mongooseim@localhost,
                                                  mod_muc_light_db_backend,
                                                  force_clear,[],5000,
                                                  ejabberd)
  in call from mam_SUITE:end_state/3 (mam_SUITE.erl, line 874)
  in call from mam_SUITE:end_per_group/2 (mam_SUITE.erl, line 660)
  in call from test_server:ts_tc/3 (test_server.erl, line 1539)
  in call from test_server:run_test_case_eval1/6 (test_server.erl, line 1140)
  in call from test_server:run_test_case_eval/9 (test_server.erl, line 987)

crash in the end_state/3 blocks execution of end_modules/3 function, and so prevents correct stop of the mod_muc_light module:

  657: end_per_group(Group, Config) ->
  658:     C = configuration(Group),
  659:     B = basic_group(Group),
  660:     Config1 = end_state(C, B, Config),
  661:     Config2 = end_modules(C, B, Config1),
  662:     escalus_fresh:clean(),
  663:     delete_users(Config2).
  ...
  823: end_modules(C, muc_light, Config) ->
  824:     end_modules(C, generic, Config),
  825:     dynamic_modules:stop(host(), mod_muc_light),
  826:     Config;
  827: end_modules(_, _, Config) ->
  828:     [stop_module(host(), M) || M <- mam_modules()],
  829:     Config.

test command:

test-runner.sh --preset riak_mnesia --skip-small-tests --skip-cover gdpr mam:riak_timed_yz_buckets_muc_light muc_light

the root cause

gdpr suite doesn't remove muc_light rooms gracefully, so having it executed before mam suite results in longer execution of mod_muc_light_db_backend:force_clear/0

@DenysGonchar DenysGonchar force-pushed the Try-to-stabilize-rooms-for-rosters branch from 180d0a3 to e161e3c Compare May 27, 2019 03:37
@DenysGonchar DenysGonchar merged commit 7818076 into gdpr-retrieve-mam May 27, 2019
@DenysGonchar DenysGonchar deleted the Try-to-stabilize-rooms-for-rosters branch May 27, 2019 03:39
@DenysGonchar DenysGonchar mentioned this pull request May 28, 2019
@fenek fenek added this to the MongooseIM 3.3.0++ milestone Jun 18, 2019
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