rippled
Loading...
Searching...
No Matches
PeerFinder.h
1#pragma once
2
3#include <xrpld/core/Config.h>
4#include <xrpld/peerfinder/detail/Store.h>
5
6#include <xrpl/rdb/DatabaseCon.h>
7
8namespace xrpl {
9
16void
17initPeerFinderDB(soci::session& session, BasicConfig const& config, beast::Journal j);
18
25void
26updatePeerFinderDB(soci::session& session, int currentSchemaVersion, beast::Journal j);
27
34void
35readPeerFinderDB(soci::session& session, std::function<void(std::string const&, int)> const& func);
36
42void
43savePeerFinderDB(soci::session& session, std::vector<PeerFinder::Store::Entry> const& v);
44
45} // namespace xrpl
A generic endpoint for log messages.
Definition Journal.h:40
Use hash_* containers for keys that do not need a cryptographically secure hashing algorithm.
Definition algorithm.h:5
void readPeerFinderDB(soci::session &session, std::function< void(std::string const &, int)> const &func)
readPeerFinderDB Reads all entries from the peer finder database and invokes the given callback for e...
void updatePeerFinderDB(soci::session &session, int currentSchemaVersion, beast::Journal j)
updatePeerFinderDB Updates the peer finder database to a new version.
void initPeerFinderDB(soci::session &session, BasicConfig const &config, beast::Journal j)
initPeerFinderDB Opens a session with the peer finder database.
Definition PeerFinder.cpp:6
void savePeerFinderDB(soci::session &session, std::vector< PeerFinder::Store::Entry > const &v)
savePeerFinderDB Saves a new entry to the peer finder database.