r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[!Cheyenne] Discussions about the Cheyenne Web Server

Graham
18-Aug-2009
[5417]
Sometimes I think that Chyenne is disrupting the fabric of reality. 
 I can comment out lines of code, and they still execute ... for 
a while and then they stop.  As though somewhere code is being cached 
somehow.
Robert
18-Aug-2009
[5418]
Can you all please "document" those finding in the Cheyenne Wiki? 
This should build a collection of tipps & tricks over time.
Dockimbel
18-Aug-2009
[5419]
Graham: the sample code above is a way of caching code in memory. 
It won't change unless you restart the process.
Graham
18-Aug-2009
[5420]
I'm not doing that for this particular problematic code .. it's just 
being executed off the drive
Dockimbel
18-Aug-2009
[5421x2]
Btw, running Cheyenne with the -w 0 option is a good way to avoid 
code caching effects.
(for debugging only)
Robert
18-Aug-2009
[5423x5]
I have a strange error message I don't have a clue where it is coming 
from.
10/7-15:13:14.250992-[RSP] ##RSP Script Error:                   
                                                                 
                    
                                            
                                                                 
                                         
        URL  = yogalinks.rsp?rest=addtocart 
                                                                 
                                         
        File = /var/www/cheyenne/yogalinks.rsp 
                                                                 
                                      
                          
                                                                 
                                                           
     
   ** Script Error : Invalid argument: o                         
                                                                 
               
        ** Where: to-integer                     
                                                                 
                                    
        ** Near:  [to integer! 
:value]                                                          
                                                      
          
                                                                 
                                                                 
          
                                                      
                                                                 
                               
Request  = make object! [        
                                                                 
                                                    
    headers: 
[Host "www.yogalinks.eu" User-Agent {Mozilla/5.0 (Macintosh; U; Intel 
Mac OS X 10_5_7; de-de) AppleWebKit/525.28.3 (KHTML, like Gecko) 
Ve
    status-line: #{                                           
                                                                 
                       
504F535420796F67616C696E6B732E7273703F726573743D616464746F636172 
                                                                 
                    
7420485454502F312E300D0A                    
                                                                 
                                         
}                      
                                                                 
                                                              
  
  method: 'POST                                                  
                                                                 
                  
    url: "yogalinks.rsp?rest=addtocart"       
                                                                 
                                       
    content: #{          
                                                                 
                                                            
70726F647563745F69643D596F67616D617425323045636F25323050726F2671 
                                                                 
                    
75616E746974793D6F26636F6C6F723D626F72646561757825324667726175 
                                                                 
                      
}                                         
                                                                 
                                           
    path: "/"        
                                                                 
                                                                
 
   target: "yogalinks.rsp"                                       
                                                                 
                   
    arg: "rest=addtocart"                    
                                                                 
                                        
    ext: '.rsp          
                                                                 
                                                             
   
 version: none                                                   
                                                                 
                 
    file: %/var/www/cheyenne/yogalinks.rsp     
                                                                 
                                      
    script-name: none     
                                                                 
                                                           
]
From trace.log
It seems cheyenne got somehow stucked after a longer running period. 
Restarting did solve the problem.
Could be something where sessions/ session variables are not reset 
in all cases.
Graham
18-Aug-2009
[5428]
why is cheyenne inside your www directory?
Dockimbel
18-Aug-2009
[5429x2]
About your error, it's caused by an invalid argument passed in POST 
data : quantity=o (o instead of 0). Are you validating parameters 
sent by client using RSP 'validate function or your own one?
Somehow stucked

: I need more details to give you a diagnosis (Does the server respond 
to static requests? Does it generates any useful info in logs files,...). 
I have several Cheyenne instances with heavy RSP webapps running 
for months without any need for restarting.
Will
18-Aug-2009
[5431]
Cheyenne is very powerful and very stable. It is also very sensible, 
so you have to take care much of what you do, I have also many instances 
serving millions hits per month, no problem at all 8)
Dockimbel
18-Aug-2009
[5432x2]
RSP scripts requires carefull coding pratices, that's the (small) 
price to pay for performances. That's why user feedback is important, 
to be able to improve RSP engine resistance to user's (sometimes 
bad) practices.
Good documentation would be also a good help, I'm not a great documentation 
writer, but gathering the hints, tips and info from here to fill 
the wiki is the way to go.
Henrik
18-Aug-2009
[5434]
how is the web based configuration page going?
Dockimbel
18-Aug-2009
[5435]
No progress since a year at least, due to other priorities. But I 
still plan to make one before the end of this year.
Henrik
18-Aug-2009
[5436]
alright. will attempt to upgrade to the latest cheyenne soon, so 
I can get back to some much needed web work.
Graham
18-Aug-2009
[5437x2]
Henrik ....it's just a svn checkout.  takes a few mins.
doc "improve RSP engine resistance to user's (sometimes bad) practices." 
... I think that means me!
Henrik
18-Aug-2009
[5439x2]
hmm.. is there an easy way to check which version I'm running, for 
example through RSP?
figured it out, however it would be nice to see which one it is.
Graham
18-Aug-2009
[5441x3]
How ?
Doc has a web control panel on the back burner ... so maybe that 
information will be there.
I've updated my cheyenne.exe binary to use my prot-http.r so that 
you can do PUT, DELETE, GET with read/custom etc.
Dockimbel
18-Aug-2009
[5444x2]
Graham, not only you, but that's a good thing. :-) Cheyenne would 
have never become as solid as it is today without your and others 
help.
Henrik: on Windows, you have a help message when the mouse pointer 
is over Cheyenne's tray icon. From RSP script, just use :

>> p: open http://localhost
>> p/locals/headers/server
== "Cheyenne/0.9.20"
Henrik
18-Aug-2009
[5446]
ok, thanks
Graham
18-Aug-2009
[5447]
Will, are you familiar with how to use Cheyenne's logging functions 
from within a rsp script?
Will
18-Aug-2009
[5448]
not sure what you mean, rsp-log which is deprecated in latest version?
Graham
18-Aug-2009
[5449x6]
found it .. can use ?? to log to the trace.log
This is really really strange.
I have a rsp page called creategoogledoc.rsp ... I click on it once, 
and the I get my document created.

Click on it again and the rsp script is not executed ( looking from 
the trace ) but I still get taken to the googledoc page where I previousl 
y created the document.

It's as though the browser is caching my request and executing it 
locally without hitting the server
Arrrggg.... it's all caused by Chrome.  Switching to FF and the problem 
goes away!
And here I was looking for  some type of caching occuring in Cheyenne 
or my RSP pages
I wonder if there is anything on the cheyenne side that can stop 
this behaviour?
Will
18-Aug-2009
[5455]
rsp pages should not be cached by default by any browser. Do you 
have firebug in FF can you look at the header fo the response an 
see if there is any difference between the two requests? wireshark 
or tcpflow can be used to look at headers as well
amacleod
19-Aug-2009
[5456]
I was having similar cashing problems with Chrome...I could not getr 
it to display a changed/updated rsp page. I had to close out.
Graham
19-Aug-2009
[5457x2]
interesting
If this only occurs with Chrome and RSP ... maybe there is something 
that can be done.
Sunanda
19-Aug-2009
[5459]
Google Chrome has some badly broken logic when it comes to obeying 
cache-control headers.
Graham
19-Aug-2009
[5460]
Got a link to this ?
Sunanda
19-Aug-2009
[5461]
Here's someone else banging their head against chrome's caching logic:

http://stackoverflow.com/questions/559984/getting-confused-about-expires-headers-when-testing-in-chrome
Graham
19-Aug-2009
[5462x2]
That appears to be saying that Chrome is not caching ....
here the problem appears to be that Chrome is heavily caching.
Sunanda
19-Aug-2009
[5464]
Lots of other people seeing overheavy  Chrome caching, eg:

http://www.google.com/support/forum/p/Chrome/thread?tid=77a9194da602bc00&hl=en
Graham
19-Aug-2009
[5465x2]
I've created a youtube video showing what is happening http://www.youtube.com/watch?v=ANgSrOuDncE
I'm using BB FlashBack Express 2 because it can upload directly to 
youtube ..and it seems to be free :)