File tree Expand file tree Collapse file tree 3 files changed +25
-0
lines changed
services/horizon/internal/test/integration Expand file tree Collapse file tree 3 files changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -113,6 +113,9 @@ type captiveCoreTomlValues struct {
113113 BucketListDBMemoryForCaching * uint `toml:"BUCKETLIST_DB_MEMORY_FOR_CACHING,omitempty"`
114114 EnableEmitClassicEvents * bool `toml:"EMIT_CLASSIC_EVENTS,omitempty"`
115115 EnableBackfillStellarAssetEvents * bool `toml:"BACKFILL_STELLAR_ASSET_EVENTS,omitempty"`
116+ OverrideEvictionParamsForTesting * bool `toml:"OVERRIDE_EVICTION_PARAMS_FOR_TESTING,omitempty"`
117+ TestingStartingEvictionScanLevel * uint `toml:"TESTING_STARTING_EVICTION_SCAN_LEVEL,omitempty"`
118+ TestingMaxEntriesToArchive * uint `toml:"TESTING_MAX_ENTRIES_TO_ARCHIVE,omitempty"`
116119}
117120
118121// QuorumSetIsConfigured returns true if there is a quorum set defined in the configuration.
Original file line number Diff line number Diff line change @@ -5,6 +5,9 @@ type validatorCoreConfigTemplatePrams struct {
55 NetworkPassphrase string
66 TestingMinimumPersistentEntryLifetime int
77 TestingSorobanHighLimitOverride bool
8+ OverrideEvictionParamsForTesting bool
9+ TestingStartingEvictionScanLevel uint
10+ TestingMaxEntriesToArchive uint
811}
912
1013type captiveCoreConfigTemplatePrams struct {
@@ -20,6 +23,12 @@ NETWORK_PASSPHRASE="{{ .NetworkPassphrase }}"
2023TESTING_MINIMUM_PERSISTENT_ENTRY_LIFETIME={{ .TestingMinimumPersistentEntryLifetime }}
2124TESTING_SOROBAN_HIGH_LIMIT_OVERRIDE={{ .TestingSorobanHighLimitOverride }}
2225
26+ {{if .OverrideEvictionParamsForTesting}}
27+ OVERRIDE_EVICTION_PARAMS_FOR_TESTING=true
28+ TESTING_MAX_ENTRIES_TO_ARCHIVE={{ .TestingMaxEntriesToArchive }}
29+ TESTING_STARTING_EVICTION_SCAN_LEVEL={{ .TestingStartingEvictionScanLevel }}
30+ {{end}}
31+
2332PEER_PORT=11625
2433HTTP_PORT=11626
2534PUBLIC_HTTP_PORT=true
@@ -52,6 +61,12 @@ TESTING_MINIMUM_PERSISTENT_ENTRY_LIFETIME={{ .TestingMinimumPersistentEntryLifet
5261TESTING_SOROBAN_HIGH_LIMIT_OVERRIDE={{ .TestingSorobanHighLimitOverride }}
5362ENABLE_SOROBAN_DIAGNOSTIC_EVENTS=true
5463
64+ {{if .OverrideEvictionParamsForTesting}}
65+ OVERRIDE_EVICTION_PARAMS_FOR_TESTING=true
66+ TESTING_MAX_ENTRIES_TO_ARCHIVE={{ .TestingMaxEntriesToArchive }}
67+ TESTING_STARTING_EVICTION_SCAN_LEVEL={{ .TestingStartingEvictionScanLevel }}
68+ {{end}}
69+
5570PEER_PORT=11725
5671
5772UNSAFE_QUORUM=true
Original file line number Diff line number Diff line change @@ -68,6 +68,7 @@ type Config struct {
6868 StellarRPCDockerImage string
6969 SkipProtocolUpgrade bool
7070 QuickExpiration bool
71+ QuickEviction bool
7172 NetworkPassphrase string
7273
7374 // Weird naming here because bools default to false, but we want to start
@@ -166,11 +167,17 @@ func NewTest(t *testing.T, config Config) *Test {
166167 NetworkPassphrase : config .NetworkPassphrase ,
167168 TestingMinimumPersistentEntryLifetime : 65536 ,
168169 TestingSorobanHighLimitOverride : false ,
170+ OverrideEvictionParamsForTesting : false ,
169171 }
170172 if config .QuickExpiration {
171173 validatorParams .TestingSorobanHighLimitOverride = true
172174 validatorParams .TestingMinimumPersistentEntryLifetime = 10
173175 }
176+ if config .QuickEviction {
177+ validatorParams .OverrideEvictionParamsForTesting = true
178+ validatorParams .TestingStartingEvictionScanLevel = 2
179+ validatorParams .TestingMaxEntriesToArchive = 100
180+ }
174181 var i * Test
175182 if ! config .SkipCoreContainerCreation {
176183 composePath := findDockerComposePath ()
You can’t perform that action at this time.
0 commit comments