com.yahoo.vespa.model.application.validation.BundleValidator Maven / Gradle / Ivy
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.vespa.model.application.validation;
import com.yahoo.config.model.deploy.DeployState;
import org.w3c.dom.Document;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.function.Predicate;
import java.util.jar.Attributes;
import java.util.jar.JarFile;
import java.util.jar.Manifest;
import java.util.logging.Level;
import java.util.regex.Pattern;
/**
* A validator for bundles.
*
* @author hmusum
* @author bjorncs
*/
public class BundleValidator extends AbstractBundleValidator {
@Override
protected void validateManifest(JarContext reporter, JarFile jar, Manifest mf) {
// Check for required OSGI headers
Attributes attributes = mf.getMainAttributes();
HashSet mfAttributes = new HashSet<>();
for (Map.Entry
© 2015 - 2024 Weber Informatics LLC | Privacy Policy