Michael, that will fit perfect disconsidering the fact that this user
can receive external points from other signals (ie someone else liking
your message) :(

On Aug 21, 7:14 pm, Michael W <[email protected]> wrote:
> Why can't you track this on the client side?
>
> - Have the server side calculate points when it detects that their
>   connection drops
>
> - Each client additionally runs a 1-second timer that updates the point
>   display without hitting the server, understanding that the server has
>   final say in how many points the account has.
>
>
>
>
>
>
>
> On Tue, 21 Aug 2012 14:55:01 -0700 (PDT), Filipe <[email protected]> wrote:
> > Douglas, yes, time is one of the score signals (the main one).
>
> > Anyway, I can't picture how can I make this sync on client side
> > without always hitting DB to check how many point do user have in that
> > specific interaction/time.
>
> > For exemple, these interactions:
>
> > 1) Initial points 100 (client side: 100 points)
> > 2) 1 second passes: +1 point (client side: 101 points)
> > 3) 1 second passes: +1 point (client side: 102 points)
> > 4) Friend like my message AND 1 second passes: +1 +1 points (client
> > side: 104 points)
>
> > Hitting DB
> > 1) 1 hit -> emit('points')
> > 2) 1 hit -> emit('points')
> > 3) 1 hit -> emit('points')
> > 4) 2 hits -> emit('points') x 2
>
> > Is this correct?
>
> > On Aug 21, 3:17 pm, "P. Douglas Reeder" <[email protected]> wrote:
> > > It sounds like you have a score, rather than strictly time connected. 
> > > That's an aggregate, so using Mongo's map-reduce should adapt to 
> > > different ways of measuring time connected (if you find your current 
> > > measurement takes too many resources). It should also be efficient, since 
> > > only changed factors are recomputed.
>
> > --
> > Job Board:http://jobs.nodejs.org/
> > Posting 
> > guidelines:https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
> > You received this message because you are subscribed to the Google
> > Groups "nodejs" group.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]
> > For more options, visit this group at
> >http://groups.google.com/group/nodejs?hl=en?hl=en

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to