Question

This question talks about how you can go about storing page views, but I now have a distributed environment (multiple web servers) so the answer in that question don't seem to apply any longer.

What is the best way to capture and store page views for each page on your site in a distributed environment?

Was it helpful?

Solution

In a webfarm instead of using the default in-memory cache you could use a distributed cache such as AppFabric or memcached. Or store the results into a database.

OTHER TIPS

Consider using Ajax post call to the web server. Data can be stored in any storage device such as windows azure storage, sql azure or any database, something similar to the following:

<script>
    document.ready(function() { $ajax.post("server url")})

In server url manage to write the count entry in storage.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top