Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

postgresql backend deprecation warning #4348

Merged

Conversation

ThomasBrady
Copy link
Contributor

@ThomasBrady ThomasBrady commented Jun 5, 2024

Description

Resolves #X

Example output:

config.cfg:

DATABASE="postgresql://foobar"

output:

 % ./src/stellar-core catchup current/1 --conf=config.cfg
Warning: running non-release version v21.0.0-76-g91d3468dd of stellar-core
2024-06-05T10:51:22.443 [default INFO] Config from config.cfg
2024-06-05T10:51:22.444 [Database WARNING] Support for postgresql backend is deprecated and will be removed in a future release of stellar-core.

Checklist

  • Reviewed the contributing document
  • Rebased on top of master (no merge commits)
  • Ran clang-format v8.0.0 (via make format or the Visual Studio extension)
  • Compiles
  • Ran all tests
  • If change impacts performance, include supporting evidence per the performance document

@@ -1433,6 +1433,17 @@ Config::processConfig(std::shared_ptr<cpptoml::table> t)
else if (item.first == "DATABASE")
{
DATABASE = SecretValue{readString(item)};
auto connectString = DATABASE.value;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can use Database::isSqlite condition to avoid re-implementing string search. The warning should probably clarify that future versions of core will only support BucketListDB for ledger state with SQLite for misc data, with all other backends deprecated.

@ThomasBrady ThomasBrady force-pushed the deprecate-postgresql-db-backend branch from 91d3468 to 484c2a5 Compare June 5, 2024 23:25
Copy link
Contributor

@SirTyson SirTyson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@SirTyson
Copy link
Contributor

SirTyson commented Jun 6, 2024

r+ 0a5dd88

@latobarita latobarita merged commit 99cbf44 into stellar:master Jun 6, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants