Search in sources :

Example 1 with DefContent

use of com.yahoo.vespa.config.protocol.DefContent in project vespa by vespa-engine.

the class Application method getTargetDef.

private ConfigDefinition getTargetDef(GetConfigRequest req) {
    ConfigKey<?> configKey = req.getConfigKey();
    DefContent def = req.getDefContent();
    ConfigDefinitionKey configDefinitionKey = new ConfigDefinitionKey(configKey.getName(), configKey.getNamespace());
    if (def.isEmpty()) {
        if (logDebug()) {
            debug("No config schema in request for " + configKey);
        }
        return cache.getDef(configDefinitionKey);
    } else {
        if (logDebug()) {
            debug("Got config schema from request, length:" + def.asList().size() + " : " + configKey);
        }
        return new ConfigDefinition(configKey.getName(), def.asStringArray());
    }
}
Also used : ConfigDefinition(com.yahoo.vespa.config.buildergen.ConfigDefinition) ConfigDefinitionKey(com.yahoo.vespa.config.ConfigDefinitionKey) DefContent(com.yahoo.vespa.config.protocol.DefContent)

Aggregations

ConfigDefinitionKey (com.yahoo.vespa.config.ConfigDefinitionKey)1 ConfigDefinition (com.yahoo.vespa.config.buildergen.ConfigDefinition)1 DefContent (com.yahoo.vespa.config.protocol.DefContent)1