mirror of https://gitee.com/bigwinds/arangodb
Fix replicationFactor: -1 almost endless loop
This commit is contained in:
parent
69afcc0501
commit
aff77dea41
|
@ -381,7 +381,7 @@ LogicalCollection::LogicalCollection(TRI_vocbase_t* vocbase,
|
|||
_version(ReadNumericValue<uint32_t>(info, "version", currentVersion())),
|
||||
_indexBuckets(ReadNumericValue<uint32_t>(
|
||||
info, "indexBuckets", DatabaseFeature::defaultIndexBuckets())),
|
||||
_replicationFactor(ReadNumericValue<int>(info, "replicationFactor", 1)),
|
||||
_replicationFactor(ReadNumericValue<size_t>(info, "replicationFactor", 1)),
|
||||
_numberOfShards(ReadNumericValue<size_t>(info, "numberOfShards", 1)),
|
||||
_allowUserKeys(ReadBooleanValue(info, "allowUserKeys", true)),
|
||||
_shardIds(new ShardMap()),
|
||||
|
@ -870,7 +870,7 @@ void LogicalCollection::getIndexesVPack(VPackBuilder& result,
|
|||
|
||||
// SECTION: Replication
|
||||
int LogicalCollection::replicationFactor() const {
|
||||
return _replicationFactor;
|
||||
return static_cast<int>(_replicationFactor);
|
||||
}
|
||||
|
||||
// SECTION: Sharding
|
||||
|
|
|
@ -540,7 +540,7 @@ class LogicalCollection {
|
|||
std::vector<std::shared_ptr<arangodb::Index>> _indexes;
|
||||
|
||||
// SECTION: Replication
|
||||
int const _replicationFactor;
|
||||
size_t const _replicationFactor;
|
||||
|
||||
// SECTION: Sharding
|
||||
size_t _numberOfShards;
|
||||
|
|
Loading…
Reference in New Issue