public String getFQDNHostname() {
        return hostNameSupplier.getFqdnHostName();
    }
@Test
    void testSerialization() {
        try {
            // without resolved hostname
            {
                TaskManagerLocation original =
                        new TaskManagerLocation(
                                ResourceID.generate(), InetAddress.getByName("1.2.3.4"), 8888);

                TaskManagerLocation serCopy = InstantiationUtil.clone(original);
                assertThat(original).isEqualTo(serCopy);
            }

            // with resolved hostname
            {
                TaskManagerLocation original =
                        new TaskManagerLocation(
                                ResourceID.generate(), InetAddress.getByName("127.0.0.1"), 19871);
                original.getFQDNHostname();

                TaskManagerLocation serCopy = InstantiationUtil.clone(original);
                assertThat(original).isEqualTo(serCopy);
            }
        } catch (Exception e) {
            e.printStackTrace();
            fail(e.getMessage());
        }
    }