re-enabled previously disabled code in rsgxsnetservice, that proved useful

This commit is contained in:
Cyril Soler 2016-01-06 10:31:59 -05:00
parent 6398b7b9d6
commit 7da2ad14ec
2 changed files with 3 additions and 7 deletions

View File

@ -2739,18 +2739,17 @@ void RsGxsNetService::locked_genReqMsgTransaction(NxsTransaction* tr)
#ifdef NXS_NET_DEBUG_1
GXSNETDEBUG_PG(item->PeerId(),grpId) << " Request list is empty. Not doing anything. " << std::endl;
#endif
#ifdef SUSPENDED
// The list to req is empty. That means we already have all messages that this peer can
// provide. So we can stamp the group from this peer to be up to date.
// Normally, this is not needed, since the time stamp is updated when receiving messages, not message ids
// Part of this is already achieved in two other places:
// - the GroupStats exchange system, which counts the messages at each peer. It could also supply TS for the messages, but it does not for the time being
// - client TS are updated when receiving messages
locked_stampPeerGroupUpdateTime(pid,grpId,tr->mTransaction->updateTS,msgItemL.size()) ;
#endif
}
}
#ifdef SUSPENDED
void RsGxsNetService::locked_stampPeerGroupUpdateTime(const RsPeerId& pid,const RsGxsGroupId& grpId,time_t tm,uint32_t n_messages)
{
std::map<RsPeerId,RsGxsMsgUpdateItem*>::iterator it = mClientMsgUpdateMap.find(pid) ;
@ -2772,7 +2771,6 @@ void RsGxsNetService::locked_stampPeerGroupUpdateTime(const RsPeerId& pid,const
IndicateConfigChanged();
}
#endif
void RsGxsNetService::locked_pushGrpTransactionFromList( std::list<RsNxsItem*>& reqList, const RsPeerId& peerId, const uint32_t& transN)
{

View File

@ -442,13 +442,11 @@ private:
*/
void collateGrpFragments(GrpFragments fragments, std::map<RsGxsGroupId, GrpFragments>& partFragments) const;
#ifdef SUSPENDED
/*!
* stamp the group info from that particular peer at the given time.
*/
void locked_stampPeerGroupUpdateTime(const RsPeerId& pid,const RsGxsGroupId& grpId,time_t tm,uint32_t n_messages) ;
#endif
void cleanRejectedMessages();
void processObserverNotifications();