broadcast(eventName, payload, opts) {
		if (Array.isArray(opts) || utils.isString(opts)) opts = { groups: opts };
		else if (opts == null) opts = {};

		if (opts.groups && !Array.isArray(opts.groups)) opts.groups = [opts.groups];

		const promises = [];

		this.logger.debug(
			`Broadcast '${eventName}' event` +
				(opts.groups ? ` to '${opts.groups.join(", ")}' group(s)` : "") +
				"."
		);

		if (this.transit) {
			const ctx = this.ContextFactory.create(this, null, payload, opts);
			ctx.eventName = eventName;
			ctx.eventType = "broadcast";
			ctx.eventGroups = opts.groups;

			if (!this.options.disableBalancer) {
				const endpoints = this.registry.events.getAllEndpoints(eventName, opts.groups);

				// Send to remote services
				endpoints.forEach(ep => {
					if (ep.id != this.nodeID) {
						const newCtx = ctx.copy(ep);
						promises.push(this.transit.sendEvent(newCtx));
					}
				});
			} else {
				// Disabled balancer case
				let groups = opts.groups;

				if (!groups || groups.length == 0) {
					// Apply to all groups
					groups = this.getEventGroups(eventName);
				}

				if (groups.length == 0) return; // Return here because balancer disabled, so we can't call the local services.

				const endpoints = this.registry.events.getAllEndpoints(eventName, groups);

				// Return here because balancer disabled, so we can't call the local services.
				return this.Promise.all(
					endpoints.map(ep => {
						const newCtx = ctx.copy(ep);
						newCtx.eventGroups = groups;
						return this.transit.sendEvent(newCtx);
					})
				);
			}
		}

		// Send to local services
		promises.push(this.broadcastLocal(eventName, payload, opts));

		return this.Promise.all(promises);
	}
Broadcast an event for all local & remote services

@param {string} eventName
@param {any?} payload
@param {Object?} opts
@returns {Promise}

@memberof ServiceBroker