public List<ClusterNode> listNodes(String clusterId) {
        CqlSession session = cqlSessionFactory.get(clusterId);

        return session.getMetadata().getNodes().values().stream()
            .map(ClusterNode::from)
            .sorted(Comparator.comparing(ClusterNode::getDatacenter)
                .thenComparing(ClusterNode::getRack))
            .toList();
    }
@Test
    void list_nodes_in_cluster() {
        // given
        List<ClusterNode> nodes = clusterNodeListCommander.listNodes(CLUSTER_ID);

        assertThat(nodes).hasSize(1);
        assertThat(nodes.getFirst().getRack()).isEqualTo("rack1");
        assertThat(nodes.getFirst().getNodeState()).isEqualTo(NodeState.UP);
        assertThat(nodes.getFirst().getDatacenter()).isEqualTo("dc1");
        assertThat(nodes.getFirst().getUpSinceMillis()).isGreaterThan(0);
        assertThat(nodes.getFirst().getCassandraVersion()).isNotNull();
    }