Commit Graph

59481 Commits

Author SHA1 Message Date
Michael Klishin 7d3292cedd quorum_queue_SUITE: keep Raft state logging in force_checkpoint_on_queue 2025-05-22 15:09:57 +02:00
Michael Klishin d17b085653 Quorum queue machine: do not publish certain state records
we can use log state in tests.
2025-05-22 15:09:55 +02:00
Michael Klishin d54fee2e7a Update a #13175 test to not use private Ra machine state
(cherry picked from commit e49acf956c806849068f543f282683978ca5a385)
2025-05-22 15:09:25 +02:00
Aaron Seo 6a78e9f7ba Add timeout to rpc call for force_checkpoint
(cherry picked from commit 4439150e50)
2025-05-22 15:09:25 +02:00
Aaron Seo fa310864d7 Fix force_checkpoint tests and CLI command
(cherry picked from commit 12bf3e094e)

Conflicts:
	deps/rabbit/src/rabbit_quorum_queue.erl
2025-05-22 15:09:23 +02:00
Aaron Seo 0d3dfd9695 Add force checkpoint functions for quorum queues and command line tool
(cherry picked from commit b54ab1d5e5)
2025-05-22 14:58:12 +02:00
Péter Gömöri ec455d5cff Fix comment about CQ v1->v2 index recovery 2025-05-22 14:05:44 +02:00
Péter Gömöri 55e3c458c2 Add tests for rabbit_classic_queue_index_v2:bounds/2 2025-05-22 14:05:44 +02:00
Iliia Khaprov 2d029649a2
Add CQ and QQ Observer CLI plugins from boot steps
Do not hard code them, also preserve user-provided plugins list
Type fix by @kura
2025-05-22 10:58:35 +02:00
Marcial Rosales 27b3e21554 Fix issue related to popup warning
And in particular locating the span#close button
2025-05-22 10:08:22 +02:00
Michael Klishin 6dd7447b92
Merge pull request #13929 from rabbitmq/queue-checks
Trigger a 4.2.x alpha release build / trigger_alpha_build (push) Has been cancelled Details
Test (make) / Build and Xref (1.17, 26) (push) Has been cancelled Details
Test (make) / Build and Xref (1.17, 27) (push) Has been cancelled Details
Test (make) / Test (1.17, 27, khepri) (push) Has been cancelled Details
Test (make) / Test (1.17, 27, mnesia) (push) Has been cancelled Details
Test (make) / Test mixed clusters (1.17, 27, khepri) (push) Has been cancelled Details
Test (make) / Test mixed clusters (1.17, 27, mnesia) (push) Has been cancelled Details
Test (make) / Type check (1.17, 27) (push) Has been cancelled Details
Test Management UI with Selenium / selenium (chrome, 1.17.3, 27.3) (push) Has been cancelled Details
Use more idiomatic `maybe` feature
2025-05-21 21:51:43 +04:00
Michael Klishin dfa06d91ca
Merge pull request #13928 from rabbitmq/sac-policy
Delete single-active-consumer policy
2025-05-21 19:59:18 +04:00
David Ansari 3189686510 Add maybe_expr feature for OTP 26
GitHub action Build and Xref on OTP 26 errored with:
```
src/rabbit_quorum_queue.erl:252:9: syntax error before: ok
%  252|         ok ?= rabbit_queue_type_util:check_auto_delete(Q),
%     |         ^
```
2025-05-21 17:48:51 +02:00
David Ansari 4a3752a87f Use more idiomatic `maybe` feature 2025-05-21 17:32:04 +02:00
David Ansari 90e7e1065c Delete single-active-consumer policy
`single-active-consumer` shouldn't be listed under `unsupported_policies` for quorum
queues and streams because it isn't a valid policy in the first place, see
https://www.rabbitmq.com/docs/consumers#sac-cannot-be-enabled-with-a-policy
2025-05-21 17:11:16 +02:00
Michael Klishin 1679d0ced0
Merge pull request #13925 from rabbitmq/bump-up-chromedriver
Bump up chrome driver
2025-05-21 18:21:52 +04:00
Michael Klishin 6e0ba8e9ff
Merge pull request #13924 from rabbitmq/remove-unused-channel-field
Remove unused field in channel record.
2025-05-21 18:20:20 +04:00
Marcial Rosales a028db8156 Briefly explain how to start a second rabbitmq server
interactively
2025-05-21 15:50:29 +02:00
Marcial Rosales 44dd282ed4 Eliminate flake around listing live amqp connections 2025-05-21 15:15:35 +02:00
Marcial Rosales 6578c83a0e Bump up chrome driver
This is needed when running tests interactively.
The OS updates the local chrome binary and this
node.js library has to be upgraded too.
2025-05-21 14:10:30 +02:00
Karl Nilsson 542c0fe512 Remove unused field in channel record. 2025-05-21 09:22:36 +01:00
Michael Klishin 8199c0f401
Merge pull request #13920 from rabbitmq/md/prop-ra-indexes
Trigger a 4.2.x alpha release build / trigger_alpha_build (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 26) (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 27) (push) Waiting to run Details
Test (make) / Test (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Type check (1.17, 27) (push) Waiting to run Details
Add a proptest checking `ra_indexes` indices
2025-05-21 00:55:44 +04:00
Michael Davis 01b4051b03
Add a proptest checking `ra_indexes` indices
This is mostly the same as the `messages_total` property test but checks
that the Raft indexes in `ra_indexes` are the set of the indexes checked
out by all consumers union any indexes in the `returns` queue. This is
the intended state of `ra_indexes` and failing this condition could
cause bugs that would prevent snapshotting.
2025-05-20 10:34:18 -04:00
David Ansari 8546bcfecd
Merge pull request #13918 from rabbitmq/amqp-durable
Trigger a 4.2.x alpha release build / trigger_alpha_build (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 26) (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 27) (push) Waiting to run Details
Test (make) / Test (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Type check (1.17, 27) (push) Waiting to run Details
Follow AMQP spec for durable field
2025-05-20 13:20:55 +02:00
David Ansari 67895da04d Mention AMQP durable field in 4.2 release notes 2025-05-20 08:32:52 +02:00
David Ansari f8f1396c90 Follow AMQP spec for durable field
The AMQP spec defines:
```
<field name="durable" type="boolean" default="false"/>
```

RabbitMQ 4.0 and 4.1 interpret the durable field as true if not set.
The idea was to favour safety over performance.
This complies with the AMQP spec because the spec allows other target or
node specific defaults for the durable field:
> If the header section is omitted the receiver MUST assume the appropriate
> default values (or the meaning implied by no value being set) for the fields
> within the header unless other target or node specific defaults have otherwise
> been set.

However, some client libraries completely omit the header section if the
app expliclity sets durable=false. This complies with the spec, but it
means that RabbitMQ cannot diffentiate between "client app forgot to set
the durable field" vs "client lib opted in for an optimisation omitting
the header section".

This is problematic with JMS message selectors where JMS apps can filter
on JMSDeliveryMode. To be able to correctly filter on JMSDeliveryMode,
RabbitMQ needs to know whether the JMS app sent the message as
PERSISTENT or NON_PERSISTENT.

Rather than relying on client libs to always send the header section
including the durable field, this commit makes RabbitMQ comply with the
default value for durable in the AMQP spec.
Some client lib maintainers accepted to send the header section, while
other maintainers refused to do so:
https://github.com/Azure/go-amqp/issues/330
https://issues.apache.org/jira/browse/QPIDJMS-608

Likely the AMQP spec was designed to omit the header section when
performance is important, as is the case with durable=false. Omitting
the header section means saving a few bytes per message on the wire and
some marshalling and unmarshalling overhead on both client and server.

Therefore, it's better to push the "safe by default" behaviour from the broker
back to the client libs. Client libs should send messages as durable by
default unless the client app expliclity opts in to send messages as
non-durable. This is also what JMS does: By default JMS apps send
messages as PERSISTENT:
> The message producer's default delivery mode is PERSISTENT.

Therefore, this commit also makes the AMQP Erlang client send messages as
durable, by default.

This commit will apply to RabbitMQ 4.2.
It's arguably not a breaking change because in RabbitMQ, message durability
is actually more determined by the queue type the message is sent to rather than the
durable field of the message:
* Quroum queues and streams store messages durably (fsync or replicate)
  no matter what the durable field is
* MQTT QoS 0 queues hold messages in memory no matter what the
  durable field is
* Classic queues do not fsync even if the durable field is set to true

In addition, the RabbitMQ AMQP Java library introduced in RabbitMQ 4.0 sends messages with
durable=true:
53e3dd6abb/src/main/java/com/rabbitmq/client/amqp/impl/AmqpPublisher.java (L91)

The tests for selecting messages by JMSDeliveryMode relying on the
behaviour in this commit can be found on the `jms` branch.
2025-05-20 08:32:52 +02:00
Michael Klishin 4f1076d89c
Merge pull request #13916 from rabbitmq/otp28-fixes
Trigger a 4.2.x alpha release build / trigger_alpha_build (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 26) (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 27) (push) Waiting to run Details
Test (make) / Test (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Type check (1.17, 27) (push) Waiting to run Details
Test Authentication/Authorization backends via mutiple messaging protocols / selenium (chrome, 1.17.3, 27.3) (push) Has been cancelled Details
Test Authentication/Authorization backends via mutiple messaging protocols / summary-selenium (push) Has been cancelled Details
OTP28: re:split change; street-address macro
2025-05-19 16:18:40 +04:00
Michal Kuratczyk 9fefcc4827
Remove rabbitmq_mqtt from DEPS (it's a TEST_DEP) 2025-05-19 09:40:05 +02:00
Michal Kuratczyk 637a2bc8cc
OTP28: re:split change; street-address macro
https://github.com/erlang/otp/issues/9739

In OTP28+, splitting an empty string returns an empty list, not an empty
string (the input).

Additionally `street-address` macro was removed in OTP28 - replace with
the value it used to be.

Lastly, rabbitmq_auth_backend_oauth2 has an MQTT test, so add
rabbitmq_mqtt to TEST_DEPS
2025-05-19 08:59:50 +02:00
Michael Klishin 4b714f4f7c
Merge pull request #13913 from rabbitmq/mk-ra-2.16.9
Trigger a 4.2.x alpha release build / trigger_alpha_build (push) Waiting to run Details
Test Authentication/Authorization backends via mutiple messaging protocols / selenium (chrome, 1.17.3, 27.3) (push) Waiting to run Details
Test Authentication/Authorization backends via mutiple messaging protocols / summary-selenium (push) Blocked by required conditions Details
Test (make) / Build and Xref (1.17, 26) (push) Waiting to run Details
Test (make) / Build and Xref (1.17, 27) (push) Waiting to run Details
Test (make) / Test (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, khepri) (push) Waiting to run Details
Test (make) / Test mixed clusters (1.17, 27, mnesia) (push) Waiting to run Details
Test (make) / Type check (1.17, 27) (push) Waiting to run Details
Test Management UI with Selenium / selenium (chrome, 1.17.3, 27.3) (push) Has been cancelled Details
Bump Ra to 2.16.9
2025-05-19 08:11:21 +04:00
Michael Klishin d68ca77ec5
Merge pull request #13912 from rabbitmq/mk-osiris-1.8.8
Bump Osiris to 1.8.8
2025-05-19 07:30:02 +04:00
Michael Klishin c2d6dee8e8
Bump Ra to 2.16.9 2025-05-18 23:26:46 -04:00
Michael Klishin 94575bc76d
Bump Osiris to 1.8.8 2025-05-18 22:46:40 -04:00
Michael Klishin 92a4d2c2ab
Merge pull request #13910 from rabbitmq/ik-queues-with-plugins-mgmt
Queues with plugins - Managment UI parts
2025-05-19 06:31:28 +04:00
Michael Klishin c29fc82158
Merge pull request #13909 from rabbitmq/ik-queue-protection-mgmt
Do not render Delete button for internal queues
2025-05-19 06:24:42 +04:00
Michael Klishin eb7634c678
Merge pull request #13905 from rabbitmq/ik-queues-with-plugins
Queues with plugins  - Core
2025-05-19 06:22:48 +04:00
Michael Klishin 551a300f78
Merge pull request #13903 from rabbitmq/dependabot/maven/deps/rabbitmq_auth_backend_http/examples/rabbitmq_auth_backend_spring_boot_kotlin/main/dev-deps-5ac378ddf0
[skip ci] Bump the dev-deps group across 1 directory with 2 updates
2025-05-19 06:22:15 +04:00
Iliia Khaprov 180e7b1c1c
Queues with plugins - switch to get_queue_type in Management UI 2025-05-18 23:52:58 +02:00
Iliia Khaprov de17a77df4
Queues with plugins - Enable adding queues with plugins, Management UI 2025-05-18 23:52:58 +02:00
Iliia Khaprov 5fd3bddcfe
Protected queues - do not render Delete button for internal queues
with fix for rabbit_mgmt_wm_queue by MK
2025-05-18 23:50:53 +02:00
Iliia Khaprov bcdb0b7067
Queues with plugins - remove unused include form rabbit registry suite 2025-05-17 23:33:12 +02:00
Iliia Khaprov fd6b40c14a
Queues with plugins - adapt qos0 queue from MQTT plugin 2025-05-17 23:33:11 +02:00
Iliia Khaprov 3a33163d98
Queues with plugins - remove queue_topology callback 2025-05-17 23:33:11 +02:00
Iliia Khaprov 1eeaef4874
Queues with plugins - move is_(replicated->replicable) to capabilities 2025-05-17 23:33:11 +02:00
Iliia Khaprov 9ef170f4e7
Queues with plugins - short_alias_of spec fix 2025-05-17 20:48:14 +02:00
Iliia Khaprov c12c76ae45
Queues with plugins - sync with queue topologies updates 2025-05-17 20:48:09 +02:00
Iliia Khaprov 34f0d12dab
Queues with plugins - address Karl's comments
revive_local_queue_replicas -> revive_local_queue_members
can_redeliver converted from callback to capabilities key
rebalance_moduled converted from callback to capabilities key
2025-05-17 20:48:05 +02:00
Diana Parra Corbacho cfd51bac6c
Queues with plugins - fix rabbit_registry_SUITE 2025-05-17 20:48:00 +02:00
Iliia Khaprov 59701a0ea9
Queues with plugins - Diana's review 2025-05-17 20:47:55 +02:00
Diana Parra Corbacho 3f4fa167c5
Queues with plugins - tests, run amqqueue:to_printable in broker
It needs access to registry for the queue type
2025-05-17 20:47:49 +02:00