public static boolean shouldExecuteLocally(final NodeInfo nodeInfo,
                                               final String nodeName) {
        final String thisNodeName = nodeInfo.getThisNodeName();
        if (thisNodeName == null) {
            throw new RuntimeException("This node has no name");
        }

        // If this is the node that was contacted then just return our local info.
        return thisNodeName.equals(nodeName);
    }
@return True if the work should be executed on the local node.
I.e. if nodeName equals the name of the local node
stroom-node/stroom-node-api/src/main/java/stroom/node/api/NodeCallUtil.java