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

Mam inbox unification #3165

Merged
merged 4 commits into from
Jul 1, 2021
Merged

Mam inbox unification #3165

merged 4 commits into from
Jul 1, 2021

Conversation

NelsonVides
Copy link
Collaborator

@NelsonVides NelsonVides commented Jun 30, 2021

If inbox is nothing more than a low-cost summary of mam, we can expect inbox to store pretty much what is stored in mam, and nothing else.

This is currently not true, as inbox is not taking into account no-store hints for example, and it is storing body-less messages, like for example it would store carbon copies.

Additionally, make both take the <store> hint as enforcing storage.

@codecov
Copy link

codecov bot commented Jun 30, 2021

Codecov Report

Merging #3165 (d99449c) into master (45c3308) will decrease coverage by 0.04%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3165      +/-   ##
==========================================
- Coverage   80.27%   80.23%   -0.05%     
==========================================
  Files         396      396              
  Lines       32260    32251       -9     
==========================================
- Hits        25896    25875      -21     
- Misses       6364     6376      +12     
Impacted Files Coverage Δ
src/inbox/mod_inbox.erl 90.15% <100.00%> (-0.05%) ⬇️
src/mam/mod_mam_utils.erl 89.96% <100.00%> (+0.06%) ⬆️
src/mod_roster_riak.erl 81.53% <0.00%> (-15.39%) ⬇️
src/ejabberd.erl 45.00% <0.00%> (-10.00%) ⬇️
src/mongoose_tcp_listener.erl 76.59% <0.00%> (-4.26%) ⬇️
src/mod_bosh.erl 91.89% <0.00%> (-2.03%) ⬇️
src/inbox/mod_inbox_entries.erl 96.72% <0.00%> (-1.64%) ⬇️
src/domain/service_domain_db.erl 78.12% <0.00%> (-1.57%) ⬇️
src/global_distrib/mod_global_distrib_utils.erl 64.48% <0.00%> (-0.94%) ⬇️
src/pubsub/mod_pubsub_db_mnesia.erl 92.40% <0.00%> (-0.43%) ⬇️
... and 5 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 45c3308...d99449c. Read the comment docs.

Copy link
Member

@chrzaszcz chrzaszcz 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 in general, I have two minor remarks.

big_tests/tests/inbox_SUITE.erl Outdated Show resolved Hide resolved
src/mam/mod_mam_utils.erl Outdated Show resolved Hide resolved
If inbox is nothing more than a low-cost summary of mam, we can expect
inbox to store pretty much what is stored in mam, and nothing else.
Copy link
Member

@chrzaszcz chrzaszcz left a comment

Choose a reason for hiding this comment

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

Nice, it's good to see the things unified.

@chrzaszcz chrzaszcz merged commit 2bb9c77 into master Jul 1, 2021
@chrzaszcz chrzaszcz deleted the mam_inbox_unification branch July 1, 2021 14:19
@Premwoik Premwoik added this to the 5.0.0 milestone Oct 5, 2021
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.

None yet

3 participants