コード例 #1
0
        public virtual void OnHttpException(HttpActionExecutedContext actionExecutedContext, CancellationToken cancellationToken)
        {
            if (HasWrappedFilter)
            {
                WrappedFilter.ExecuteExceptionFilterAsync(actionExecutedContext, cancellationToken);
            }

            var contextData = new Dictionary <string, object> {
                { "HttpActionContext", actionExecutedContext.ActionContext }
            };

            ExceptionlessClient.Current.ProcessUnhandledException(actionExecutedContext.Exception, "ExceptionHttpFilter", true, contextData);
        }
コード例 #2
0
        public virtual void OnHttpException(HttpActionExecutedContext actionExecutedContext, CancellationToken cancellationToken)
        {
            if (HasWrappedFilter)
            {
                WrappedFilter.ExecuteExceptionFilterAsync(actionExecutedContext, cancellationToken);
            }

            var contextData = new ContextData();

            contextData.MarkAsUnhandledError();
            contextData.SetSubmissionMethod("ExceptionHttpFilter");
            contextData.Add("HttpActionContext", actionExecutedContext.ActionContext);

            actionExecutedContext.Exception.ToExceptionless(contextData).Submit();
        }
コード例 #3
0
        protected virtual async Task OnHttpExceptionAsync(HttpActionExecutedContext actionExecutedContext, CancellationToken cancellationToken)
        {
            if (HasWrappedFilter)
            {
                await WrappedFilter.ExecuteExceptionFilterAsync(actionExecutedContext, cancellationToken).ConfigureAwait(false);
            }

            var contextData = new ContextData();

            contextData.MarkAsUnhandledError();
            contextData.SetSubmissionMethod("ExceptionHttpFilter");

            actionExecutedContext.Exception
            .ToExceptionless(contextData, _client)
            .SetHttpActionContext(actionExecutedContext.ActionContext)
            .Submit();
        }