corrected prev patch on ndb_mgmd usage of SignalSender

parent a830ed3c
......@@ -1227,9 +1227,7 @@ MgmtSrvr::setEventReportingLevelImpl(int nodeId,
EventSubscribeReq::SignalLength);
*dst = ll;
if (ss.sendSignal(nodeId, &ssig) != SEND_OK) {
return SEND_OR_RECEIVE_FAILED;
}
send(ss,ssig,nodeId,NODE_TYPE_DB);
#if 0
while (1)
......@@ -1283,6 +1281,19 @@ MgmtSrvr::setNodeLogLevelImpl(int nodeId, const SetLogLevelOrd & ll)
return ss.sendSignal(nodeId, &ssig) == SEND_OK ? 0 : SEND_OR_RECEIVE_FAILED;
}
int
MgmtSrvr::send(SignalSender &ss, SimpleSignal &ssig, Uint32 node, Uint32 node_type){
Uint32 max = (node == 0) ? MAX_NODES : node + 1;
for(; node < max; node++){
while(nodeTypes[node] != (int)node_type && node < max) node++;
if(nodeTypes[node] != (int)node_type)
break;
ss.sendSignal(node, &ssig);
}
return 0;
}
//****************************************************************************
//****************************************************************************
......
......@@ -31,6 +31,8 @@
#include <EventLogger.hpp>
#include <signaldata/EventSubscribeReq.hpp>
#include <SignalSender.hpp>
/**
* @desc Block number for Management server.
* @todo This should probably be somewhere else. I don't know where atm.
......@@ -496,8 +498,7 @@ public:
private:
//**************************************************************************
int setEventReportingLevel(int processId, LogLevel::EventCategory, Uint32);
void set_common_stop_req_params(void *stopReq);
int send(SignalSender &ss, SimpleSignal &ssig, Uint32 node, Uint32 node_type);
int sendSTOP_REQ(NodeId nodeId,
NodeBitmask &stoppedNodes,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment