Commit Graph

222 Commits

Author SHA1 Message Date
Karl Nilsson c9637355dc QQ: more prompt metrics after leader election 2025-03-17 17:19:57 +00:00
Jean-Sébastien Pédron 94b8ef6792
rabbitmq-components.mk: Update meck from 0.9.2 to 1.0.0
[Why]
Hopefully it will fix a crash we observe fairly regularily in CI.
2025-03-13 16:32:42 +01:00
Karl Nilsson 2efb9d7edc Ra 2.16.3 - bug fixes.
* Add num_segments to Ra counters
* ra_server_proc: Fix handling of local query replies
* Remove Bazel-related files by @mkuratczyk in #520
* Replication bug fixes that could cause replication to stall
* Use infinity timeout for ra_log_ets:mem_table_please
2025-03-13 12:15:22 +00:00
Michael Klishin ffcf9a27a4
Osiris 1.8.6 2025-03-01 19:26:08 -05:00
Loïc Hoguin 3e00c84e9f
Update Cowboy, Cowlib and Ranch
Cowboy 2.13 contains the Websocket optimisations as well
as the ability to set the Websocket max_frame_size option
dynamically, plus plenty of other improvements.

Cowlib was added as a test dep to rabbitmq_mqtt to make
sure emqtt doesn't pull the wrong Cowlib version for Cowboy.
2025-02-18 11:15:08 +01:00
Karl Nilsson 42db0c659c Ra v2.16.2
This is a bugfix release of Ra:

* Fix last_index counter lag
* Fix off by one in follower assertion
* Fix log divergence bug
2025-02-13 15:27:45 +00:00
zhongwencool b367b40786 Bump observer_cli to 1.8.2 2025-02-08 17:19:37 +08:00
Karl Nilsson 7931797761 Ra 2.16.1
Contains bug fix which would crash at-most-once dead lettering during
node restarts.

Less excessive debug logging around ra log.

Fix issue that could make leader transfers take 5s+ to complete.
2025-02-03 14:51:05 +00:00
Karl Nilsson 3a7a374190 Ra v2.16.0
This version of Ra contains a substantially refactored Ra log
implementation that provides higher throughput and lower
memory use in serveral scenarios.

New features:

* `log_ext` new effect type that instead of immedately reading
entries from the log it will instead provide a read plan for any
entries only located in segments.

* Machine version upgrades can now be be delayed until all
members are confirmed to support the new version.
This will avoid potential consumption pauses during upgrades.
2025-01-27 13:50:38 +00:00
Karl Nilsson 9ed8a3067c Ra 2.15.1
This version contains bug fixes and a change to use async_dist
when a quorum queue sends a message to a remote node (e.g. a consumer
delivery). Using async_dist will reduce chances of messages not
reaching consumers in a timely manner when the system is loaded
and occasionally fills the distribution buffer.
2025-01-22 14:31:13 +00:00
Karl Nilsson 675007a20b Update osiris to v1.8.5
This release contains a bug fix to an issue that very occasionally
could cause consumers on replica nodes not to be notified about
newly committed offsets in a timely manner.
2024-11-22 14:05:56 +00:00
Simon Unge 6cf211a1e1
Dependency thoas updated from 1.0.0 to 1.2.1
(cherry picked from commit 13bf5c005e)

Conflicts:
	rabbitmq-components.mk
(cherry picked from commit 679eaa1913)

Conflicts:
	rabbitmq-components.mk
2024-11-21 20:42:04 -05:00
Jean-Sébastien Pédron 7e59f38ad4
Bump khepri_mnesia_migration from 0.7.0 to 0.7.1
Release notes:
https://github.com/rabbitmq/khepri_mnesia_migration/releases/tag/v0.7.1
2024-11-18 10:35:11 +01:00
Karl Nilsson 5f4715979c Osiris v1.8.4
This osiris release contains a bug fix that would cause an osiris
member to crash during recovery if certain unexpected files
were present in the log directory. (.e.g ".nfsXXXXXXXXXXXX") type
files used by the NFS file system when in use files are deleted.
2024-11-12 10:20:38 +00:00
Michael Klishin 08064abf81
Revert "Bump observer_cli to 1.8.0" 2024-10-21 22:23:38 -04:00
zhongwencool 8f7232b742 Bump observer_cli to 1.8.0 2024-10-22 09:36:07 +08:00
Simon Unge 7702a92865 Dependency Recon updated from 2.5.3 to 2.5.6 2024-10-07 20:23:50 +00:00
Loïc Hoguin aee0cd0079
make & make CI: Small cleanups 2024-09-30 12:35:43 +02:00
Loïc Hoguin 5086553bdd
make: Correct rabbitmq_prelaunch/rabbitmq_stream_common deps 2024-09-30 12:35:42 +02:00
Loïc Hoguin f4f375c6a9
Use Make in CI
This is a proof of concept that mostly works but is missing
some tests, such as rabbitmq_mqtt or rabbitmq_cli. It also
doesn't apply to mixed version testing yet.
2024-09-30 12:35:41 +02:00
Loïc Hoguin 645942cf95
make: Move dep_osiris in rabbitmq-components.mk
Otherwise some plugins can't build if we try to run tests
directly after checkout. This is because the plugins
depend on osiris as well as rabbit, but there is no
dep_osiris defined in the plugin itself.
2024-09-30 12:35:41 +02:00
Jean-Sébastien Pédron 52969c8832
Bump khepri_mnesia_migration from 0.6.0 to 0.7.0
Release notes:
https://github.com/rabbitmq/khepri_mnesia_migration/releases/tag/v0.7.0
2024-09-12 22:49:28 +02:00
Jean-Sébastien Pédron 412691d618
Bump Khepri from 0.15.0 to 0.16.0
Release notes:
https://github.com/rabbitmq/khepri/releases/tag/v0.16.0
2024-09-12 22:48:03 +02:00
Jean-Sébastien Pédron be9e5d8029
Bump khepri_mnesia_migration from 0.5.0 to 0.6.0
Release notes:
https://github.com/rabbitmq/khepri_mnesia_migration/releases/tag/v0.6.0
2024-09-05 11:41:54 +02:00
Jean-Sébastien Pédron bc416757e8
Bump Khepri from 0.14.0 to 0.15.0
Release notes:
https://github.com/rabbitmq/khepri/releases/tag/v0.15.0
2024-09-05 11:36:45 +02:00
Jean-Sébastien Pédron b90a606f47
Bump Ra from 2.13.6 to 2.14.0
Release notes:
https://github.com/rabbitmq/ra/releases/tag/v2.14.0
2024-09-05 11:33:56 +02:00
Loïc Hoguin 5aefd919d3
make: Additional cleanup of RabbitMQ components
Because of the monorepo most components do not need to be
listed. Only the community plugins and third party dependencies.

Community plugins can now be fetched and acted on from the top
level Makefile by adding COMMUNITY_PLUGINS=1 to the command line
or the environment. This will fetch and build community plugins:

  make COMMUNITY_PLUGINS=1

Once fetched they can be targeted directly as usual:

  make -C deps/rabbitmq_metronome

This cleanup has a net positive effect on build performance,
especially the performance of the top-level Makefile:

  make nope  0,04s user 0,02s system 106% cpu 0,061 total
  make nope  0,02s user 0,01s system 104% cpu 0,033 total

But also a minor improvement for application Makefiles:

  make -C deps/rabbit nope  0,02s user 0,00s system 98% cpu 0,022 total
  make -C deps/rabbit nope  0,01s user 0,00s system 98% cpu 0,020 total

And that improvement adds up when going through dependencies:

  make -C deps/rabbitmq_management  0,59s user 0,23s system 100% cpu 0,808 total
  make -C deps/rabbitmq_management  0,60s user 0,19s system 101% cpu 0,780 total
2024-08-29 15:19:32 +02:00
Loïc Hoguin d4222f8216
make: Remove emptied rabbitmq-tools.mk 2024-08-29 15:19:14 +02:00
Loïc Hoguin 7cb0c1b217
make: Refactor PROJECT_VERSION computation 2024-08-29 15:19:14 +02:00
Loïc Hoguin a5cfb1ea9a
make: Remove show-upstream-git-fetch-url and co
They haven't been necessary for quite some time.
2024-08-29 15:19:14 +02:00
Loïc Hoguin 11a9148bba
make: Cleanup RABBITMQ_COMPONENTS
Ideally we wouldn't need it, but until applications are
in apps/ it will be necessary for a thing or two.

Note that rabbitmq_server_release is required to be
there for prepare-dist:: to work when building the
generic unix package.
2024-08-29 15:18:28 +02:00
Karl Nilsson c6006fd5ce Ra v2.13.6
This release contains a few fixes and improvements:

* Add ra:key_metrics/2
* ra_server: Add a new last_applied state query
* Stop checkpoint validation when encountering a valid checkpoint
* Kill snapshot process before deleting everything
2024-08-14 14:30:30 +01:00
Michael Klishin ddf5d2ff04
Merge pull request #11941 from rabbitmq/mk-bump-observer-cli 2024-08-08 02:52:33 -04:00
Michael Klishin a8afe603cf Bump observer_cli to 1.7.5 2024-08-08 01:56:28 -04:00
Simon Unge 2766122836 Move shovel prometheus to its own plugin 2024-08-08 01:26:49 -04:00
Michael Klishin b6098de245 Bump Cuttlefish to 3.4.0 2024-08-06 18:24:07 -04:00
Michael Klishin af67afe090 Bump Cuttlefish to 3.3.0 2024-08-05 22:32:21 -04:00
Karl Nilsson 5c0384a328 Ra v2.13.5
This restores the previous pre-init behaviour where an invalid server
will not stop the Ra system from starting. Instead it will log the
errors and continue.

This ensures compatibility with upgraded older systems and systems
where there are historical discrepancies between what is in the
ra_directory and actually on disk.
2024-07-23 15:13:50 +01:00
Michael Klishin f1b52880bb Bump Ra to 2.13.4 2024-07-22 11:00:51 -04:00
Karl Nilsson 42991f7838 Ra v2.13.3
This contains a fix in the ra_directory module to ensure
names can be deleted even when a Ra server has never been started
during the current node lifetime.

Also contains a small tweak to ensure the ra_directory:unregister_name
is called before deleting a Ra data directory which is less likely
to cause a corrupt state that will stop a Ra system from starting.
2024-07-19 18:47:27 +01:00
Karl Nilsson b225fb97ad Ra 2.13.2
This contains an important bugfix to an issue introduced in
2.11.0 where a segment writer may crash during recovery.
2024-07-19 12:40:48 +01:00
Karl Nilsson c0c6029938 Ra 2.13.1
This release contains improvements to the checkpointing feature
needed for quorum queues v4 and the following fixes:

* Add read to file:open/2 options in ra_lib:sync_file/1
* Emit the new local_query tuple only if query options are set
* bug fixes for checkpoints
2024-07-15 15:08:35 +01:00
Jean-Sébastien Pédron e9da930f59
Bump Khepri from 0.13.0 to 0.14.0
Release notes:
https://github.com/rabbitmq/khepri/releases/tag/v0.14.0

While here, bump khepri_mnesia_migration from 0.4.0 to 0.5.0 as well.
2024-07-10 16:07:43 -04:00
Loïc Hoguin 13025a3ba2
make: Experimental erlang.mk implementing beam cache
The beam cache allows switching between app and test
builds without having to rebuild everything. Since
the files keep their mtime and other attributes,
rebuilding continues from where it was left off
before, and only the relevant files get rebuilt
if anything changed.
2024-06-29 17:15:32 +02:00
Loïc Hoguin a64d1e67fc
Remove looking_glass
It has largely been superseded by `perf`. It is no longer
generally useful. It can always be added to BUILD_DEPS for
the rare cases it is needed, or installed locally and
pointed to by setting its path to ERL_LIBS.
2024-06-26 09:56:46 +02:00
Loïc Hoguin 31310d2315
make: Simplify looking for DEPS_DIR
With the monorepo the dependencies are either correct
or are the parent directory (when we are in a rabbit
application in deps/).
2024-06-24 14:06:46 +02:00
Karl Nilsson fdaef55213 Ra v2.11.0
This release includes a new machine API `snapshot_installed/2`. This new
API will only be used indirectly through khepri.

This release also includes an performance improvement that reduces the chances
of building a large WAL mailbox backlog when a node is low on scheduling
resources and commands are committed by followers completing writes to disk
before the leader.

There is also a fix for a potential election deadlock.
2024-06-17 15:43:12 +01:00
Loïc Hoguin 1535e730de
make: Don't immediately expand PROJECT_VERSION
When there is nothing to do we don't need this variable
so we don't want to calculate it unnecessarily.

Because this variable is only used once, when
producing the .app file, we don't have to worry
about the calculation being done multiple times.
If we ever do then it will need to be lazily
evaluated[1] instead.

[1] Managing Projects with GNU Make, 3rd Edition Chapter 10

Execution speed differences:

  make -C deps/rabbit nope  0,02s user 0,03s system 101% cpu 0,051 total
  make -C deps/rabbit nope  0,02s user 0,01s system 97% cpu 0,031 total
2024-06-10 09:42:32 +02:00
Michal Kuratczyk 65cbe5d2f3
Switch to upstream Jose
We had to fork it for Thoas support
but it's been merged a long time ago
https://github.com/potatosalad/erlang-jose/pull/126
2024-06-03 08:51:38 +02:00
Karl Nilsson 5123680a17 QQ: default to compressed mem tables and set a wal max entries default
Compressed ETS tables may introduce a small throughput penalty (low single
digit %) but can reduce peak Ra memory use by 30-50%.

Also set a default wal_max_entries value to avoid mem tables growing
too large when using very small message sizes (as more than 1M tiny
messages can easily fit into one WAL file).

Ra 2.10.1 has a type spec fix needed.
2024-05-09 14:24:22 +01:00