Copied from git commit:
Fix for successive invocations of Broker::enable
When Broker::enable(flags) is called multiple times in Bro scriptland,
only the first invocation will cause that an endpoint is created and
that the endpoint flags will be set. Every successive invocation
will be ignored. This is bad in cases that you want to enable
additional flags, e.g., auto_publish or auto_routing, in a script that
is initialized later on.
The fix now simply checks for each invocation of Broker::enable(flags),
if an endpoint was already created and if yes it will check if the
flags have changed. If the new flags are different from the old ones,
the new flags will be set.
Two small questions/comments after taking a look:
would it perhaps make sense to add flags to the already existing flags when calling enable, instead of replacing them? Or do you think it is ok that the flags of the last call "win" in this case.
In any case, I think it would be nice to update the documentation of Broker::Enable to relfect what is going on here. Could you perhaps add that to the branch?
Can I just assume that this will no longer apply after the next round of broker updates and that we can close it?
This doesn't seem to apply any longer.