Skip to content

Commit

Permalink
services/horizon: Update default for --captive-core-use-db to true (#…
Browse files Browse the repository at this point in the history
…4877)

* 4856: Update default for  --captive-core-use-db to true
* Update CHANGELOG.md
  • Loading branch information
urvisavla authored Jun 6, 2023
1 parent b060996 commit da99d59
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 5 additions & 0 deletions services/horizon/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ file. This project adheres to [Semantic Versioning](http://semver.org/).


## Unreleased
### Changes
### Breaking Changes
- Modify the default value of `--captive-core-use-db` to true ([4856](https://github.com/stellar/go/issues/4856))
- This updates the default behavior of captive core to start in on-disk mode.
- To continue using the previous in-memory mode, explicitly set the `--captive-core-use-db` flag to false

## 2.24.1

Expand Down
5 changes: 1 addition & 4 deletions services/horizon/internal/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ func Flags() (*Config, support.ConfigOptions) {
&support.ConfigOption{
Name: CaptiveCoreConfigUseDB,
OptType: types.Bool,
FlagDefault: false,
FlagDefault: true,
Required: false,
Usage: `when enabled, Horizon ingestion will instruct the captive
core invocation to use an external db url for ledger states rather than in memory(RAM).\n
Expand Down Expand Up @@ -736,9 +736,6 @@ func ApplyFlags(config *Config, flags support.ConfigOptions, options ApplyOption
if config.StellarCoreDatabaseURL != "" {
return fmt.Errorf("Invalid config: --%s passed but --ingest not set. ", StellarCoreDBURLFlagName)
}
if config.CaptiveCoreConfigUseDB {
return fmt.Errorf("Invalid config: --%s has been set, but --ingest not set. ", CaptiveCoreConfigUseDB)
}
}

// Configure log file
Expand Down

0 comments on commit da99d59

Please sign in to comment.