private void validateImportedPackages(DeployState state, JarFile jar, Manifest manifest) {
        Map<DeprecatedProvidedBundle, List<String>> deprecatedPackagesInUse = new HashMap<>();
        forEachImportPackage(manifest, (packageName) -> {
            for (DeprecatedProvidedBundle deprecatedBundle : DeprecatedProvidedBundle.values()) {
                for (Predicate<String> matcher : deprecatedBundle.javaPackageMatchers) {
                    if (matcher.test(packageName)) {
                        deprecatedPackagesInUse.computeIfAbsent(deprecatedBundle, __ -> new ArrayList<>())
                                .add(packageName);
                    }
                }
            }
        });
        deprecatedPackagesInUse.forEach((artifact, packagesInUse) -> {
            log(state, Level.WARNING, "JAR file '%s' imports the packages %s from '%s'. \n%s",
                filename(jar), packagesInUse, artifact.name, artifact.description);
        });
    }
A validator for bundles.

@author hmusum
@author bjorncs
config-model/src/main/java/com/yahoo/vespa/model/application/validation/BundleValidator.java