creating a feedback/error page for each of my already existing 300 web apps - need some advice

StackOverflow https://stackoverflow.com/questions/19792013

I have a kind of a unique requirement... my company has a portfolio of over 300 web apps. What we want to do is, on each app, create a specific "CommonError.aspx" page - this will be a "global" page that all errors, handled and unhandled, will redirect to. This page will have a text box for custom feedback if the user wants to provide it regarding the error they just encountered, along with several other data points. The user then will be able to click "Submit" and the "feedback" will be fed into a common database, called something like "ErrorFeedback".

Anyways, the idea is to have this functionality in every single one of our apps. Clearly, modifying and customizing each app to include this functionality will be very time consuming. The apps are a mix of MVC and Web Forms. What I would like to do is create a simple, drag and drop, plug and play sort of solution that the developers for each app can take and simply drop into their solution. This whole things screams Nuget, but we aren't using Nuget yet, so that's not an option. I really am not sure how to approach this, and any advice would be great!

有帮助吗?

解决方案

You can create an error handling module, which will catch all errors not caught by your applications. This module will be a drag-and-drop assembly (DLL) that will have to be loaded in the <httpModules> section of each site or server's configuration.

You can for example let the handler log the error somehow (per application, per server or towards one global log[service]), get an ID out of that log entry and redirect to either a page shared for all websites or a generic error handling form that each of your applications will have to contain. Upon showing this page you are free of the somewhat limited environment of the handler (as it is a new request), and can do anything you want with the log ID used in the redirect URL.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top