Skip to content

Conversation

@telezynski
Copy link
Member

@telezynski telezynski commented Dec 15, 2025

This PR addresses flaky tests:

• mam_SUITE:muc_message_with_stanzaid

  • elastic search archive: retry when delete_by_query fails

• pubsub_SUITE:send_last_published_item_no_items_test

  • rdbms backend: (it was failing often for cockroachdb) - retry when transaction fails

@mongoose-im

This comment was marked as outdated.

@codecov
Copy link

codecov bot commented Dec 15, 2025

Codecov Report

❌ Patch coverage is 54.16667% with 11 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.12%. Comparing base (903eebf) to head (d582886).
⚠️ Report is 56 commits behind head on master.

Files with missing lines Patch % Lines
src/mam/mod_mam_muc_elasticsearch_arch.erl 50.00% 5 Missing ⚠️
src/rdbms/mongoose_rdbms_cockroachdb.erl 61.53% 5 Missing ⚠️
src/rdbms/mongoose_rdbms.erl 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4601      +/-   ##
==========================================
+ Coverage   86.03%   86.12%   +0.08%     
==========================================
  Files         563      563              
  Lines       33752    33772      +20     
==========================================
+ Hits        29039    29086      +47     
+ Misses       4713     4686      -27     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from 1d0e5a5 to 39b31ee Compare December 18, 2025 19:53
@mongoose-im

This comment was marked as outdated.

@mongoose-im

This comment was marked as outdated.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from 56d1dd5 to b6bf806 Compare January 12, 2026 15:27
@mongoose-im

This comment was marked as outdated.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from b6bf806 to 5477026 Compare January 13, 2026 22:42
@mongoose-im

This comment was marked as outdated.

@telezynski telezynski changed the title Retry on version conflicts when using elasitic_search Fix flaky tests for mam and pubsub Jan 14, 2026
@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from 5477026 to c79c0f2 Compare January 14, 2026 10:51
@mongoose-im

This comment was marked as outdated.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from c79c0f2 to c0e10e8 Compare January 15, 2026 08:34
@mongoose-im

This comment was marked as outdated.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from c0e10e8 to c22a5cb Compare January 15, 2026 14:42
@mongoose-im

This comment was marked as outdated.

@mongoose-im

This comment was marked as outdated.

@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from 9182d0e to 75982d6 Compare January 19, 2026 09:35
@mongoose-im
Copy link
Collaborator

mongoose-im commented Jan 19, 2026

CircleCI results for 75982d6

elasticsearch_and_cassandra_28 / elasticsearch_and_cassandra_mnesia / 75982d6
Reports root/ big
OK: 683 / Failed: 0 / User-skipped: 72 / Auto-skipped: 0

small_tests_27 / small_tests / 75982d6
Reports root / small

small_tests_28 / small_tests / 75982d6
Reports root / small

small_tests_28_arm64 / small_tests / 75982d6
Reports root / small

ldap_mnesia_27 / ldap_mnesia / 75982d6
Reports root/ big
OK: 2359 / Failed: 0 / User-skipped: 1378 / Auto-skipped: 0

ldap_mnesia_28 / ldap_mnesia / 75982d6
Reports root/ big
OK: 2359 / Failed: 0 / User-skipped: 1378 / Auto-skipped: 0

dynamic_domains_pgsql_mnesia_28 / pgsql_mnesia / 75982d6
Reports root/ big
OK: 5234 / Failed: 0 / User-skipped: 122 / Auto-skipped: 0

dynamic_domains_pgsql_mnesia_27 / pgsql_mnesia / 75982d6
Reports root/ big
OK: 5234 / Failed: 0 / User-skipped: 122 / Auto-skipped: 0

dynamic_domains_mysql_redis_28 / mysql_redis / 75982d6
Reports root/ big
OK: 5199 / Failed: 0 / User-skipped: 157 / Auto-skipped: 0

pgsql_cets_28 / pgsql_cets / 75982d6
Reports root/ big
OK: 5324 / Failed: 0 / User-skipped: 202 / Auto-skipped: 0

internal_mnesia_28 / internal_mnesia / 75982d6
Reports root/ big
OK: 2507 / Failed: 0 / User-skipped: 1230 / Auto-skipped: 0

cockroachdb_cets_28 / cockroachdb_cets / 75982d6
Reports root/ big
OK: 5324 / Failed: 0 / User-skipped: 202 / Auto-skipped: 0

pgsql_mnesia_27 / pgsql_mnesia / 75982d6
Reports root/ big
OK: 5627 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0

mysql_redis_28 / mysql_redis / 75982d6
Reports root/ big
OK: 20 / Failed: 0 / User-skipped: 0 / Auto-skipped: 0

pgsql_mnesia_28 / pgsql_mnesia / 75982d6
Reports root/ big
OK: 5627 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0

@telezynski telezynski marked this pull request as ready for review January 19, 2026 10:36
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 added some comments.

Andrzej Telezynski added 2 commits January 20, 2026 11:54
The retry is necessary as quite often cockrachdb fails with message
"restart transaction: TransactionRetryWithProtoRefreshError: WriteTooOldError".
Retrying the query is a recommended operation in this case.
@telezynski telezynski force-pushed the MIM-2511_remove_archive branch from 75982d6 to d582886 Compare January 20, 2026 10:55
@mongoose-im
Copy link
Collaborator

mongoose-im commented Jan 20, 2026

CircleCI results for d582886

elasticsearch_and_cassandra_28 / elasticsearch_and_cassandra_mnesia / d582886
Reports root/ big
OK: 683 / Failed: 0 / User-skipped: 72 / Auto-skipped: 0

small_tests_28 / small_tests / d582886
Reports root / small

small_tests_27 / small_tests / d582886
Reports root / small

small_tests_28_arm64 / small_tests / d582886
Reports root / small

ldap_mnesia_27 / ldap_mnesia / d582886
Reports root/ big
OK: 2359 / Failed: 0 / User-skipped: 1378 / Auto-skipped: 0

ldap_mnesia_28 / ldap_mnesia / d582886
Reports root/ big
OK: 2359 / Failed: 0 / User-skipped: 1378 / Auto-skipped: 0

dynamic_domains_pgsql_mnesia_27 / pgsql_mnesia / d582886
Reports root/ big
OK: 5234 / Failed: 0 / User-skipped: 122 / Auto-skipped: 0

dynamic_domains_pgsql_mnesia_28 / pgsql_mnesia / d582886
Reports root/ big
OK: 5234 / Failed: 0 / User-skipped: 122 / Auto-skipped: 0

internal_mnesia_28 / internal_mnesia / d582886
Reports root/ big
OK: 2507 / Failed: 0 / User-skipped: 1230 / Auto-skipped: 0

dynamic_domains_mysql_redis_28 / mysql_redis / d582886
Reports root/ big
OK: 5199 / Failed: 0 / User-skipped: 157 / Auto-skipped: 0

pgsql_cets_28 / pgsql_cets / d582886
Reports root/ big
OK: 5324 / Failed: 0 / User-skipped: 202 / Auto-skipped: 0

mysql_redis_28 / mysql_redis / d582886
Reports root/ big
OK: 5620 / Failed: 0 / User-skipped: 149 / Auto-skipped: 0

cockroachdb_cets_28 / cockroachdb_cets / d582886
Reports root/ big
OK: 632 / Failed: 0 / User-skipped: 0 / Auto-skipped: 0

pgsql_mnesia_28 / pgsql_mnesia / d582886
Reports root/ big
OK: 5627 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0

pgsql_mnesia_27 / pgsql_mnesia / d582886
Reports root/ big
OK: 5627 / Failed: 0 / User-skipped: 142 / Auto-skipped: 0

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.

👌

@chrzaszcz chrzaszcz merged commit 107cfbf into master Jan 21, 2026
3 of 4 checks passed
@chrzaszcz chrzaszcz deleted the MIM-2511_remove_archive branch January 21, 2026 10:14
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