mirror of https://gitee.com/bigwinds/arangodb
Merge branch 'devel' of https://github.com/arangodb/arangodb into devel
This commit is contained in:
commit
9bf9204888
|
@ -43,7 +43,6 @@ class ExecutionEngineResult : public Result {
|
|||
// This is not explicit on purpose
|
||||
// NOLINTNEXTLINE(google-explicit-constructor,hicpp-explicit-conversions)
|
||||
ExecutionEngineResult(Result const& result);
|
||||
|
||||
explicit ExecutionEngineResult(ExecutionEngine*);
|
||||
|
||||
~ExecutionEngineResult();
|
||||
|
|
|
@ -217,7 +217,7 @@ EngineInfoContainerDBServer::CollectionInfo::CollectionInfo(
|
|||
|
||||
EngineInfoContainerDBServer::CollectionInfo::~CollectionInfo() {}
|
||||
|
||||
void EngineInfoContainerDBServer::CollectionInfo::mergeShards(std::shared_ptr<std::vector<ShardID>> shards) {
|
||||
void EngineInfoContainerDBServer::CollectionInfo::mergeShards(std::shared_ptr<std::vector<ShardID>> const& shards) {
|
||||
for (auto const& s : *shards) {
|
||||
usedShards.emplace(s);
|
||||
}
|
||||
|
|
|
@ -145,7 +145,7 @@ class EngineInfoContainerDBServer {
|
|||
CollectionInfo(AccessMode::Type lock, std::shared_ptr<std::vector<ShardID>> shards);
|
||||
~CollectionInfo();
|
||||
|
||||
void mergeShards(std::shared_ptr<std::vector<ShardID>> shards);
|
||||
void mergeShards(std::shared_ptr<std::vector<ShardID>> const& shards);
|
||||
|
||||
AccessMode::Type lockType;
|
||||
std::vector<std::shared_ptr<EngineInfo>> engines;
|
||||
|
|
|
@ -86,7 +86,7 @@ class NearUtils {
|
|||
typedef std::priority_queue<Document, std::vector<Document>, CMP>
|
||||
GeoDocumentsQueue;
|
||||
|
||||
NearUtils(geo::QueryParams&& params) noexcept;
|
||||
explicit NearUtils(geo::QueryParams&& params) noexcept;
|
||||
~NearUtils();
|
||||
|
||||
public:
|
||||
|
|
|
@ -1726,7 +1726,7 @@ bool MMFilesLogfileManager::executeWhileNothingQueued(std::function<void()> cons
|
|||
|
||||
// wait until a specific logfile has been collected
|
||||
int MMFilesLogfileManager::waitForCollector(MMFilesWalLogfile::IdType logfileId,
|
||||
double maxWaitTime) {
|
||||
double maxWaitTime) {
|
||||
if (maxWaitTime <= 0.0) {
|
||||
maxWaitTime = 24.0 * 3600.0; // wait "forever"
|
||||
}
|
||||
|
@ -1771,6 +1771,10 @@ int MMFilesLogfileManager::waitForCollector(MMFilesWalLogfile::IdType logfileId,
|
|||
LOG_TOPIC(DEBUG, arangodb::Logger::FIXME) << "going into lock timeout. having waited for logfile: " << logfileId << ", maxWaitTime: " << maxWaitTime;
|
||||
logStatus();
|
||||
|
||||
if (application_features::ApplicationServer::isStopping()) {
|
||||
return TRI_ERROR_SHUTTING_DOWN;
|
||||
}
|
||||
|
||||
// waited for too long
|
||||
return TRI_ERROR_LOCK_TIMEOUT;
|
||||
}
|
||||
|
|
|
@ -143,7 +143,7 @@ class RocksDBValue {
|
|||
RocksDBValue(RocksDBEntryType type, LocalDocumentId const& docId, TRI_voc_rid_t revision);
|
||||
RocksDBValue(RocksDBEntryType type, VPackSlice const& data);
|
||||
RocksDBValue(RocksDBEntryType type, arangodb::StringRef const& data);
|
||||
RocksDBValue(S2Point const&);
|
||||
explicit RocksDBValue(S2Point const&);
|
||||
|
||||
private:
|
||||
static RocksDBEntryType type(char const* data, size_t size);
|
||||
|
|
|
@ -36,7 +36,7 @@ namespace arangodb {
|
|||
|
||||
class StatisticsWorker final : public Thread {
|
||||
public:
|
||||
StatisticsWorker(TRI_vocbase_t& vocbase);
|
||||
explicit StatisticsWorker(TRI_vocbase_t& vocbase);
|
||||
~StatisticsWorker() { shutdown(); }
|
||||
|
||||
void run() override;
|
||||
|
|
|
@ -45,7 +45,7 @@ Result GeoUtils::indexCellsLatLng(VPackSlice const& data, bool isGeoJson,
|
|||
|
||||
VPackSlice lat = data.at(isGeoJson ? 1 : 0);
|
||||
VPackSlice lon = data.at(isGeoJson ? 0 : 1);
|
||||
if (!lat.isNumber() || !lat.isNumber()) {
|
||||
if (!lat.isNumber() || !lon.isNumber()) {
|
||||
return TRI_ERROR_BAD_PARAMETER;
|
||||
}
|
||||
S2LatLng ll = S2LatLng::FromDegrees(lat.getNumericValue<double>(),
|
||||
|
|
|
@ -53,7 +53,7 @@ class S2MultiPointRegion final : public S2Region {
|
|||
private:
|
||||
|
||||
// private constructor for clone
|
||||
S2MultiPointRegion(S2MultiPointRegion const*);
|
||||
explicit S2MultiPointRegion(S2MultiPointRegion const*);
|
||||
|
||||
int num_points_;
|
||||
S2Point* points_;
|
||||
|
|
|
@ -47,7 +47,7 @@ class S2MultiPolyline : public S2Region {
|
|||
|
||||
size_t num_lines() const { return lines_.size(); }
|
||||
S2Polyline const& line(size_t k) const {
|
||||
assert(k >= 0 && k < lines_.size());
|
||||
assert(k < lines_.size());
|
||||
//DCHECK_LT(k, lines_.size());
|
||||
return lines_[k];
|
||||
}
|
||||
|
@ -71,7 +71,7 @@ class S2MultiPolyline : public S2Region {
|
|||
private:
|
||||
// Internal constructor used only by Clone() that makes a deep copy of
|
||||
// its argument.
|
||||
S2MultiPolyline(S2MultiPolyline const* src);
|
||||
explicit S2MultiPolyline(S2MultiPolyline const* src);
|
||||
|
||||
// We store the vertices in an array rather than a vector because we don't
|
||||
// need any STL methods, and computing the number of vertices using size()
|
||||
|
|
|
@ -469,12 +469,10 @@ bool ShapeContainer::equals(S2Polygon const* other) const {
|
|||
}
|
||||
|
||||
bool ShapeContainer::equals(ShapeContainer const* cc) const {
|
||||
bool result = false;
|
||||
|
||||
// equals function will only trigger for equal types
|
||||
// if types are not equal, result is false
|
||||
if (cc->_type != _type) {
|
||||
return result;
|
||||
return false;
|
||||
}
|
||||
|
||||
switch (cc->_type) {
|
||||
|
|
Loading…
Reference in New Issue