Witango-Talk: 304 last-modified

2008-08-22 Thread WebDude
Hi All,
 
I am a bit confused as to how to implement a caching scheme in which I can
show whether or not a page has been updated or not. This is for a forum that
stores the last update by date. I would like to change the response http to
show the last-modified date if possible. Unfortunately, I am a novice on
http headers and would like some help on how to implement this. If I set the
expiry to 
 
@ASSIGN Local$httpHeader VALUE=Content-Type:
text/html@CRLFCache-Control: no-cache, max-age=0, must-revalidate,proxy
revalidate@CRLFPragma: no-cache@CRLF@USERREFERENCECOOKIE@CRLF
 
Will this generat what I need for the request? I am looking for the reponse
to be something like this...
 
HTTP/1.0 200 OK
Server: Microsoft-IIS/5.0
Content-Location:  http://www.xyz.taf http://www.xyz.taf
Date: Fri, 22 Aug 2008 18:22:39 GMT
Content-Type: text/html
Accept-Ranges: bytes
Last-Modified: Wed, 020 Aug 2008 13:30:23 GMT
ETag: 801395163ec21:8a9
Content-Length: 751
 
And I am confused as to the ETag.
 
Can I set this globally for all tafs? or would that really take a
performance hit?
 
Can someone shed some light on this, please?
 
Thanks!



 


TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

Re: Witango-Talk: 304 last-modified

2008-08-22 Thread Scott Cadillac

Hey Dude,

Unfortunately HTTP caching takes a lot more consideration than just  
globally setting a custom HTTP response header.


When you set a custom header for caching purposes, this process is  
entirely dependent on receiving some specific request HTTP header  
properties (i.e., If-Modified-Since and/or If-None-Match), in order to  
conditionally set a corresponding expiry date, an ETag number and a  
304 response (for the subsequent responses), as opposed to the custom  
200 response (on the first response). And depending on the version of  
tango you are running - you may not have access to these HTTP  
properties.


In addition, HTTP caching is managed by matching the entire URL of the  
file in question, this includes the argument names and values, so if  
your GET arguments are changing, then your caching is overridden. POST  
requests generally always override cache checks as well.


And of course it should be mentioned that although browsers and  
proxies do adhere to the HTTP standards, these applications and  
devices are sometimes unpredictable as to when they implement cache  
rules.


I've built systems with HTTP caching, and I hope I can save you some  
time by giving you some advice - don't bother. The headache,  
unpredictability and limited results is usually not worth it. There'll  
be times where you can easily waste hours chasing your code in circles  
just to discover that all the bugs and weird behavior is the result of  
something happening off the server (where you have no control).


I would recommend you pursue methods for caching whatever essential  
data you need in memory on the Server to save on performance issues -  
or check out load balancing. Or possibly an appliance of some kind  
that handles the caching outside of your server.


And please note, your tango code example is for deliberately turning  
off caching.


I hope this helps, good luck.

Scott,




On Aug-22-2008, at 10:55 AM, WebDude wrote:


Hi All,

I am a bit confused as to how to implement a caching scheme in which  
I can show whether or not a page has been updated or not. This is  
for a forum that stores the last update by date. I would like to  
change the response http to show the last-modified date if possible.  
Unfortunately, I am a novice on http headers and would like some  
help on how to implement this. If I set the expiry to


@ASSIGN Local$httpHeader VALUE=Content-Type: text/html@CRLFCache- 
Control: no-cache, max-age=0, must-revalidate,proxy  
revalidate@CRLFPragma: no- 
cache@CRLF@USERREFERENCECOOKIE@CRLF


Will this generat what I need for the request? I am looking for the  
reponse to be something like this...


HTTP/1.0 200 OK
Server: Microsoft-IIS/5.0
Content-Location: http://www.xyz.taf
Date: Fri, 22 Aug 2008 18:22:39 GMT
Content-Type: text/html
Accept-Ranges: bytes
Last-Modified: Wed, 020 Aug 2008 13:30:23 GMT
ETag: 801395163ec21:8a9
Content-Length: 751

And I am confused as to the ETag.

Can I set this globally for all tafs? or would that really take a  
performance hit?


Can someone shed some light on this, please?

Thanks!




TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf


TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf



RE: Witango-Talk: 304 last-modified

2008-08-22 Thread WebDude
Thanks, Scott,

Yeah, I thought it was going to be complicated ;-/ I actually was looking at
ASP and PHP code to see if I could write something in Witango that would
kind of do the same thing.

I was looking at this from a Googlebot point of view. When Gbot comes, if
the requested page hasn't been modified since the last request it won't
crawl the page. Google recommends that you use this... 

You should configure your server to return this response (called the
If-Modified-Since HTTP header) when a page hasn't changed since the last
time the requestor asked for it. This saves you bandwidth and overhead
because your server can tell Googlebot that a page hasn't changed since the
last time it was crawled.

'Dude
 

-Original Message-
From: Scott Cadillac [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 22, 2008 9:51 AM
To: witango-talk@witango.com
Subject: Re: Witango-Talk: 304 last-modified

Hey Dude,

Unfortunately HTTP caching takes a lot more consideration than just globally
setting a custom HTTP response header.

When you set a custom header for caching purposes, this process is entirely
dependent on receiving some specific request HTTP header properties (i.e.,
If-Modified-Since and/or If-None-Match), in order to conditionally set a
corresponding expiry date, an ETag number and a
304 response (for the subsequent responses), as opposed to the custom 200
response (on the first response). And depending on the version of tango you
are running - you may not have access to these HTTP properties.

In addition, HTTP caching is managed by matching the entire URL of the file
in question, this includes the argument names and values, so if your GET
arguments are changing, then your caching is overridden. POST requests
generally always override cache checks as well.

And of course it should be mentioned that although browsers and proxies do
adhere to the HTTP standards, these applications and devices are sometimes
unpredictable as to when they implement cache rules.

I've built systems with HTTP caching, and I hope I can save you some time by
giving you some advice - don't bother. The headache, unpredictability and
limited results is usually not worth it. There'll be times where you can
easily waste hours chasing your code in circles just to discover that all
the bugs and weird behavior is the result of something happening off the
server (where you have no control).

I would recommend you pursue methods for caching whatever essential data you
need in memory on the Server to save on performance issues - or check out
load balancing. Or possibly an appliance of some kind that handles the
caching outside of your server.

And please note, your tango code example is for deliberately turning off
caching.

I hope this helps, good luck.

Scott,




On Aug-22-2008, at 10:55 AM, WebDude wrote:

 Hi All,

 I am a bit confused as to how to implement a caching scheme in which I 
 can show whether or not a page has been updated or not. This is for a 
 forum that stores the last update by date. I would like to change the 
 response http to show the last-modified date if possible.
 Unfortunately, I am a novice on http headers and would like some help 
 on how to implement this. If I set the expiry to

 @ASSIGN Local$httpHeader VALUE=Content-Type: text/html@CRLFCache-
 Control: no-cache, max-age=0, must-revalidate,proxy
 revalidate@CRLFPragma: no-
 cache@CRLF@USERREFERENCECOOKIE@CRLF

 Will this generat what I need for the request? I am looking for the 
 reponse to be something like this...

 HTTP/1.0 200 OK
 Server: Microsoft-IIS/5.0
 Content-Location: http://www.xyz.taf
 Date: Fri, 22 Aug 2008 18:22:39 GMT
 Content-Type: text/html
 Accept-Ranges: bytes
 Last-Modified: Wed, 020 Aug 2008 13:30:23 GMT
 ETag: 801395163ec21:8a9
 Content-Length: 751

 And I am confused as to the ETag.

 Can I set this globally for all tafs? or would that really take a 
 performance hit?

 Can someone shed some light on this, please?

 Thanks!



 __
 __ TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf

TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf



Witango-Talk: New project and Sick Member

2008-08-22 Thread Robert Garcia
1st, Ben Johanson has been working for me for a couple of years now,  
and he has worked with me hard on one particular project. Not related,  
but he is having some serious digestive issues and isn't doing well,  
in the ER at the moment, so if you know him, you may want to wish him  
well. I am sure he would appreciate it.


BigHead's last major witango site, and by far biggest work in terms of  
scope and use is peachdirect.com.


http://www.peachdirect.com/

This system was not only a very sophisticated ecommerce site,  
basically a mini bestbuy type site, but also we wrote the entire  
backend, including all vendor fullfillment, vendor communication, and  
since this is a private credit card site, we wrote all of the  
communication modules custom for communicating to the bank. Its a very  
large system.


The site was written in witango, and then uses other languages, mainly  
realbasic to deal with the bank com and the vendor system and such.  
The peachdirect site is almost dormant now, but at its peak was doing  
over $20 million per month in orders. At its peak, witango could  
barely take it, we had lots of workarounds, and even wrote our own  
page caching system in witango to help with the load. Originally,  
several years ago, the witango site was only supposed to be up for a  
few months, until they went to a bigger system.


Well, the company has completely changed their name and launched a new  
site/system and are planning the $20 million/month level in just a  
couple of months. This time, we wrote the ENTIRE system in PHP and it  
is running on the Zend Platform. We have already ported large sites  
over from witango to php, but this was a monster. The interesting part  
is that every line of code is written in PHP. There is no perl,  
realbasic, java, nothing. Not only that, we are using standard PHP  
5.1.6 from CentOS 5.2 distribution, with yum installable modules, like  
php-gd, php-xml, php-soap, etc. No pear, no roll your own stuff at  
all. We have used a couple of classes to generate excel files, and  
things like that, other than that, its all standard php, with the  
addition of some features like partial page caching from the Zend  
Platform.


In this huge project, I don't think we have run into ONE php bug. I  
can't think of a time we had to rewrite code, or create an external  
object to make up for a php bug or deficiency. Even all of the  
realbasic code that handled the bank and vendor communication is  
written in PHP, some scripts being run from command line via cron and  
such.


Anyway, I am not trying to sell php, I have no gain there, but as a  
developer I am amazed. To make the statement that we have not had one  
workaround, is amazing. XML just works, soap just works. The soap  
client is amazing, just give it a wsdl and call your method, like 3  
lines of code. Many have contacted me if possible to port big projects  
over, yes it is.


Anyway, just thought I would share, don't forget to shoot ben a line  
if you know him.


Link to new site:

http://www.venue.com/

--

Robert Garcia
President - BigHead Technology
VP Application Development - eventpix.com
13653 West Park Dr
Magalia, Ca 95954
ph: 530.645.4040 x222 fax: 530.645.4040
[EMAIL PROTECTED] - [EMAIL PROTECTED]
http://bighead.net/ - http://eventpix.com/

TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf



RE: Witango-Talk: New project and Sick Member

2008-08-22 Thread Tom Ferguson
Robert,

Thanks for the heads up on Ben.  Although I've never met Ben in person, Ben
has always been a help to me with Tango and Witango over the years.

I've sent him a brief note.  Hope all is well with him.

Tom Ferguson 

 -Original Message-
 From: Robert Garcia [mailto:[EMAIL PROTECTED] 
 Sent: Friday, August 22, 2008 08:41
 To: witango-talk@witango.com
 Subject: Witango-Talk: New project and Sick Member
 
 1st, Ben Johanson has been working for me for a couple of 
 years now, and he has worked with me hard on one particular 
 project. Not related, but he is having some serious digestive 
 issues and isn't doing well, in the ER at the moment, so if 
 you know him, you may want to wish him well. I am sure he 
 would appreciate it.
 
 BigHead's last major witango site, and by far biggest work in 
 terms of scope and use is peachdirect.com.
 
 http://www.peachdirect.com/
 
 This system was not only a very sophisticated ecommerce site, 
 basically a mini bestbuy type site, but also we wrote the 
 entire backend, including all vendor fullfillment, vendor 
 communication, and since this is a private credit card site, 
 we wrote all of the communication modules custom for 
 communicating to the bank. Its a very large system.
 
 The site was written in witango, and then uses other 
 languages, mainly realbasic to deal with the bank com and the 
 vendor system and such.  
 The peachdirect site is almost dormant now, but at its peak 
 was doing over $20 million per month in orders. At its peak, 
 witango could barely take it, we had lots of workarounds, and 
 even wrote our own page caching system in witango to help 
 with the load. Originally, several years ago, the witango 
 site was only supposed to be up for a few months, until they 
 went to a bigger system.
 
 Well, the company has completely changed their name and 
 launched a new site/system and are planning the $20 
 million/month level in just a couple of months. This time, we 
 wrote the ENTIRE system in PHP and it is running on the Zend 
 Platform. We have already ported large sites over from 
 witango to php, but this was a monster. The interesting part 
 is that every line of code is written in PHP. There is no 
 perl, realbasic, java, nothing. Not only that, we are using 
 standard PHP
 5.1.6 from CentOS 5.2 distribution, with yum installable 
 modules, like php-gd, php-xml, php-soap, etc. No pear, no 
 roll your own stuff at all. We have used a couple of classes 
 to generate excel files, and things like that, other than 
 that, its all standard php, with the addition of some 
 features like partial page caching from the Zend Platform.
 
 In this huge project, I don't think we have run into ONE php 
 bug. I can't think of a time we had to rewrite code, or 
 create an external object to make up for a php bug or 
 deficiency. Even all of the realbasic code that handled the 
 bank and vendor communication is written in PHP, some scripts 
 being run from command line via cron and such.
 
 Anyway, I am not trying to sell php, I have no gain there, 
 but as a developer I am amazed. To make the statement that we 
 have not had one workaround, is amazing. XML just works, soap 
 just works. The soap client is amazing, just give it a wsdl 
 and call your method, like 3 lines of code. Many have 
 contacted me if possible to port big projects over, yes it is.
 
 Anyway, just thought I would share, don't forget to shoot ben 
 a line if you know him.
 
 Link to new site:
 
 http://www.venue.com/
 
 -- 
 
 Robert Garcia
 President - BigHead Technology
 VP Application Development - eventpix.com
 13653 West Park Dr
 Magalia, Ca 95954
 ph: 530.645.4040 x222 fax: 530.645.4040
 [EMAIL PROTECTED] - [EMAIL PROTECTED] 
 http://bighead.net/ - http://eventpix.com/ 
 __
 __
 TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
 

TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf