Extracting index building code to be run optionally

This is to allow the correct operation of local/remote lookups to be correctly indexed (after the resolver has run). Addresses an issue in vacuum https://github.com/daveshanley/vacuum/issues/294

Signed-off-by: Dave Shanley <dave@quobix.com>
This commit is contained in:
Dave Shanley
2023-06-17 12:54:51 -04:00
committed by quobix
parent c6659c8a5b
commit a4b7a01c43
4 changed files with 32 additions and 10 deletions

View File

@@ -24,6 +24,10 @@ type DocumentConfiguration struct {
// AllowRemoteReferences will allow the index to lookup remote references. This is disabled by default.
AllowRemoteReferences bool
// AvoidIndexBuild will avoid building the index. This is disabled by default, only use if you are sure you don't need it.
// This is useful for developers building out models that should be indexed later on.
AvoidIndexBuild bool
}
func NewOpenDocumentConfiguration() *DocumentConfiguration {