Make function declarations less verbose
This commit is contained in:
parent
ccffd6f47f
commit
d84b2a95e2
|
@ -280,7 +280,7 @@ public:
|
|||
static Key getPauseKey();
|
||||
|
||||
// parallel restore
|
||||
Future<Void> parallelRestoreFinish(Database cx, UID randomUID, UnlockDB unlockDB = UnlockDB::TRUE);
|
||||
Future<Void> parallelRestoreFinish(Database cx, UID randomUID, UnlockDB = UnlockDB::TRUE);
|
||||
Future<Void> submitParallelRestore(Database cx,
|
||||
Key backupTag,
|
||||
Standalone<VectorRef<KeyRangeRef>> backupRanges,
|
||||
|
@ -308,12 +308,12 @@ public:
|
|||
Key tagName,
|
||||
Key url,
|
||||
Standalone<VectorRef<KeyRangeRef>> ranges,
|
||||
WaitForComplete waitForComplete = WaitForComplete::TRUE,
|
||||
WaitForComplete = WaitForComplete::TRUE,
|
||||
Version targetVersion = ::invalidVersion,
|
||||
Verbose verbose = Verbose::TRUE,
|
||||
Verbose = Verbose::TRUE,
|
||||
Key addPrefix = Key(),
|
||||
Key removePrefix = Key(),
|
||||
LockDB lockDB = LockDB::TRUE,
|
||||
LockDB = LockDB::TRUE,
|
||||
OnlyApplyMutationLogs = OnlyApplyMutationLogs::FALSE,
|
||||
InconsistentSnapshotOnly = InconsistentSnapshotOnly::FALSE,
|
||||
Version beginVersion = ::invalidVersion);
|
||||
|
@ -367,7 +367,7 @@ public:
|
|||
Future<ERestoreState> abortRestore(Database cx, Key tagName);
|
||||
|
||||
// Waits for a restore tag to reach a final (stable) state.
|
||||
Future<ERestoreState> waitRestore(Database cx, Key tagName, Verbose verbose);
|
||||
Future<ERestoreState> waitRestore(Database cx, Key tagName, Verbose);
|
||||
|
||||
// Get a string describing the status of a tag
|
||||
Future<std::string> restoreStatus(Reference<ReadYourWritesTransaction> tr, Key tagName);
|
||||
|
@ -384,7 +384,7 @@ public:
|
|||
int snapshotIntervalSeconds,
|
||||
std::string tagName,
|
||||
Standalone<VectorRef<KeyRangeRef>> backupRanges,
|
||||
StopWhenDone stopWhenDone = StopWhenDone::TRUE,
|
||||
StopWhenDone = StopWhenDone::TRUE,
|
||||
UsePartitionedLog = UsePartitionedLog::FALSE,
|
||||
IncrementalBackupOnly = IncrementalBackupOnly::FALSE);
|
||||
Future<Void> submitBackup(Database cx,
|
||||
|
@ -432,14 +432,14 @@ public:
|
|||
|
||||
Future<Optional<Version>> getLastRestorable(Reference<ReadYourWritesTransaction> tr,
|
||||
Key tagName,
|
||||
Snapshot snapshot = Snapshot::FALSE);
|
||||
Snapshot = Snapshot::FALSE);
|
||||
void setLastRestorable(Reference<ReadYourWritesTransaction> tr, Key tagName, Version version);
|
||||
|
||||
// stopWhenDone will return when the backup is stopped, if enabled. Otherwise, it
|
||||
// will return when the backup directory is restorable.
|
||||
Future<EnumState> waitBackup(Database cx,
|
||||
std::string tagName,
|
||||
StopWhenDone stopWhenDone = StopWhenDone::TRUE,
|
||||
StopWhenDone = StopWhenDone::TRUE,
|
||||
Reference<IBackupContainer>* pContainer = nullptr,
|
||||
UID* pUID = nullptr);
|
||||
|
||||
|
@ -507,7 +507,7 @@ public:
|
|||
Standalone<VectorRef<KeyRangeRef>> backupRanges,
|
||||
Key addPrefix,
|
||||
Key removePrefix,
|
||||
ForceAction forceAction = ForceAction::FALSE);
|
||||
ForceAction = ForceAction::FALSE);
|
||||
|
||||
Future<Void> unlockBackup(Reference<ReadYourWritesTransaction> tr, Key tagName);
|
||||
Future<Void> unlockBackup(Database cx, Key tagName) {
|
||||
|
@ -526,7 +526,7 @@ public:
|
|||
Future<Void> submitBackup(Reference<ReadYourWritesTransaction> tr,
|
||||
Key tagName,
|
||||
Standalone<VectorRef<KeyRangeRef>> backupRanges,
|
||||
StopWhenDone stopWhenDone = StopWhenDone::TRUE,
|
||||
StopWhenDone = StopWhenDone::TRUE,
|
||||
Key addPrefix = StringRef(),
|
||||
Key removePrefix = StringRef(),
|
||||
LockDB lockDatabase = LockDB::FALSE,
|
||||
|
@ -566,25 +566,23 @@ public:
|
|||
[=](Reference<ReadYourWritesTransaction> tr) { return getStateValue(tr, logUid); });
|
||||
}
|
||||
|
||||
Future<UID> getDestUid(Reference<ReadYourWritesTransaction> tr, UID logUid, Snapshot snapshot = Snapshot::FALSE);
|
||||
Future<UID> getDestUid(Reference<ReadYourWritesTransaction> tr, UID logUid, Snapshot = Snapshot::FALSE);
|
||||
Future<UID> getDestUid(Database cx, UID logUid) {
|
||||
return runRYWTransaction(cx, [=](Reference<ReadYourWritesTransaction> tr) { return getDestUid(tr, logUid); });
|
||||
}
|
||||
|
||||
Future<UID> getLogUid(Reference<ReadYourWritesTransaction> tr, Key tagName, Snapshot snapshot = Snapshot::FALSE);
|
||||
Future<UID> getLogUid(Reference<ReadYourWritesTransaction> tr, Key tagName, Snapshot = Snapshot::FALSE);
|
||||
Future<UID> getLogUid(Database cx, Key tagName) {
|
||||
return runRYWTransaction(cx, [=](Reference<ReadYourWritesTransaction> tr) { return getLogUid(tr, tagName); });
|
||||
}
|
||||
|
||||
Future<int64_t> getRangeBytesWritten(Reference<ReadYourWritesTransaction> tr,
|
||||
UID logUid,
|
||||
Snapshot snapshot = Snapshot::FALSE);
|
||||
Future<int64_t> getLogBytesWritten(Reference<ReadYourWritesTransaction> tr,
|
||||
UID logUid,
|
||||
Snapshot snapshot = Snapshot::FALSE);
|
||||
Snapshot = Snapshot::FALSE);
|
||||
Future<int64_t> getLogBytesWritten(Reference<ReadYourWritesTransaction> tr, UID logUid, Snapshot = Snapshot::FALSE);
|
||||
// stopWhenDone will return when the backup is stopped, if enabled. Otherwise, it
|
||||
// will return when the backup directory is restorable.
|
||||
Future<EnumState> waitBackup(Database cx, Key tagName, StopWhenDone stopWhenDone = StopWhenDone::TRUE);
|
||||
Future<EnumState> waitBackup(Database cx, Key tagName, StopWhenDone = StopWhenDone::TRUE);
|
||||
Future<EnumState> waitSubmitted(Database cx, Key tagName);
|
||||
Future<Void> waitUpgradeToLatestDrVersion(Database cx, Key tagName);
|
||||
|
||||
|
|
|
@ -159,9 +159,9 @@ public:
|
|||
LocalityData clientLocality,
|
||||
EnableLocalityLoadBalance,
|
||||
TaskPriority taskID = TaskPriority::DefaultEndpoint,
|
||||
LockAware lockAware = LockAware::FALSE,
|
||||
LockAware = LockAware::FALSE,
|
||||
int apiVersion = Database::API_VERSION_LATEST,
|
||||
IsSwitchable switchable = IsSwitchable::FALSE);
|
||||
IsSwitchable = IsSwitchable::FALSE);
|
||||
|
||||
~DatabaseContext();
|
||||
|
||||
|
@ -242,7 +242,7 @@ public:
|
|||
// new cluster.
|
||||
Future<Void> switchConnectionFile(Reference<ClusterConnectionFile> standby);
|
||||
Future<Void> connectionFileChanged();
|
||||
IsSwitchable switchable{ IsSwitchable::FALSE };
|
||||
IsSwitchable switchable{ false };
|
||||
|
||||
// Management API, Attempt to kill or suspend a process, return 1 for request sent out, 0 for failure
|
||||
Future<int64_t> rebootWorker(StringRef address, bool check = false, int duration = 0);
|
||||
|
@ -261,9 +261,9 @@ public:
|
|||
LocalityData const& clientLocality,
|
||||
EnableLocalityLoadBalance,
|
||||
LockAware,
|
||||
IsInternal internal = IsInternal::TRUE,
|
||||
IsInternal = IsInternal::TRUE,
|
||||
int apiVersion = Database::API_VERSION_LATEST,
|
||||
IsSwitchable switchable = IsSwitchable::FALSE);
|
||||
IsSwitchable = IsSwitchable::FALSE);
|
||||
|
||||
explicit DatabaseContext(const Error& err);
|
||||
|
||||
|
|
|
@ -50,18 +50,18 @@ public:
|
|||
virtual void setVersion(Version v) = 0;
|
||||
virtual Future<Version> getReadVersion() = 0;
|
||||
virtual Optional<Version> getCachedReadVersion() const = 0;
|
||||
virtual Future<Optional<Value>> get(const Key& key, Snapshot snapshot = Snapshot::FALSE) = 0;
|
||||
virtual Future<Key> getKey(const KeySelector& key, Snapshot snapshot = Snapshot::FALSE) = 0;
|
||||
virtual Future<Optional<Value>> get(const Key& key, Snapshot = Snapshot::FALSE) = 0;
|
||||
virtual Future<Key> getKey(const KeySelector& key, Snapshot = Snapshot::FALSE) = 0;
|
||||
virtual Future<Standalone<RangeResultRef>> getRange(const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) = 0;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) = 0;
|
||||
virtual Future<Standalone<RangeResultRef>> getRange(KeySelector begin,
|
||||
KeySelector end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) = 0;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) = 0;
|
||||
virtual Future<Standalone<VectorRef<const char*>>> getAddressesForKey(Key const& key) = 0;
|
||||
virtual Future<Standalone<VectorRef<KeyRef>>> getRangeSplitPoints(KeyRange const& range, int64_t chunkSize) = 0;
|
||||
virtual Future<int64_t> getEstimatedRangeSizeBytes(KeyRange const& keys) = 0;
|
||||
|
|
|
@ -115,7 +115,7 @@ private:
|
|||
void setNetworkOption(FDBNetworkOptions::Option option, Optional<StringRef> value = Optional<StringRef>());
|
||||
|
||||
// Configures the global networking machinery
|
||||
void setupNetwork(uint64_t transportId = 0, UseMetrics useMetrics = UseMetrics::FALSE);
|
||||
void setupNetwork(uint64_t transportId = 0, UseMetrics = UseMetrics::FALSE);
|
||||
|
||||
// This call blocks while the network is running. To use the API in a single-threaded
|
||||
// environment, the calling program must have ACTORs already launched that are waiting
|
||||
|
@ -251,20 +251,20 @@ public:
|
|||
Future<Version> getRawReadVersion();
|
||||
Optional<Version> getCachedReadVersion() const;
|
||||
|
||||
[[nodiscard]] Future<Optional<Value>> get(const Key& key, Snapshot snapshot = Snapshot::FALSE);
|
||||
[[nodiscard]] Future<Optional<Value>> get(const Key& key, Snapshot = Snapshot::FALSE);
|
||||
[[nodiscard]] Future<Void> watch(Reference<Watch> watch);
|
||||
[[nodiscard]] Future<Key> getKey(const KeySelector& key, Snapshot snapshot = Snapshot::FALSE);
|
||||
[[nodiscard]] Future<Key> getKey(const KeySelector& key, Snapshot = Snapshot::FALSE);
|
||||
// Future< Optional<KeyValue> > get( const KeySelectorRef& key );
|
||||
[[nodiscard]] Future<RangeResult> getRange(const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE);
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE);
|
||||
[[nodiscard]] Future<RangeResult> getRange(const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE);
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE);
|
||||
[[nodiscard]] Future<RangeResult> getRange(const KeyRange& keys,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
|
@ -292,14 +292,14 @@ public:
|
|||
const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE);
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE);
|
||||
[[nodiscard]] Future<Void> getRangeStream(const PromiseStream<Standalone<RangeResultRef>>& results,
|
||||
const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE);
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE);
|
||||
[[nodiscard]] Future<Void> getRangeStream(const PromiseStream<Standalone<RangeResultRef>>& results,
|
||||
const KeyRange& keys,
|
||||
int limit,
|
||||
|
@ -351,13 +351,13 @@ public:
|
|||
// The returned list would still be in form of [keys.begin, splitPoint1, splitPoint2, ... , keys.end]
|
||||
Future<Standalone<VectorRef<KeyRef>>> getRangeSplitPoints(KeyRange const& keys, int64_t chunkSize);
|
||||
// If checkWriteConflictRanges is true, existing write conflict ranges will be searched for this key
|
||||
void set(const KeyRef& key, const ValueRef& value, AddConflictRange addConflictRange = AddConflictRange::TRUE);
|
||||
void set(const KeyRef& key, const ValueRef& value, AddConflictRange = AddConflictRange::TRUE);
|
||||
void atomicOp(const KeyRef& key,
|
||||
const ValueRef& value,
|
||||
MutationRef::Type operationType,
|
||||
AddConflictRange addConflictRange = AddConflictRange::TRUE);
|
||||
void clear(const KeyRangeRef& range, AddConflictRange addConflictRange = AddConflictRange::TRUE);
|
||||
void clear(const KeyRef& key, AddConflictRange addConflictRange = AddConflictRange::TRUE);
|
||||
AddConflictRange = AddConflictRange::TRUE);
|
||||
void clear(const KeyRangeRef& range, AddConflictRange = AddConflictRange::TRUE);
|
||||
void clear(const KeyRef& key, AddConflictRange = AddConflictRange::TRUE);
|
||||
[[nodiscard]] Future<Void> commit(); // Throws not_committed or commit_unknown_result errors in normal operation
|
||||
|
||||
void setOption(FDBTransactionOptions::Option option, Optional<StringRef> value = Optional<StringRef>());
|
||||
|
|
|
@ -38,17 +38,17 @@ public:
|
|||
Future<Version> getReadVersion() override;
|
||||
Optional<Version> getCachedReadVersion() const override;
|
||||
|
||||
Future<Optional<Value>> get(Key const& key, Snapshot snapshot = Snapshot::FALSE) override;
|
||||
Future<Optional<Value>> get(Key const& key, Snapshot = Snapshot::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(KeySelector const& begin,
|
||||
KeySelector const& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(KeySelector begin,
|
||||
KeySelector end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
void set(KeyRef const& key, ValueRef const& value) override;
|
||||
void clear(KeyRangeRef const&) override { throw client_invalid_operation(); }
|
||||
void clear(KeyRef const&) override;
|
||||
|
|
|
@ -71,18 +71,18 @@ public:
|
|||
void setVersion(Version v) override { tr.setVersion(v); }
|
||||
Future<Version> getReadVersion() override;
|
||||
Optional<Version> getCachedReadVersion() const override { return tr.getCachedReadVersion(); }
|
||||
Future<Optional<Value>> get(const Key& key, Snapshot snapshot = Snapshot::FALSE) override;
|
||||
Future<Key> getKey(const KeySelector& key, Snapshot snapshot = Snapshot::FALSE) override;
|
||||
Future<Optional<Value>> get(const Key& key, Snapshot = Snapshot::FALSE) override;
|
||||
Future<Key> getKey(const KeySelector& key, Snapshot = Snapshot::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(const KeySelector& begin,
|
||||
const KeySelector& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(KeySelector begin,
|
||||
KeySelector end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(const KeyRange& keys,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
|
|
|
@ -47,17 +47,17 @@ public:
|
|||
Future<Version> getReadVersion() override;
|
||||
Optional<Version> getCachedReadVersion() const override;
|
||||
|
||||
Future<Optional<Value>> get(Key const& key, Snapshot snapshot = Snapshot::FALSE) override;
|
||||
Future<Optional<Value>> get(Key const& key, Snapshot = Snapshot::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(KeySelector const& begin,
|
||||
KeySelector const& end,
|
||||
int limit,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
Future<Standalone<RangeResultRef>> getRange(KeySelector begin,
|
||||
KeySelector end,
|
||||
GetRangeLimits limits,
|
||||
Snapshot snapshot = Snapshot::FALSE,
|
||||
Reverse reverse = Reverse::FALSE) override;
|
||||
Snapshot = Snapshot::FALSE,
|
||||
Reverse = Reverse::FALSE) override;
|
||||
Future<Void> commit() override;
|
||||
Version getCommittedVersion() const override;
|
||||
void setOption(FDBTransactionOptions::Option option, Optional<StringRef> value = Optional<StringRef>()) override;
|
||||
|
|
|
@ -168,7 +168,7 @@ public:
|
|||
KeySelector begin,
|
||||
KeySelector end,
|
||||
GetRangeLimits limits,
|
||||
Reverse reverse = Reverse::FALSE);
|
||||
Reverse = Reverse::FALSE);
|
||||
|
||||
void set(ReadYourWritesTransaction* ryw, const KeyRef& key, const ValueRef& value);
|
||||
|
||||
|
|
|
@ -140,9 +140,9 @@ class FutureBucket;
|
|||
class TaskBucket : public ReferenceCounted<TaskBucket> {
|
||||
public:
|
||||
TaskBucket(const Subspace& subspace,
|
||||
AccessSystemKeys sysAccess = AccessSystemKeys::FALSE,
|
||||
PriorityBatch priorityBatch = PriorityBatch::FALSE,
|
||||
LockAware lockAware = LockAware::FALSE);
|
||||
AccessSystemKeys = AccessSystemKeys::FALSE,
|
||||
PriorityBatch = PriorityBatch::FALSE,
|
||||
LockAware = LockAware::FALSE);
|
||||
virtual ~TaskBucket();
|
||||
|
||||
void setOptions(Reference<ReadYourWritesTransaction> tr) {
|
||||
|
@ -308,9 +308,7 @@ class TaskFuture;
|
|||
|
||||
class FutureBucket : public ReferenceCounted<FutureBucket> {
|
||||
public:
|
||||
FutureBucket(const Subspace& subspace,
|
||||
AccessSystemKeys sysAccess = AccessSystemKeys::FALSE,
|
||||
LockAware lockAware = LockAware::FALSE);
|
||||
FutureBucket(const Subspace& subspace, AccessSystemKeys = AccessSystemKeys::FALSE, LockAware = LockAware::FALSE);
|
||||
virtual ~FutureBucket();
|
||||
|
||||
void setOptions(Reference<ReadYourWritesTransaction> tr) {
|
||||
|
|
|
@ -249,7 +249,7 @@ struct RequestData : NonCopyable {
|
|||
|
||||
Future<Reply> response;
|
||||
Reference<ModelHolder> modelHolder;
|
||||
TriedAllOptions triedAllOptions{ TriedAllOptions::FALSE };
|
||||
TriedAllOptions triedAllOptions{ false };
|
||||
|
||||
bool requestStarted = false; // true once the request has been sent to an alternative
|
||||
bool requestProcessed = false; // true once a response has been received and handled by checkAndProcessResult
|
||||
|
|
|
@ -51,7 +51,7 @@ public:
|
|||
LocalConfiguration(std::string const& dataFolder,
|
||||
std::string const& configPath,
|
||||
std::map<std::string, std::string> const& manualKnobOverrides,
|
||||
IsTest isTest = IsTest::FALSE);
|
||||
IsTest = IsTest::FALSE);
|
||||
LocalConfiguration(LocalConfiguration&&);
|
||||
LocalConfiguration& operator=(LocalConfiguration&&);
|
||||
~LocalConfiguration();
|
||||
|
|
|
@ -833,8 +833,8 @@ struct ServerDBInfo;
|
|||
|
||||
class Database openDBOnServer(Reference<AsyncVar<ServerDBInfo>> const& db,
|
||||
TaskPriority taskID = TaskPriority::DefaultEndpoint,
|
||||
LockAware lockAware = LockAware::FALSE,
|
||||
EnableLocalityLoadBalance enableLocalityLoadBalance = EnableLocalityLoadBalance::TRUE);
|
||||
LockAware = LockAware::FALSE,
|
||||
EnableLocalityLoadBalance = EnableLocalityLoadBalance::TRUE);
|
||||
ACTOR Future<Void> extractClusterInterface(Reference<AsyncVar<Optional<struct ClusterControllerFullInterface>>> a,
|
||||
Reference<AsyncVar<Optional<struct ClusterInterface>>> b);
|
||||
|
||||
|
|
Loading…
Reference in New Issue