diff --git a/src/python/blazingmq/dev/configurator/__init__.py b/src/python/blazingmq/dev/configurator/__init__.py index a5508ccab..a82eb4783 100644 --- a/src/python/blazingmq/dev/configurator/__init__.py +++ b/src/python/blazingmq/dev/configurator/__init__.py @@ -227,6 +227,19 @@ def _add_domain(self, domain: "Domain") -> "Domain": return domain + def remove_domain(self, name: str) -> None: + """ + Remove a domain from the Cluster's map and all the domain's maps. + + The domain must exist in `Cluster.domains`. It can be missing from the + broker's domain maps. + """ + + del self.domains[name] + + for node in self.nodes.values(): + node.domains.pop(name, None) + class Cluster(AbstractCluster): def domain(self, parameters: mqbconf.Domain) -> "Domain":