3131 base_product_version /0 ,
3232 motd_file /0 ,
3333 motd /0 ,
34- pg_local_scope /1 ]).
34+ pg_local_scope /1 ,
35+ pg_scope_amqp091_channel /0 ,
36+ pg_scope_amqp091_connection /0 ]).
3537% % For CLI, testing and mgmt-agent.
3638-export ([set_log_level /1 , log_locations /0 , config_files /0 ]).
3739-export ([is_booted /1 , is_booted /0 , is_booting /1 , is_booting /0 ]).
4042% % Boot steps.
4143-export ([update_cluster_tags /0 , maybe_insert_default_data /0 , boot_delegate /0 , recover /0 ,
4244 pg_local_amqp_session /0 ,
43- pg_local_amqp_connection /0 , prevent_startup_if_node_was_reset /0 ]).
45+ pg_local_amqp_connection /0 ,
46+ pg_local_amqp091_channel /0 ,
47+ pg_local_amqp091_connection /0 ,
48+ start_pg_local /0 ,
49+ prevent_startup_if_node_was_reset /0 ]).
4450
4551-rabbit_boot_step ({pre_boot , [{description , " rabbit boot start" }]}).
4652
157163 [{description , " kernel ready" },
158164 {requires , external_infrastructure }]}).
159165
166+ -rabbit_boot_step ({pg_local ,
167+ [{description , " local-only pg scope" },
168+ {mfa , {rabbit , start_pg_local , []}},
169+ {requires , kernel_ready },
170+ {enables , core_initialized }]}).
171+
160172-rabbit_boot_step ({guid_generator ,
161173 [{description , " guid generator" },
162174 {mfa , {rabbit_sup , start_restartable_child ,
292304 {enables , core_initialized }]}).
293305
294306-rabbit_boot_step ({pg_local_amqp_connection ,
295- [{description , " local-only pg scope for AMQP connections" },
307+ [{description , " local-only pg scope for AMQP 1.0 connections" },
296308 {mfa , {rabbit , pg_local_amqp_connection , []}},
297309 {requires , kernel_ready },
298310 {enables , core_initialized }]}).
299311
312+ -rabbit_boot_step ({pg_local_amqp091_channel ,
313+ [{description , " local-only pg scope for AMQP 0-9-1 channels" },
314+ {mfa , {rabbit , pg_local_amqp091_channel , []}},
315+ {requires , kernel_ready },
316+ {enables , core_initialized }]}).
317+
318+ -rabbit_boot_step ({pg_local_amqp091_connection ,
319+ [{description , " local-only pg scope for AMQP 0-9-1 connections" },
320+ {mfa , {rabbit , pg_local_amqp091_connection , []}},
321+ {requires , kernel_ready },
322+ {enables , core_initialized }]}).
323+
300324% %---------------------------------------------------------------------------
301325
302326-include_lib (" rabbit_common/include/rabbit.hrl" ).
@@ -1146,6 +1170,9 @@ boot_delegate() ->
11461170recover () ->
11471171 ok = rabbit_vhost :recover ().
11481172
1173+ start_pg_local () ->
1174+ rabbit_sup :start_child (pg_local_scope , pg , [node ()]).
1175+
11491176pg_local_amqp_session () ->
11501177 PgScope = pg_local_scope (amqp_session ),
11511178 rabbit_sup :start_child (pg_amqp_session , pg , [PgScope ]).
@@ -1154,9 +1181,23 @@ pg_local_amqp_connection() ->
11541181 PgScope = pg_local_scope (amqp_connection ),
11551182 rabbit_sup :start_child (pg_amqp_connection , pg , [PgScope ]).
11561183
1184+ pg_local_amqp091_channel () ->
1185+ PgScope = pg_local_scope (amqp091_channel ),
1186+ rabbit_sup :start_child (pg_amqp091_channel , pg , [PgScope ]).
1187+
1188+ pg_local_amqp091_connection () ->
1189+ PgScope = pg_local_scope (amqp091_connection ),
1190+ rabbit_sup :start_child (pg_amqp091_connection , pg , [PgScope ]).
1191+
11571192pg_local_scope (Prefix ) ->
11581193 list_to_atom (io_lib :format (" ~s _~s " , [Prefix , node ()])).
11591194
1195+ pg_scope_amqp091_channel () ->
1196+ pg_local_scope (amqp091_channel ).
1197+
1198+ pg_scope_amqp091_connection () ->
1199+ pg_local_scope (amqp091_connection ).
1200+
11601201- spec update_cluster_tags () -> 'ok' .
11611202
11621203update_cluster_tags () ->
0 commit comments