apollo-portal/src/main/java/com/ctrip/framework/apollo/portal/service/ConfigsExportService.java/ConfigsExportService/exportNamespaces
class ConfigsExportService:  private void exportNamespaces(final Env env, final App exportApp, final ClusterDTO exportCluster,
                                ZipOutputStream zipOutputStream) {
    String clusterName = exportCluster.getName();

    List<NamespaceBO> namespaceBOS = namespaceService.findNamespaceBOs(exportApp.getAppId(), env, clusterName);

    if (CollectionUtils.isEmpty(namespaceBOS)) {
      return;
    }

    Stream<ConfigBO> configBOStream = namespaceBOS.stream()
        .map(
            namespaceBO -> new ConfigBO(env, exportApp.getOwnerName(), exportApp.getAppId(), clusterName, namespaceBO));

    writeNamespacesToZip(configBOStream, zipOutputStream);
  }