World: r3wp
[!Cheyenne] Discussions about the Cheyenne Web Server
older newer | first last |
Dockimbel 31-Jan-2009 [3786x5] | I'm working on it today, I'll release a beta version in a couple of hours. Lot of fixes and improvements in this release. |
New Cheyenne 0.9.19 beta version available for testing at : http://cheyenne-server.org/tmp/cheyenne-r0919.zip Tested only on Windows (my Linux image network has currently some issues). ChangeLog (diff-ed from last test version) : o RSP: an HTTP redirection in 'on-page-start won't evaluate the page script anymore. o CGI: mezz function READ-CGI now patched to be compatible with Cheyenne. That's the right way of reading POST data in REBOL CGI scripts. o RSP: fixed a bug in session/add when setting a block! value. o Task-handler: fixed a network error on first packet read (high load + fast hardware). o Task-handler: TCP keepalive mode activated (test workaround half-closed connections). o Task-master: o 'no-delay mode removed and replaced by 'keep-alive mode o now forks a new process as soon as one dies (not waiting for a new request) o fix a long standing bug in queued job module name mismatching (can happen under extreme load) o minor code cleanup o Uniserve: 'no-delay TCP network mode now switched off for all connections. Fixes a stability issue on Vista and probably on UNIX with very high load. o RSP: fix a bug in 'decode-multipart when there's no file received. o UniServe: new logger service. Now all info or error logs, and debug messages from CGI/RSP scripts are written in %trace.log. Additionnaly, you can now log messages using : - debug/print msg ; msg [string!] - debug/probe value ; any mold-able value - ?? word ; works like REBOL's '?? function - ? msg ; alias for debug/print o RSP: in debug mode, page generation time and SQL queries stats now added at bottom of pages. o RSP: error in events from %app-init.r now logged. o RSP: fix a rare RSP freezing issue when an error occurs in %RSP.r (for example, by a user script that breaks RSP sandbox). o RSP: sanboxing now protects from Exit/Return/Break calls made outside of a function context. o RSP: %misc/rsp-init.r file removed. o RSP/CGI: New config keyword added in global sections : 'worker-libs. It lists the librairies to load when a worker process is started. An optional 'on-quit section can be added to call cleanup code when the process quits. Examples : worker-libs [ %libs/mysql-protocols.r ... ] or worker-libs [ %libs/mysql-protocols.r ... on-quit [ %/libs/free-resources.r ] ] o Task-master: now you can reset all worker processes without stopping Cheyenne. This is usefull when you need to force non-RSP/CGI files reload (helper scripts, 3rd party librairies,...). Usage: Windows : tray icon -> Reset Workers UNIX : kill -s USR1 <pid> (<pid> is Cheyenne's main process ID) o Added a -w command line option to set the worker processes number. Usage: $ cheyenne -w <n> (n [integer!] : CGI/RSP process number) Use -w 0 to help debug CGI/RSP code by resetting worker processes after each request. (it's like calling "Reset workers" after each request). | |
Complete changelog is available in %Cheyenne/Changelog.txt. | |
Command line option -debug has been replaced by -w 0 | |
I'll release Windows and Linux test binaries tomorrow. | |
[unknown: 5] 31-Jan-2009 [3791] | How is fast-cgi implemented via Cheyenne? |
Janko 31-Jan-2009 [3792x2] | Great Doc! I am really becoming a fan of cheyenne + rebol for webapps.. I have 2 half working in the garage already :) |
(and I used a lot of stuff and been developing webapps for >4 years for $$) | |
Henrik 31-Jan-2009 [3794] | Looking forward to get back to Cheyenne/RSP too. Keep up the good work, DocKimbel. |
Maarten 31-Jan-2009 [3795] | Thank you! |
Dockimbel 31-Jan-2009 [3796x2] | Thanks guys for your kind support! |
Paul: FastCGI is implemented at low-level as an UniServe client protocol. It should be able to communicate with any FastCGI server like PHP. | |
[unknown: 5] 31-Jan-2009 [3798] | Thanks Doc. |
Dockimbel 1-Feb-2009 [3799] | FYI : the new "Reset Workers" feature is not working well on UNIX, I'm working on it to fix it. |
Dockimbel 2-Feb-2009 [3800] | Cheyenne new test release delayed until tomorrow. Almost a dozen of fixes and useful improvements were added, mostly by Will (many thanks to him). So a little more time is required to run non-regression tests. |
Dockimbel 3-Feb-2009 [3801x5] | New Cheyenne test release 0.9.19 available. Please report any bug or regresson here. Changelog (diff from previous one) : o RSP: fixed a security issue allowing access to /webapp/private/ sub-folders content. o RSP/CGI: fix for HTTP 'Date header not being returned in some cases.(Will) o RSP Sessions: fixed an issue with init flag when saving sessions on disk.(Will) o RSP: now you can declare folders as valid login URL.(Will) Ex: auth "/admin/login/" o RSP: a new session word 'from has been added. It's set to the referring URL on login. After login, you can now redirect to the referring page (in case of session timeouts for example).(Will) o RSP: a webapp can now be called without the ending slash.(Will) o RSP: the root "/" webapp can now be declared (needs testing).(Will) o RSP: new 'SID-domain config keyword added allowing to share sessions between sub-domains.(Will) o RSP: now session ID can be passed as URL or POST data in addition to cookie.(Will) o New 'charset config keyword added. It allows to define specific charset sent through HTTP headers for 'text/htlm resources.(Will) o RSP: Added a new function no-log in Response object. Use it to avoid writing log info to disk for the current request.(Will) Ex: response/no-log o New 'mod-expire module for HTTPd. Allow configuring 'Expires HTTP header. See %Cheyenne/mods/mod-expire.r for more info.(Will) |
Download links : - sources: : http://cheyenne-server.org/tmp/cheyenne-r0919.zip - Windows test binary : http://cheyenne-server.org/tmp/cheyenne.zip - Linux test binary : http://cheyenne-server.org/tmp/cheyenne.gz | |
Btw, the "Reset Workers" issue on UNIX has been solved in this release. | |
I've been asked to publish some stats for Cheyenne downloads, here they are (stats since 18 months) : Source downloads : 978 Binaries downloads : 2372 - Windows: 926 (39%) - Linux : 867 (37%) - OS X : 579 (24%) | |
Btw, here's some stats for cheyenne-server.org web site (online since jun-2008) : Total page viewed : 48224 - Static pages : 9824 - Blog : 19179 - Wiki : 19221 | |
Robert 4-Feb-2009 [3806] | Doc, can RSP be used with other web-servers as well? I use lighttpd at the moment and would like to avoid changing my configuration on my production system. |
Will 4-Feb-2009 [3807] | Robert, one thing you can do for sure is reverse proxy rsp to cheyenne and serve static from lighthttpd 8) |
Maarten 4-Feb-2009 [3808] | Robert, write a few helper functions and use http://www.ross-gill.com/techniques/rsp/ |
Will 4-Feb-2009 [3809] | that way you have overhead of launching/closing a process for every request |
Robert 4-Feb-2009 [3810] | Maarten, thx. Didn't remember this one. Will, well Rebol core is fast and it would be OK in the first place. |
Maarten 4-Feb-2009 [3811] | My code is scattered everywhere... it's a Darwinistic tactic |
Oldes 4-Feb-2009 [3812] | I'm using Cheyenne with Apache using the reverse proxy. Don't know it it's possible with lighthttpd. Let us know:) |
Dockimbel 4-Feb-2009 [3813] | Cheyenne's RSP with other web server : no. The reverse proxy technique works well. |
Robert 5-Feb-2009 [3814] | Maarten, does your RSP version support things like session handling etc.? Is it updated to keep track with Cheyenne's version? |
Maarten 5-Feb-2009 [3815] | Of course not :-) |
Will 5-Feb-2009 [3816x4] | reverse proxy on apache2 with apache on one ip and cheyenne on another ip, put something like this in your virtualhost config: ProxyPass /00/core/ http://192.168.0.110/media/ ProxyPassReverse /00/core/ /media/ ProxyPassReverseCookiePath /media /00/core of course you'll have different ip and path |
this one is a little different and a bit more expensive on resources, if a request doesn't exist (no file match, no folder match) proxy reverse to cheyenne: DirectoryIndex default.html index.html RewriteEngine on RewriteCond /Volumes/data/web%{REQUEST_FILENAME} !-f RewriteCond /Volumes/data/web%{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ http://cheyenne.com$1 [P] | |
one advantage of proxy reversing is you can gzip with apache, rebol doesn't do that natively | |
of course you'll have to enable the proper modules in apache and for the first example, you only need ProxyPassReverseCookiePath if path do not match 8) | |
Janko 8-Feb-2009 [3820] | Do you guys advise running cheyenne behind reverse proxy or direcly on web in general? (if I would use reverse proxv I would try nginx) |
Dockimbel 8-Feb-2009 [3821x2] | New Cheyenne v0.9.19 test release available at http://cheyenne-server.org/tmp/cheyenne-r0919.zip. This should be the last one before making 0.9.19 the new official version. ChangeLog (diff from previous one) : o RSP: fix in request/query-string allowing processing parameters values passed through 'validate filter. o RSP: output of RSP scripts is now compressed (using deflate) if the client supports it. o Default static files memory cache now set to 4Mb accepting files up to 64Kb. o Mod-static: fixed a bug in Last-Modified date forming when seconds = 0. |
Proxy : I run all my Cheyenne servers directly on web. Adding a reverse proxy frontend like nginx might be usefull for heavy loaded sites (millions hits/day) or when you need load banlancing and fault tolerance. | |
Janko 8-Feb-2009 [3823] | aha, thanks, I will run it directly too then |
Will 8-Feb-2009 [3824x2] | Janko, Cheyenne is very fast (try benchmarking with siege or ab)! I have heavy loads and special configurations, it has been asked how to make it work with lighttpd, so the discussion.. 8) |
Thank you Dock, I'll check new deflate asap 8) | |
Chris 8-Feb-2009 [3826] | Is there much overhead compressing pages before sending? I know that most modern browsers support deflate... |
Dockimbel 8-Feb-2009 [3827x2] | The compression overhead is small compared to the time gained on the network transfert. Here's a study from intel on that question : http://software.intel.com/en-us/articles/http-compression-for-web-applications/ |
I just measured loading times on CC using pages with 200 tickets listed. On average, before compression ~700ms, after ~300ms. (40ms latency between my PC and the server). | |
Chris 8-Feb-2009 [3829] | Good to know, thanks! |
Dockimbel 8-Feb-2009 [3830] | Download links : - sources: : http://cheyenne-server.org/tmp/cheyenne-r0919.zip - Windows test binary : http://cheyenne-server.org/tmp/cheyenne0919.zip - Linux test binaries : o Enpro : http://cheyenne-server.org/tmp/cheyenne0919-pro.gz o Enface : http://cheyenne-server.org/tmp/cheyenne0919-face.gz |
Janko 8-Feb-2009 [3831x2] | Will: that is exactly what I did when I tried to use it and saw the workflow/api very nice, then I tested the req/sec and I astonished reported here :) (1 month or so back) |
yes, it's very fast... still don't fully get it :) | |
Robert 9-Feb-2009 [3833] | I have some more questions: 1. Is it possible to use virtual hosting? I have a bunch of doamins. Lighttpd has a super-simpel and easy way to support virtual doamins. 2. I think that things like PHP etc. is supported as well, right? |
Janko 9-Feb-2009 [3834] | 1. yes 2. It has php support (I haven't tried it yet) |
Dockimbel 9-Feb-2009 [3835] | PHP needs to be patched first on UNIX before being usable by Cheyenne, see : http://www.cheyenne-server.org/blog.rsp?view=15 |
older newer | first last |