Custom Error without showing zoo error

Repository of web frameworks and applications for Microsoft IIS.
User avatar
Posts: 1
Joined: 06 Jun 2017, 13:55

Custom Error without showing zoo error

06 Jun 2017, 14:07

I am working on a website which has custom errors in Rails. (The site uses IIS and Helicon Zoo on a windows server)

In order to get these custom errors to work, I needed to turn error mode to custom/detailed. This allows any 500, 404, etc. error to go to a page in the rails application that handles it ( checks if it should redirect anywhere, records the error to a table, and on a 500 shows the error to an admin user, and on 404 shows suggested pages to users.)

However, whenever there is an error with rails itself running, (a gem missing, syntax error, timeout, etc.) it falls back to the helicon zoo error page, which shows the full error and environment variables to the user. (NOT good!) I have looked into many solutions and alternatives, but cannot find a way to get the desired functionality. (Custom rails errors on 500/404 errors, but NO zoo error on rails server not running) The only solution to this problem I have been able to find seems to be to turn custom/detailed errors off, which would not allow us to do the custom rails error pages, and we would need to create html error pages that are not part of the rails code/server, or rely on default iis errors.


Is there a way we can have these custom rails error routes, but not show the zoo errors when the server has problems running? Or at least a way to change the Helicon Zoo errors to no longer show the environment variables and stack trace?

Thanks.

User avatar
Posts: 402
Joined: 06 Mar 2012, 11:59

Re: Custom Error without showing zoo error

12 Jun 2017, 07:56

Hello.

Zoo error only pops up when application backend completely failed to handle the request, basically when backend worker crashed or did not return correct response. Whether backend worker returns error status code, i.e. 50x, 40x, etc, the request is considered handled by backend anyway and Zoo error does not show up. Thus if there is a way to configure Ruby not to crash on errors but return some custom error page instead, it should work with Zoo as well. I only suspect that custom errors you are referring are part of some Ruby development web server, and not Rails framework itself.
Next, Zoo errors are just normal IIS errors and Zoo relies on IIS settings regarding error handling. So you can intercept these errors as well and reroute them to custom page using IIS settings (like custom errors, etc.) Alternatively, you can use Helicon Ape custom error feature to intercept error responses and return custom error pages.

User avatar
Posts: 1
Joined: 02 Nov 2017, 09:25

Re: Custom Error without showing zoo error

02 Nov 2017, 09:29

That is a pity, it would have been a decent element. Is it conceivable to cripple the 404 divert from Yootheme to permit another module to divert to a custom article.

site :

https://www.bestessaywritingservice.co/

User avatar
Posts: 1
Joined: 10 Nov 2017, 06:17

Re: Custom Error without showing zoo error

10 Nov 2017, 06:32

I am really glad I’ve found this information.

Return to Helicon Zoo

Who is online

Users browsing this forum: No registered users and 4 guests