private List<Component> getComponents(JID componentJID) {
        synchronized (routables) {
            if (componentJID.getNode() != null) {
                return Collections.emptyList();
            }
            RoutableComponents routable = routables.get(componentJID.getDomain());
            if (routable != null) {
                return routable.getComponents();
            }
            else {
                // Search again for those JIDs whose domain include the server name but this
                // time remove the server name from the JID's domain
                String serverName = componentJID.getDomain();
                int index = serverName.lastIndexOf("." + serverDomain);
                if (index > -1) {
                    routable = routables.get(serverName.substring(0, index));
                    if (routable != null) {
                        return routable.getComponents();
                    }
                }
            }
            return Collections.emptyList();
        }
    }
Retrieves the <code>Component</code> which is mapped to the specified JID. The
look up will only be done on components that were registered with this JVM. That
means that components registered in other cluster nodes are not going to be
considered.

@param componentJID the jid mapped to the component.
@return the list of components with the specified id.
xmppserver/src/main/java/org/jivesoftware/openfire/component/InternalComponentManager.java