Class DerivedConfiguration
java.lang.Object
com.yahoo.searchdefinition.derived.DerivedConfiguration
- All Implemented Interfaces:
com.yahoo.config.ConfigInstance.Producer
,com.yahoo.vespa.config.search.AttributesConfig.Producer
public class DerivedConfiguration
extends Object
implements com.yahoo.vespa.config.search.AttributesConfig.Producer
A set of all derived configuration of a search definition. Use this as a facade to individual configurations when
necessary.
- Author:
- bratseth
-
Constructor Summary
ConstructorDescriptionDerivedConfiguration
(Schema schema, com.yahoo.config.application.api.DeployLogger deployLogger, com.yahoo.config.model.api.ModelContext.Properties deployProperties, RankProfileRegistry rankProfileRegistry, com.yahoo.search.query.profile.QueryProfileRegistry queryProfiles, ai.vespa.rankingexpression.importer.configmodelview.ImportedMlModels importedModels, ExecutorService executor) Creates a complete derived configuration snapshot from a search definition.DerivedConfiguration
(Schema schema, RankProfileRegistry rankProfileRegistry) Creates a complete derived configuration from a search definition. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Exports a complete set of configuration-server format config files.static void
exportDocuments
(com.yahoo.document.config.DocumentmanagerConfig.Builder documentManagerCfg, String toDirectory) static void
exportDocuments
(com.yahoo.document.config.DocumenttypesConfig.Builder documentTypesCfg, String toDirectory) static void
exportQueryProfiles
(com.yahoo.search.query.profile.QueryProfileRegistry queryProfileRegistry, String toDirectory) void
getConfig
(com.yahoo.vespa.config.search.AttributesConfig.Builder builder) void
getConfig
(com.yahoo.vespa.config.search.AttributesConfig.Builder builder, AttributeFields.FieldSet fs) com.yahoo.search.query.profile.QueryProfileRegistry
void
setIndexingScript
(IndexingScript script)
-
Constructor Details
-
DerivedConfiguration
Creates a complete derived configuration from a search definition. Only used in tests.- Parameters:
schema
- the search to derive a configuration from. Derived objects will be snapshots, but this argument is live. Which means that this object will be inconsistent when the given search definition is later modified.rankProfileRegistry
- aRankProfileRegistry
-
DerivedConfiguration
public DerivedConfiguration(Schema schema, com.yahoo.config.application.api.DeployLogger deployLogger, com.yahoo.config.model.api.ModelContext.Properties deployProperties, RankProfileRegistry rankProfileRegistry, com.yahoo.search.query.profile.QueryProfileRegistry queryProfiles, ai.vespa.rankingexpression.importer.configmodelview.ImportedMlModels importedModels, ExecutorService executor) Creates a complete derived configuration snapshot from a search definition.- Parameters:
schema
- the search to derive a configuration from. Derived objects will be snapshots, but this argument is live. Which means that this object will be inconsistent when the given search definition is later modified.deployLogger
- aDeployLogger
for logging when doing operations on thisdeployProperties
- properties set on deployrankProfileRegistry
- aRankProfileRegistry
queryProfiles
- the query profiles of this application
-
-
Method Details
-
export
Exports a complete set of configuration-server format config files.- Parameters:
toDirectory
- the directory to export to, current dir if null- Throws:
IOException
- if exporting fails, some files may still be created
-
exportDocuments
public static void exportDocuments(com.yahoo.document.config.DocumentmanagerConfig.Builder documentManagerCfg, String toDirectory) throws IOException - Throws:
IOException
-
exportDocuments
public static void exportDocuments(com.yahoo.document.config.DocumenttypesConfig.Builder documentTypesCfg, String toDirectory) throws IOException - Throws:
IOException
-
exportQueryProfiles
public static void exportQueryProfiles(com.yahoo.search.query.profile.QueryProfileRegistry queryProfileRegistry, String toDirectory) throws IOException - Throws:
IOException
-
getSummaries
-
getAttributeFields
-
getConfig
public void getConfig(com.yahoo.vespa.config.search.AttributesConfig.Builder builder) - Specified by:
getConfig
in interfacecom.yahoo.vespa.config.search.AttributesConfig.Producer
-
getConfig
public void getConfig(com.yahoo.vespa.config.search.AttributesConfig.Builder builder, AttributeFields.FieldSet fs) -
getIndexingScript
-
getIndexInfo
-
setIndexingScript
-
getSchema
-
getRankProfileList
-
getVsmSummary
-
getVsmFields
-
getIndexSchema
-
getJuniperrc
-
getSummaryMap
-
getImportedFields
-
getQueryProfiles
public com.yahoo.search.query.profile.QueryProfileRegistry getQueryProfiles()
-