Description
The registerNamespace() and unregisterNamespace() methods of NamespaceRegistry should cause the session from which the registry instance was acquired to refresh its state. Otherwise code that first registers a new namespace and then tries to use it might end up failing because the session is still seeing and older version of the content tree. Potential other sessions should remain as they are and only start seeing the modified namespaces once they're separately refreshed.
PS. Similar refresh requirements probably also affect things like node type registration, versioning, direct-to-workspace writes, etc.