Use activity.replyToId as a hint for sorting #2991
Labels
backlog
Out of scope for the current iteration but it will be evaluated in a future release.
feature-request
Azure report label
Feature Request
In addition of using
activity.timestamp
, we could also useactivity.replyToId
.But also note that
activity.id
andactivity.replyToId
could beundefined
/null
.Additional Context
This is not trivial to solve due to Direct Line protocol issue that is out of our control.
timestamp
andreplyToId
Currently, we are sorting based on
timestamp
. For incoming activities, we receive thistimestamp
field. For outgoing activities, we receive thistimestamp
field after the server successfully sent the activity. This also means, after the bot completely processed the activity.As the system is distributed, outgoing activities may not receive "server-blessed"
timestamp
before the bot response. Thus, Web Chat need to use local clock fortimestamp
before receiving server-blessing.We know there may be clock skew (especially when client set to wrong time zone).
Thus, in our previous PR, we attempted to measure/correct the clock skew between client and server. But it's not perfect since there could be milliseconds differences (bigger on mobile devices), user may see jitter of messages as recorded by @Slayouth.
Emulator works because the
timestamp
field is always local clock.[Enhancement]
The text was updated successfully, but these errors were encountered: