@Override
    public void doRun() {
        final DataNodeDto dto = DataNodeDto.Builder.builder()
                .setId(nodeId.getNodeId())
                .setTransportAddress(opensearchBaseUri.get().toString())
                .setClusterAddress(opensearchClusterUri.get())
                .setDataNodeStatus(processState.get().getDataNodeStatus())
                .setHostname(configuration.getHostname())
                .setRestApiAddress(datanodeRestApiUri.get())
                .setCertValidUntil(certValidUntil.get())
                .setDatanodeVersion(version.getVersion().toString())
                .build();

        nodeService.ping(dto);

    }
@Test
    void doRun() {

        final SimpleNodeId nodeID = new SimpleNodeId("5ca1ab1e-0000-4000-a000-000000000000");
        final URI uri = URI.create("http://localhost:9200");
        final String cluster = "localhost:9300";
        final String datanodeRestApi = "http://localhost:8999";
        @SuppressWarnings("unchecked")



        final NodePingPeriodical task = new NodePingPeriodical(
                nodeService,
                nodeID,
                new Configuration(),
                () -> uri,
                () -> cluster,
                () -> datanodeRestApi,
                () -> OpensearchState.AVAILABLE,
                Date::new
        );

        task.doRun();

        Assertions.assertThat(nodeService.allActive().values())
                .hasSize(1)
                .allSatisfy(nodeDto -> {
                    Assertions.assertThat(nodeDto.getTransportAddress()).isEqualTo("http://localhost:9200");
                    Assertions.assertThat(nodeDto.getClusterAddress()).isEqualTo("localhost:9300");
                    Assertions.assertThat(nodeDto.getDataNodeStatus()).isEqualTo(DataNodeStatus.AVAILABLE);
                    Assertions.assertThat(nodeDto.getNodeId()).isEqualTo("5ca1ab1e-0000-4000-a000-000000000000");
                    Assertions.assertThat(nodeDto.getLastSeen()).isNotNull();
                    Assertions.assertThat(nodeDto.getProvisioningInformation().certValidUntil()).isNotNull();
                });
    }