Re: content static for 24hrs



Thanks Anthony,
That seems to be good advice.
I think I will pursue a combination of these ideas.
-improve hardware
-good asp practice
-generate html for content pages




So would flow be?-
-xxx/yyy/zzz.htm is sent to 404.asp if it doesn't exist
-404.asp extracts querystrings (does it pick up error page from http_referer
in servervariables?)
and requests data from database. if data found the html page is created
(filesystemobject)
404.asp then redirects to zzz.htm
otherwise redirects to 404.htm. (for stats)



Another issue is a requirement for a list of most popular pages, like
bbcnews for example.
Writing each hit to a database is what springs to my mind. This will surely
hurt database performance and wouldn't be possible if pages were html?
Would this be best done using the iis logging to database?

Many Thanks Soc.
"Anthony Jones" <Ant@xxxxxxxxxxxxxxxx> wrote in message
news:eSOC2g30HHA.5160@xxxxxxxxxxxxxxxxxxxxxxx
"Sean O'Connor" <zxc1@xxxxxxxxxxx> wrote in message
news:unmaTf20HHA.3536@xxxxxxxxxxxxxxxxxxxxxxx
Thank you,

20k visitors, 250k hits per day.

Largely content delivery, some of which will be subscription based. So
some
kind of session info would be required.

There are about new 200 pages per day, but the majority of these would be
unpopular, most users only visit a page or two. The new site should be
more
sticky, with usage perhaps multiplying by 2-5.

The servers are in house. The are single purpose servers.
sqlserver, w2000,sp4,pentium3,1gb ram, 2 hard drives(one for backups, 1
for
everything else)
web server, w2003,sp1,pentium3,1gb ram, 3 hard drives.

Yes I plan to parameterise using querystrings.


Would upgrading your servers and writing standard ASP be an acceptable
answer? We're looking at something like 15 requests per second here which
isn't a particularly amazing but those pentium 3 machines may struggle
(I've
never seen 2003 run on a pentium 3).

A goal to have in mind if you want to cache what is essentially static
content is to remove ASP from the majority of the requests for this
content
altogether. ASP performs poorly even if all its doing is copying bytes
from
an array or a file to the response. Making the majority of the responses
handled purely by IIS can significantly improve the performance of your
site.

The simplest is as Bob has said build the content on a scheduled basis.
The
downside to that approach is that the matrix of content you build could be
quite large and potentially much of it may not be visited at all.

Here is another option:-

Lets take an example of /MyFolder/MyPage.asp?valA=x&valB=y.

We could re-arrange the URL like this:-

/MyFolder/MyPage/x/y.htm

This page won't actually exist but /folder/MyPage.asp does.

Now we have a custom 404 handler /404.asp in the root of the site.

It takes /MyFolder/MyPage from the URL that was requested and checks that
/MyFolder/MyPage.asp exists. If not it continues with a 404 response.

If it does it simply server executes /MyFolder/MyPage.asp.

MyPage.asp needs to handle the parsing of "Querystring" values from the
rest
of the path. It can then create the x/y.htm file. It sets the
response.status back to 200 OK and then chunks the content of x/y.htm to
the
client.

Any subsequent attempts to fetch this page will find a static file and be
handled purely by IIS without any ASP/SQL Server intervention at all.

This doesn't help to protect subscribed content. This technique could be
refined and expanded to cover subscribed content by using a custom ISAPI
filter if you have that option open to you (I.e. C++).


--
Anthony Jones - MVP ASP/ASP.NET





.



Relevant Pages

  • Re: Database Interface Wizard, et. al.
    ... to set the Tools-Options-Compatibility to use ASP and to use IIS servers in ... order to allow the database functions. ... I can create an ASP page the page ...
    (microsoft.public.frontpage.client)
  • Re: Parameter passing query
    ... Definitely a bug Microsoft HTML code. ... >> I've developed a ASP page that searches a database on our web server. ... >> created a html form that passes parameters to a SQL statement on the ASP ...
    (microsoft.public.frontpage.programming)
  • Reviewing my code. Displaying a BLOB image through a browser
    ... Below you will see the error message I'm ... This is the error I get when I try to open my asp page. ... open the HTML page that uses the ASP page as a source for my image I ... I am trying to use an ASP page to grab a binary image from a database. ...
    (microsoft.public.inetserver.asp.db)
  • Re: Possible ASP - MYSQL connection problems???
    ... I encountered a similar thing when my webhotel swapped servers. ... new servers couldnt interpret includes with relative paths - ... >> I recently have switched from using an Access Database to a MYSQL ... >> database for an ASP page driven website I have developed. ...
    (microsoft.public.inetserver.asp.db)
  • Re: Another Drop List question
    ... If your database field is set to not allow zero-length strings, ... > ASP code and HTML and for me, it makes it easier to line up my quotes. ...
    (microsoft.public.inetserver.asp.general)

Loading