private List<Resource> xmlMappingResources() { List<ClassPathScanner> scanners = ClassPathScanners.find(serverConfig); List<String> mappingLocations = serverConfig.getMappingLocations(); List<Resource> resourceList = new ArrayList<>(); long st = System.currentTimeMillis(); if (mappingLocations != null && !mappingLocations.isEmpty()) { for (ClassPathScanner finder : scanners) { for (String mappingLocation : mappingLocations) { resourceList.addAll(finder.scanForResources(mappingLocation, resourceName -> resourceName.endsWith(".xml"))); } } } long searchTime = System.currentTimeMillis() - st; log.debug("Classpath search mappings[{}] searchTime[{}]", resourceList.size(), searchTime); return resourceList; }
private List<Resource> xmlMappingResources() { List<ClassPathScanner> scanners = ClassPathScanners.find(serverConfig); List<String> mappingLocations = serverConfig.getMappingLocations(); List<Resource> resourceList = new ArrayList<>(); long st = System.currentTimeMillis(); if (mappingLocations != null && !mappingLocations.isEmpty()) { for (ClassPathScanner finder : scanners) { for (String mappingLocation : mappingLocations) { resourceList.addAll(finder.scanForResources(mappingLocation, resourceName -> resourceName.endsWith(".xml"))); } } } long searchTime = System.currentTimeMillis() - st; log.debug("Classpath search mappings[{}] searchTime[{}]", resourceList.size(), searchTime); return resourceList; }