Skip to content

Commit 6abeaf4

Browse files
Merge pull request #15072 from rabbitmq/mk-short-default-plugin-list
gmake run-broker, gmake start-cluster: use a very short plugin list by default
2 parents 506176e + 1efda84 commit 6abeaf4

File tree

4 files changed

+23
-20
lines changed

4 files changed

+23
-20
lines changed

CONTRIBUTING.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,8 @@ will run the older version.
105105

106106
``` shell
107107
# Run from repository root.
108-
# Starts a node with the management plugin enabled
109-
gmake run-broker RABBITMQ_PLUGINS=rabbitmq_management
108+
# Starts a node with management and two stream plugins enabled
109+
gmake run-broker ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
110110
```
111111

112112
The nodes will be started in the background. They will use `rabbit@{hostname}` for its name, so CLI will be able to contact
@@ -121,8 +121,8 @@ it without an explicit `-n` (`--node`) argument:
121121

122122
``` shell
123123
# Run from repository root.
124-
# Starts a three node cluster with the management plugin enabled
125-
gmake start-cluster NODES=3 RABBITMQ_PLUGINS=rabbitmq_management
124+
# Starts a three node cluster with management and two stream plugins enabled
125+
gmake start-cluster NODES=3 ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
126126
```
127127

128128
The node will use `rabbit-{n}@{hostname}` for names, so CLI must
@@ -163,8 +163,8 @@ gmake stop-cluster NODES=3
163163
When working on management UI code, besides starting the node with
164164

165165
``` shell
166-
# starts a node with the management plugin enabled
167-
gmake run-broker RABBITMQ_PLUGINS=rabbitmq_management
166+
# starts a node with management and two stream plugins enabled
167+
gmake run-broker ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
168168
```
169169

170170
(or any other set of plugins), it is highly recommended to use [BrowserSync](https://browsersync.io/#install)

Makefile

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -66,16 +66,19 @@ ifdef COMMUNITY_PLUGINS
6666
DEPS += $(RABBITMQ_COMMUNITY)
6767
endif
6868

69+
# Plugins to enable for `gmake run-broker`, `gmake start-cluster`, etc.
70+
# To override:
71+
# gmake run-broker ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream"
72+
# gmake start-cluster NODES=3 ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
73+
ENABLED_PLUGINS ?= rabbitmq_management
74+
RABBITMQ_ENABLED_PLUGINS ?= $(call comma_list,$(ENABLED_PLUGINS))
75+
# This is necessary for the recursively called targets
76+
# used by `gmake start-cluster`.
77+
export RABBITMQ_ENABLED_PLUGINS
78+
6979
include erlang.mk
7080
include mk/github-actions.mk
7181

72-
# If PLUGINS was set when we use run-broker we want to
73-
# fill in the enabled plugins list. PLUGINS is a more
74-
# natural space-separated list.
75-
ifdef PLUGINS
76-
RABBITMQ_ENABLED_PLUGINS ?= $(call comma_list,$(PLUGINS))
77-
endif
78-
7982
# --------------------------------------------------------------------
8083
# Distribution - common variables and generic functions.
8184
# --------------------------------------------------------------------

deps/rabbitmq_auth_backend_internal_loopback/CONTRIBUTING.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,8 @@ will run the older version.
105105

106106
``` shell
107107
# Run from repository root.
108-
# Starts a node with the management plugin enabled
109-
gmake run-broker RABBITMQ_PLUGINS=rabbitmq_management
108+
# Starts a node with management and two stream plugins enabled
109+
gmake run-broker ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
110110
```
111111

112112
The nodes will be started in the background. They will use `rabbit@{hostname}` for its name, so CLI will be able to contact
@@ -121,8 +121,8 @@ it without an explicit `-n` (`--node`) argument:
121121

122122
``` shell
123123
# Run from repository root.
124-
# Starts a three node cluster with the management plugin enabled
125-
gmake start-cluster NODES=3 RABBITMQ_PLUGINS=rabbitmq_management
124+
# Starts a three node cluster with management and two stream plugins enabled
125+
gmake start-cluster NODES=3 ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
126126
```
127127

128128
The node will use `rabbit-{n}@{hostname}` for names, so CLI must
@@ -163,8 +163,8 @@ gmake stop-cluster NODES=3
163163
When working on management UI code, besides starting the node with
164164

165165
``` shell
166-
# starts a node with the management plugin enabled
167-
gmake run-broker RABBITMQ_PLUGINS=rabbitmq_management
166+
# starts a node with management and two stream plugins enabled
167+
gmake run-broker ENABLED_PLUGINS="rabbitmq_management rabbitmq_stream rabbitmq_stream_management"
168168
```
169169

170170
(or any other set of plugins), it is highly recommended to use [BrowserSync](https://browsersync.io/#install)

deps/rabbitmq_cli/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ $(LINKED_ESCRIPTS): $(ESCRIPT_FILE)
122122
tests:: escript test-deps
123123
$(verbose) $(MAKE) -C ../../ install-cli
124124
$(verbose) $(MAKE) -C ../../ start-background-broker \
125-
PLUGINS="rabbitmq_federation rabbitmq_stomp rabbitmq_stream_management amqp_client" \
125+
ENABLED_PLUGINS="rabbitmq_federation rabbitmq_stomp rabbitmq_stream_management amqp_client" \
126126
$(if $(filter khepri,$(RABBITMQ_METADATA_STORE)),,RABBITMQ_FEATURE_FLAGS="-khepri_db"); \
127127
rm -f logs; \
128128
log_dir=$$(../../sbin/rabbitmqctl eval 'io:format("~s~n", [maps:get(log_base_dir,rabbit_prelaunch:get_context())]).'); \

0 commit comments

Comments
 (0)