Re: Optimal counter implementation?

2011-05-12 Thread Zachary Zolton
So, you could increment a counter—using whatever datastore seems appropriate to you—and then also store a log document in a CouchDB database for future analysis. As long as you don't depend on reading from that log database for any of the website's functionality, that may mitigate concerns for hav

Re: Optimal counter implementation?

2011-05-11 Thread He Shiming
On Wed, May 11, 2011 at 11:12 PM, Zachary Zolton wrote: > As long as your considering using another datastore, you should consider > Redis. > > If you're just maintaining count statistics: > http://redis.io/commands/incr > Thanks. I'm considering CouchDB because I'm familiar with the document/ma

Re: Optimal counter implementation?

2011-05-11 Thread Zachary Zolton
As long as your considering using another datastore, you should consider Redis. If you're just maintaining count statistics: http://redis.io/commands/incr On Wed, May 11, 2011 at 9:42 AM, He Shiming wrote: > > On Tue, May 10, 2011 at 10:00 PM, Olafur Arason wrote: > > If you know erlang I would

Re: Optimal counter implementation?

2011-05-11 Thread He Shiming
On Tue, May 10, 2011 at 10:00 PM, Olafur Arason wrote: > If you know erlang I would advise you to extend _stats, it would > give you the best performance. > http://wiki.apache.org/couchdb/Runtime_Statistics > > There is also some work in doing visualization to it: > https://github.com/mcaprari/cou

Re: Optimal counter implementation?

2011-05-10 Thread Olafur Arason
If you know erlang I would advise you to extend _stats, it would give you the best performance. http://wiki.apache.org/couchdb/Runtime_Statistics There is also some work in doing visualization to it: https://github.com/mcaprari/couchdb-stats If you want to go the javascript route I would advice y

Re: Optimal counter implementation?

2011-05-10 Thread Fabio Batalha Cunha dos Santos
Hello, I tryed it before but didn't go ahead with the idea. I was creating each document for each access, and put inside the document a lot of info related to the request. In my opinion all depends on the among of access you cite receive, but I'm sure it isn't a sustainable way to store access h

Optimal counter implementation?

2011-05-10 Thread He Shiming
Hi, I'm working on this project, that needs to count page views. I came up with two possible solutions: 1. For each page to be counted, use a single count document, and an update handler to count on each page view 2. Create a new document on each page view, this way I get to record a history of v