public static Map<NodeID, String> findRemotePluginsWithDifferentVersion(final String pluginName) {
        final Map<String, Map<NodeID, String>> allPluginVersions = getPluginAndOpenfireVersions();
        final Set<NodeID> allNodeIDs = ClusterManager.getNodesInfo().stream().map(ClusterNodeInfo::getNodeID).collect(Collectors.toSet());

        if (!allPluginVersions.containsKey(pluginName)) {
            return null;
        }

        final Map<NodeID, String> pluginVersion = allPluginVersions.get(pluginName);
        final String localPluginVersion = pluginVersion.get(XMPPServer.getInstance().getNodeID());

        final Map<NodeID, String> result = new HashMap<>();
        for (final NodeID nodeID : allNodeIDs) {
            final String remoteVersion = pluginVersion.get(nodeID);
            if (remoteVersion == null && localPluginVersion != null) {
                // Not installed remotely.
                result.put(nodeID, null);
            } else if (remoteVersion != null && !remoteVersion.equals(localPluginVersion)) {
                // Remote has a version that is different from the local version (or locally, this plugin isn't installed).
                result.put(nodeID, remoteVersion);
            }
        }

        return result;
    }
Inspects whether the version of a specific plugin on remote nodes differs from the version installed locally.

When the remote node has the same version of the plugin installed, the returned map will not include the NodeID
of that node. When the remote node has a different version of the plugin installed, the returned map will include
a NodeID entry that maps to the version identifier of the plugin that is installed on that node. When the remote
node does not have the plugin installed, the returned map will contain an entry that has a null value.

@param pluginName The (full) name of the plugin to check.
@return A map containing the nodeID that has a different version of this plugin.
xmppserver/src/main/java/org/jivesoftware/openfire/cluster/ClusterManager.java