notice: Move to Cluster::publish()

This commit is contained in:
Arne Welzel 2024-12-11 18:11:23 +00:00
parent 347faf5e86
commit a9243bafcc

View file

@ -529,8 +529,8 @@ hook Notice::notice(n: Notice::Info) &priority=-5
# Once we have global pub/sub, we could also unconditionally # Once we have global pub/sub, we could also unconditionally
# send to a notice specific topic for communicating # send to a notice specific topic for communicating
# suppressions directly to all nodes. # suppressions directly to all nodes.
Broker::publish(Cluster::manager_topic, Notice::begin_suppression, Cluster::publish(Cluster::manager_topic, Notice::begin_suppression,
n$ts, n$suppress_for, n$note, n$identifier); n$ts, n$suppress_for, n$note, n$identifier);
@endif @endif
} }
} }
@ -540,9 +540,9 @@ hook Notice::notice(n: Notice::Info) &priority=-5
@if ( Cluster::is_enabled() && Cluster::local_node_type() == Cluster::MANAGER ) @if ( Cluster::is_enabled() && Cluster::local_node_type() == Cluster::MANAGER )
event Notice::begin_suppression(ts: time, suppress_for: interval, note: Type, identifier: string) event Notice::begin_suppression(ts: time, suppress_for: interval, note: Type, identifier: string)
{ {
local e = Broker::make_event(Notice::begin_suppression, ts, suppress_for, note, identifier); local e = Cluster::make_event(Notice::begin_suppression, ts, suppress_for, note, identifier);
Broker::publish(Cluster::worker_topic, e); Cluster::publish(Cluster::worker_topic, e);
Broker::publish(Cluster::proxy_topic, e); Cluster::publish(Cluster::proxy_topic, e);
} }
@endif @endif