Calculating Bandwidth

G

Guest

I need to calcuate (and save) the amount of Bandwidth used by each of my
customers. Any help/ideas would be appreciated(?)

I have a website that is using Forms Authentication. Each customer is
authenticated against a "Customers" table in a SQL server database. I was
thinking about creating another table ("CustomerUsage" and stored procedures
to insert/update) that would accumulate the number of bytes sent by IIS for
each page (for each customer - and a DateTime field so I could see daily
usage).

Here's how I think it could work: At the end of each Page_Load() event, I
could calcuate the total number of bytes the Response object is about to send
(Page.Response.OutputStream.Length). I could then accumulate this data for
each customer.

Will this approach work? Is there a better way to do what I want in a
shared hosting environment?

Thanks.
 
S

S. Justin Gengo [MCP]

Donald,

Just a thought, but don't you already have that in your logs? Although I
suppose that users who are going through a proxy may all appear as the same
user...

--
Sincerely,

S. Justin Gengo, MCP
Web Developer / Programmer

www.aboutfortunate.com

"Out of chaos comes order."
Nietzsche
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top