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

Make MAM return timestamps in microseconds #3595

Merged
merged 1 commit into from
Mar 18, 2022
Merged

Conversation

NelsonVides
Copy link
Collaborator

@NelsonVides NelsonVides commented Mar 17, 2022

No need to convert any of these TS to seconds, XMPP admits microseconds just fine, and client devices this way can ensure they'll display the messages in the right order, otherwise there's a risk of messages arriving within the same 1s window and therefore having the same timestamp.

Also, inbox show timestamps in microseconds, so it is just consistent.

@mongoose-im
Copy link
Collaborator

mongoose-im commented Mar 17, 2022

small_tests_23 / small_tests / f5038f9
Reports root / small


small_tests_24 / small_tests / f5038f9
Reports root / small


dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / f5038f9
Reports root/ big
OK: 2822 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / f5038f9
Reports root/ big
OK: 2822 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0


dynamic_domains_mysql_redis_24 / mysql_redis / f5038f9
Reports root/ big
OK: 2805 / Failed: 0 / User-skipped: 150 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / f5038f9
Reports root/ big
OK: 2821 / Failed: 1 / User-skipped: 133 / Auto-skipped: 0

service_domain_db_SUITE:db:db_keeps_syncing_after_cluster_join
{error,{test_case_failed,{[<<"example1.com">>,<<"example2.com">>,
               <<"example3.com">>],
              [<<"example1.com">>,<<"example2.com">>,
               <<"example3.com">>,<<"example4.com">>]}}}

Report log


ldap_mnesia_24 / ldap_mnesia / f5038f9
Reports root/ big
OK: 1505 / Failed: 0 / User-skipped: 399 / Auto-skipped: 0


internal_mnesia_24 / internal_mnesia / f5038f9
Reports root/ big
OK: 1546 / Failed: 0 / User-skipped: 358 / Auto-skipped: 0


ldap_mnesia_23 / ldap_mnesia / f5038f9
Reports root/ big
OK: 1505 / Failed: 0 / User-skipped: 399 / Auto-skipped: 0


pgsql_mnesia_24 / pgsql_mnesia / f5038f9
Reports root/ big
OK: 3196 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


pgsql_mnesia_23 / pgsql_mnesia / f5038f9
Reports root/ big
OK: 3196 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / f5038f9
Reports root/ big
OK: 1853 / Failed: 0 / User-skipped: 366 / Auto-skipped: 0


mysql_redis_24 / mysql_redis / f5038f9
Reports root/ big
OK: 3191 / Failed: 0 / User-skipped: 147 / Auto-skipped: 0


mssql_mnesia_24 / odbc_mssql_mnesia / f5038f9
Reports root/ big
OK: 3196 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0


riak_mnesia_24 / riak_mnesia / f5038f9
Reports root/ big
OK: 1696 / Failed: 0 / User-skipped: 365 / Auto-skipped: 0


dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / f5038f9
Reports root/ big
OK: 2822 / Failed: 0 / User-skipped: 133 / Auto-skipped: 0

@codecov
Copy link

codecov bot commented Mar 17, 2022

Codecov Report

Merging #3595 (f5038f9) into master (33d44ca) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #3595   +/-   ##
=======================================
  Coverage   80.86%   80.86%           
=======================================
  Files         426      426           
  Lines       32379    32378    -1     
=======================================
+ Hits        26182    26183    +1     
+ Misses       6197     6195    -2     
Impacted Files Coverage Δ
src/mam/mod_mam.erl 88.40% <100.00%> (-0.05%) ⬇️
src/mam/mod_mam_muc.erl 74.76% <100.00%> (ø)
src/mongoose_tcp_listener.erl 76.59% <0.00%> (-4.26%) ⬇️
...bal_distrib/mod_global_distrib_hosts_refresher.erl 71.69% <0.00%> (-1.89%) ⬇️
src/inbox/mod_inbox_rdbms_async.erl 65.51% <0.00%> (-1.73%) ⬇️
src/mod_muc_log.erl 63.21% <0.00%> (ø)
src/pubsub/mod_pubsub.erl 73.19% <0.00%> (+0.05%) ⬆️
src/offline/mod_offline.erl 77.17% <0.00%> (+1.08%) ⬆️
...rc/smart_markers/mod_smart_markers_rdbms_async.erl 88.88% <0.00%> (+3.70%) ⬆️
..._distrib/mod_global_distrib_outgoing_conns_sup.erl 88.00% <0.00%> (+8.00%) ⬆️

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 33d44ca...f5038f9. 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 👍

@chrzaszcz chrzaszcz merged commit 7d2da37 into master Mar 18, 2022
@chrzaszcz chrzaszcz deleted the mam_timestamps_unit branch March 18, 2022 07:10
@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.

None yet

4 participants