mirror of https://gitee.com/bigwinds/arangodb
Fix compiler warnings
This commit is contained in:
parent
67066c64ad
commit
00d77cbb5e
|
@ -634,6 +634,7 @@ GraphFormat<DMIDValue, float>* DMID::inputFormat() const {
|
|||
|
||||
struct DMIDMasterContext : public MasterContext {
|
||||
DMIDMasterContext() {} // TODO use _threashold
|
||||
|
||||
void preGlobalSuperstep() override {
|
||||
|
||||
/**
|
||||
|
|
|
@ -460,7 +460,7 @@ static void resolveInfo(
|
|||
std::vector<ShardID>& allShards) {
|
||||
|
||||
ServerState *ss = ServerState::instance();
|
||||
if (!ss->isRunningInCluster()) {
|
||||
if (!ss->isRunningInCluster()) { // single server mode
|
||||
LogicalCollection *lc = vocbase->lookupCollection(collectionID);
|
||||
if (lc == nullptr || lc->deleted()) {
|
||||
THROW_ARANGO_EXCEPTION_MESSAGE(TRI_ERROR_ARANGO_COLLECTION_NOT_FOUND,
|
||||
|
|
|
@ -122,8 +122,8 @@ void GraphStore<V, E>::loadShards(WorkerConfig* config,
|
|||
if (_loadedShards.find(vertexShards[i]) != _loadedShards.end()) {
|
||||
continue;
|
||||
}
|
||||
ShardID const& vertexShard(vertexShards[i]);
|
||||
|
||||
ShardID const& vertexShard = vertexShards[i];
|
||||
uint64_t nextEdgeOffset = edgeOffset;
|
||||
std::vector<ShardID> edgeLookups;
|
||||
// distributeshardslike should cause the edges for a vertex to be
|
||||
|
@ -326,8 +326,8 @@ void GraphStore<V, E>::_loadVertices(ShardID const& vertexShard,
|
|||
_graphFormat->copyVertexData(documentId, document, ptr, sizeof(V));
|
||||
}
|
||||
// load edges
|
||||
for (ShardID const& it : edgeShards) {
|
||||
_loadEdges(trx.get(), it, ventry, documentId);
|
||||
for (ShardID const& edgeShard : edgeShards) {
|
||||
_loadEdges(trx.get(), edgeShard, ventry, documentId);
|
||||
}
|
||||
vertexOffset++;
|
||||
edgeOffset += ventry._edgeCount;
|
||||
|
@ -403,9 +403,12 @@ void GraphStore<V, E>::_loadEdges(transaction::Methods* trx,
|
|||
_graphFormat->copyEdgeData(document, edge.data(), sizeof(E));
|
||||
if (sourceShard == (prgl_shard_t)-1 ||
|
||||
edge._targetShard == (prgl_shard_t)-1) {
|
||||
LOG_TOPIC(ERR, Logger::PREGEL) << "Could not resolve target shard of edge";
|
||||
return;
|
||||
}
|
||||
offset++;
|
||||
} else {
|
||||
LOG_TOPIC(ERR, Logger::PREGEL) << "Could not resolve target shard of edge";
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
@ -43,6 +43,7 @@ class MasterContext {
|
|||
|
||||
public:
|
||||
MasterContext(){};
|
||||
virtual ~MasterContext(){}
|
||||
|
||||
inline uint64_t globalSuperstep() const { return _globalSuperstep; }
|
||||
|
||||
|
|
|
@ -127,9 +127,9 @@ int Utils::resolveShard(WorkerConfig const* config,
|
|||
partial.close();
|
||||
// LOG_TOPIC(INFO, Logger::PREGEL) << "Partial doc: " << partial.toJson();
|
||||
int res =
|
||||
ci->getResponsibleShard(info.get(), partial.slice(), true, responsibleShard,
|
||||
ci->getResponsibleShard(info.get(), partial.slice(), false, responsibleShard,
|
||||
usesDefaultShardingAttributes);
|
||||
TRI_ASSERT(usesDefaultShardingAttributes); // should be true anyway
|
||||
//TRI_ASSERT(usesDefaultShardingAttributes); // should be true anyway
|
||||
|
||||
return res;
|
||||
}
|
||||
|
|
|
@ -52,7 +52,7 @@ class VertexContext {
|
|||
VertexEntry* _vertexEntry;
|
||||
|
||||
public:
|
||||
~VertexContext() {}
|
||||
virtual ~VertexContext() {}
|
||||
|
||||
template <typename T>
|
||||
inline void aggregate(std::string const& name, T const& value) {
|
||||
|
@ -105,6 +105,8 @@ class VertexComputation : public VertexContext<V, E, M> {
|
|||
bool _enterNextGSS = false;
|
||||
|
||||
public:
|
||||
virtual ~VertexComputation() {}
|
||||
|
||||
void sendMessage(Edge<E> const* edge, M const& data) {
|
||||
_cache->appendMessage(edge->targetShard(), edge->toKey(), data);
|
||||
}
|
||||
|
@ -140,6 +142,7 @@ class VertexCompensation : public VertexContext<V, E, M> {
|
|||
friend class Worker<V, E, M>;
|
||||
|
||||
public:
|
||||
virtual ~VertexCompensation() {}
|
||||
virtual void compensate(bool inLostPartition) = 0;
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue