Add 'dangerously_use_adapter_prefixes' setting

This commit adds a setting to not scan the triplestore for prefixes, but
instead use the prefixes listed in adapaters as the only URIs to
resolve.
This commit is contained in:
Tom Wiesing 2024-04-08 14:43:40 +02:00
parent fd53a901c3
commit 7763644ebe
No known key found for this signature in database
4 changed files with 69 additions and 14 deletions

View file

@ -113,6 +113,10 @@ triplestore:
user_prefix: null
data_prefix: null
# if desired, turn off regularly scanning for prefixes in the triplestore.
# DANGER: Turning this on will break the global resolver.
dangerously_use_adapter_prefixes: false
# The maximum agefor backups to be kept.
# Backups older than this will be removed when a new backup is made.
# The default here is 720hours (== 30 days)

View file

@ -1,5 +1,7 @@
package config
import "github.com/FAU-CDI/wisski-distillery/internal/config/validators"
type DatabaseConfig struct {
// Credentials for the admin user.
// Is automatically created if it does not exist.
@ -20,4 +22,8 @@ type SQLConfig struct {
type TSConfig struct {
DatabaseConfig `yaml:",inline" recurse:"true"`
// DangerouslyUseAdapterPrefixes inidicates if scanning for prefixes should just use prefixes declared in all adapters.
// This may not reflect what is actually in the database.
DangerouslyUseAdapterPrefixes validators.NullableBool `yaml:"dangerously_use_adapter_prefixes" default:"false" validate:"bool"`
}