Class HazelcastUtils

java.lang.Object
com.atlassian.confluence.cluster.hazelcast.HazelcastUtils

@Internal public final class HazelcastUtils extends Object
Contains HZ Member <-> NodeIdentifier conversion utils
Since:
5.7
  • Field Details

  • Method Details

    • getMemberId

      public static String getMemberId(com.hazelcast.cluster.Member member)
      While we could just use the Member UUID here, this would change on every restart. By using the socketAddress as the basis for the node identifier, it will mostly remain the same across restarts, making diagnosis of node affinity problems easier. Also, InetSocketAddress has a bad hashCode implementation, so we bypass it.
    • getMemberNodeIdentifier

      public static com.atlassian.cluster.monitoring.spi.model.NodeIdentifier getMemberNodeIdentifier(com.hazelcast.cluster.Member member)
    • getMemberSelector

      public static com.hazelcast.cluster.MemberSelector getMemberSelector(com.atlassian.cluster.monitoring.spi.model.NodeIdentifier nodeIdentifier)
    • extractNodeId

      public static Function<com.hazelcast.cluster.Member,com.atlassian.cluster.monitoring.spi.model.NodeIdentifier> extractNodeId()
    • getConfiguredMemberName

      public static Optional<String> getConfiguredMemberName(com.hazelcast.cluster.Member member)
    • extractNodeInfo

      public static Function<com.hazelcast.cluster.Member,com.atlassian.cluster.monitoring.spi.model.NodeInformation> extractNodeInfo()