Forum OpenACS Development: Redirects handling broken in request processor?

I was unable to get a custom 404 or other error page to work with ACS 4. I would always get a message in my log file saying "recursion limit exceeded". I set up my config file with something like this:
ns_section "ns/server/${server}/redirects"
  ns_param 404 "/global/notfound.html"
I found a thread from the old ACS bboard, which indicates that there is a bug with caching of ad_conn information somehow.

http://www.arsdigita.com/bboard/q-and-a-fetch-msg? msg_id=000c26

And in fact adding the suggested patch to rp_handler does seem to make the error redirect work in my OpenACS4 installation.

Has anyone else been able to get custom error pages to work without this hack??


ad_proc -private rp_handler {} {

  The request handler, which responds to absolutely every HTTP 
request made to
  the server.

} {
  ad_call_proc_if_exists ds_collect_connection_info

  if {[string compare [ns_conn url] [ad_conn url]] != 0} {
    rp_debug "ad_conn and ns_conn differ, must be a redirect!"

message in my log file saying "recursion limit exceeded" - Henry, what did you have your stack size set to in your AOLServer control file? I got a message something like that for all of my adp pages the first time I installed ACS 4.2. Turned out I needed to bump the stack size from 128*1024 that was in the default config file. I pulled 500,000 out of an older .ini style file and my adp pages started working.

Hi,

Am seeing the same error messages on my logs as well. The stack size on my control file is already 500000 but I increased it to 800000 but I still see the errors. I noticed though that there are two entires for StackSize.

ns_section ns/parameters
ns_param User nsadmin
ns_param Group nsadmin
ns_param ServerLog ${AOL_HOME}/log/${service_short_name}/server.log
ns_param Home ${AOL_HOME}
ns_param StackSize 800000
ns_param MaxKeepAlive 0

ns_section ns/threads
# use more than 1 processor (Solaris)
ns_param SystemScope on
ns_param StackSize 131072

Regards,

That is strange because I could redirect 404 pages to a custom ADP page. Check out the ADP or TCL for 404 error page thread for more information.