class NamespaceListEquivalent {
  private static final Logger logger = LoggerFactory.getLogger(NamespaceListEquivalent.class);

  public static void main(String[] args) {<FILL_FUNCTION_BODY>}
}

    logger.info("Creating Kubernetes client");
    try (final KubernetesClient client = new KubernetesClientBuilder().build()) {
      logger.info("Kubernetes client successfully created");

      // List all namespaces
      client.namespaces()
          .list()
          .getItems()
          .stream()
          .map(Namespace::getMetadata)
          .map(ObjectMeta::getName)
          .forEach(logger::info);

    } catch (KubernetesClientException aException) {
      logger.error("Problem encountered in Kubernetes Client");
      aException.printStackTrace();
    }
  
<no_super_class>