Project

General

Profile

Bug #5122

In partial-sync consumer gets only those updates that are published after it came online or have just subscribed.

Added by Saurab Dulal 8 months ago. Updated 7 months ago.

Status:
Closed
Priority:
Normal
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:

Description

If not for some specific design or security issues, the consumer should get all the updates that were published before its subscription.


Files

Screen Shot 2020-07-03 at 1.31.50 PM.png (321 KB) Screen Shot 2020-07-03 at 1.31.50 PM.png Saurab Dulal, 07/03/2020 12:05 PM
Screen Shot 2020-07-03 at 2.43.28 PM.png (858 KB) Screen Shot 2020-07-03 at 2.43.28 PM.png psync and app log Saurab Dulal, 07/03/2020 12:50 PM
#2

Updated by Ashlesh Gawande 8 months ago

  • Tracker changed from Task to Bug
  • Assignee set to Ashlesh Gawande
  • Target version set to v0.3.0
  • Start date deleted (07/03/2020)

How Consumer::HelloData works:

 for /prefix/seq in in helloData:
    if subscribed to prefix and behind on sequence number:
        add to updates
    add /prefix/seq to available subscriptions

 tell application about available subscriptions [onHelloData callback]
 tell application about updates [onSyncData callback]

This is so that app when app renews hello interest, Consumer can tell the app only if it has missed some updates while sleeping.
But what is happening here is that Consumer receives the /prefix/seq as part of first hello data and then the app subscribes to it. So consumer has received hello data with the most up to date sequence number correctly. But there is no callback to the app because it was not subscribed to it.
And when the app does call addSubscription, the Consumer class inserts the prefix with a sequence number of zero and not the original sequence number that was received in HelloData. Seems like we would have to modify onHelloData callback to add the sequence number so that app knows about this latest sequence number and can give it to addSubscription.

#3

Updated by Ashlesh Gawande 8 months ago

  • Status changed from New to In Progress
  • % Done changed from 0 to 90
#4

Updated by Ashlesh Gawande 8 months ago

  • Status changed from In Progress to Code review
  • % Done changed from 90 to 100

HelloData cb is changed to return a prefix->seqNo map instead of list of prefixes.

#5

Updated by Ashlesh Gawande 7 months ago

  • Status changed from Code review to Closed

Also available in: Atom PDF