5

Scenario is a grid with a list of contacts. User clicks on 'send email' from grid, sends an email. We drop a message in a queue to update some aggregates (which are also displayed on the list).

The problems is after sending the email, the aggregates are not guaranteed to be updated yet.

We could update the count with javascript, but what if they refresh the page and the aggregates have not yet completed?

Tom DeMille
  • 3,207
  • 3
  • 23
  • 30
  • @jlafay: "Use while. The whilst form faintly survives in Commonwealth English, but is effectively extinct in the Western Hemisphere, and there is no context for whilst in which while cannot be used, regardless of English language variant." as well as http://en.wikipedia.org/wiki/Whilst#While_and_Whilst – jason Jan 20 '11 at 18:30
  • 1
    I'm reading the Baroque Cycle by Neil Stephenson and olde English has crepteth into myne vocabulary – Tom DeMille Jan 20 '11 at 18:35
  • The first volume (Quicksilver) is incredible, Incredible, INCREDIBLE. That's not to say the other volumes aren't great, they are, just the first is wow. Outstanding choice, sir. – jason Jan 20 '11 at 18:41
  • @Jason: Could not agree more... Digressing from the point of this question a bit but man... one of the best books I have ever read, absolutely genious and incredible as you say – Tom DeMille Jan 20 '11 at 19:47

1 Answers1

1

One approach would be to keep track of the data in a cookie. On a refresh (i.e., page load) you can check for the existence of the cookie and read (and display) its value via JavaScript. The process that updates the aggregates could also read the cookie and update it, if necessary, to ensure the values are in sync once the updates are complete.

Chocula
  • 1,946
  • 1
  • 16
  • 21