Esempio n. 1
0
void BlockManagerMaster::BlockManagerMasterActor::matcherReceiver(const MatcherMessage &message,const Theron::Address from){
	cout<<"I want the proj "<<from.AsString()<<" shows:"<<message.filenameText<<" from "<<message.bmiText<<endl;
	BlockManagerId *bmi=new BlockManagerId(message.bmiText);
	BlanceMatcher *bm=BlanceMatcher::getInstance();
	string res=bm->matcher(message.filenameText,*bmi);
	MatcherRespond resp(res.c_str());
	cout<<"I will send the proj "<<res.c_str()<<" to "<<from.AsString()<<endl;
	Send(resp,from);
}
Esempio n. 2
0
void BlockManagerMaster::BlockManagerMasterActor::workerRegister(const StorageBudgetMessage &message,const Theron::Address from){
	// 加到blockInfo中
	cout<<"I receive message: nodeid"<<message.nodeid<<" and other information "<<from.AsString()<<endl;
	string respond="ok";
	RegisterStorageRespond rsr(respond.c_str());
	Send(rsr,from);
}
Esempio n. 3
0
void BlockManagerMaster::BlockManagerMasterActor::blockStatusReceiver(const BlockStatusMessage &message,const Theron::Address from){
	cout<<"receive a block "<<from.AsString()<<" shows:"<<message.mText<<endl;
	AllBlockInfo *abi=AllBlockInfo::getInstance();
	abi->put(from.AsString(),message.mText);
}
Esempio n. 4
0
void BlockManagerMaster::BlockManagerMasterActor::heartbeatReceiver(const HeartBeatMessage &message,const Theron::Address from){
	cout<<"receive heartbeat from node "<<from.AsString()<<" shows:"<<message.mText<<endl;
	string respond="ok";
	HeartBeatRespond hbr(respond.c_str());
	Send(hbr,from);
}