Git Product home page Git Product logo

exceptionless.net's People

Contributors

adamsitnik avatar adamzolotarev avatar barankaynak avatar benaadams avatar bitbeans avatar d18zj avatar deanhume avatar edwardmeng avatar ejsmith avatar elachlan avatar frankebersoll avatar geirgrusom avatar h82258652 avatar inlineasm avatar kellyelton avatar lscpike avatar mattbrooks2010 avatar mgnslndh avatar mihamarkic avatar moogle001 avatar niemyjski avatar phyxionnl avatar purekrome avatar rbaz avatar snakefoot avatar srijken avatar varorbc avatar wu-yafeng avatar xbelt avatar yang-xiaodong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

exceptionless.net's Issues

Nancy exception

ExceptionlessClient.Default.RegisterNancy(pipelines);

Exception Details: System.MissingMethodException: Method not found: 'Nancy.ErrorPipeline Nancy.ErrorPipeline.op_Addition(Nancy.ErrorPipeline, System.Func`3<Nancy.NancyContext,System.Exception,Nancy.Response>)'.

This happens with latest version of Nancy (1.3) and latest Exceptionless on NuGet.

Generated referenceIds aren't sent to the collector

See testcase in #29

The problem is that Event is serialized to the queue path on disk using ExceptionlessContractResolver, then during processing it gets deserialized using DefaultContractResolver that doesn't know how to deserialize reference_id.

StackOverflowException with EventBuilder

ExceptionlessClient.Default.SubmittingEvent += (sender, e) =>
                    {
                        if (e.IsUnhandledError)
                        {
                                var builder = new EventBuilder(e.Event, e.Client, , e.PluginContextData);
                                builder.AddTagsUnhandled").Submit(); // <-- Generates a StackOverFlowException when e.PluginContextData is also added to the above constructor.
                                e.Cancel = true;
                        }
                    };         

Serializer doesn't special case abbreviations.

When I use the EventBuilder.AddObject method, with an object containing a dictionary<string, int>, I see on Exceptionless (Extended Data) that the key of the dictionary is changed (eg. "MP3" -> "m_p3", "FLAC" -> "F_l_a_c"). I use latest nuget package Exceptionless.Wpf.

Thanks

ExceptionlessClient.Default.CreateLog("Source", "Message").AddObject(new LogInfo2()).Submit();
public class LogInfo2
   {
      public LogInfo2()
      {
         files.Add("MP3", 281);
         files.Add("FLAC", 23);
      }

      private readonly Dictionary<string, int> files = new Dictionary<string, int>(StringComparer.OrdinalIgnoreCase);

      public Dictionary<string, int> Files
      {
         get { return files; }
      }      
   }

High CPU infinite loop caused by plugin.Run() enumerating dictionary

What looks like a threading issue in exceptionless has just taken down one of my servers. This occurred following IIS recycling the process, so basically at app start.. I have managed to get a memory dump of the process and this was reported from the analysis:

The following threads in w3wp.DMP are enumerating a System.Collections.Generic.Dictionary object
( 85 -snip 47 thread IDs here- 157 )
30.25% of threads blocked (49 threads)

Multiple threads enumerating through a collection is intrinsically not a thread-safe procedure. If the dictionary object accessed by these threads is declared as static then the threads can go in an infinite loop while trying to enumerate the dictionary if one of the threads writes to the dictionary while the other threads are reading\enumerating through the same dictionary. You may also experience High CPU during this stage. For more details refer to High CPU in .NET app using a static Generic.Dictionary
http://blogs.msdn.com/b/tess/archive/2009/12/21/high-cpu-in-net-app-using-a-static-generic-dictionary.aspx

The top of the stack for each of these threads is:

System.Collections.Generic.Dictionary2[[System.__Canon, mscorlib],[System.__Canon, mscorlib]].FindEntry(System.__Canon)+c8 System.Collections.Generic.Dictionary2[[System.__Canon, mscorlib],[System.__Canon, mscorlib]].ContainsKey(System.__Canon)+9
Exceptionless.ExceptionlessConfigurationExtensions.GetInstallId(Exceptionless.ExceptionlessConfiguration)+86
Exceptionless.Plugins.Default.EnvironmentInfoPlugin.Run(Exceptionless.Plugins.EventPluginContext)+cd
Exceptionless.Plugins.EventPluginManager.Run(Exceptionless.Plugins.EventPluginContext)+14b
Exceptionless.ExceptionlessClient.SubmitEvent(Exceptionless.Models.Event, Exceptionless.Plugins.ContextData)+238
System.Web.HttpApplication.RaiseOnError()+87
System.Web.HttpApplication.RecordError(System.Exception)+381
System.Web.HttpApplication.RecordError(System.Exception)+2c9

Since Dictionary<> is thread safe on reads, i'm guessing there is a problem around reporting exceptions while exceptionless is still in startup? (Assuming persistedClientData is only configured once in startup)

Looking in the ObservableDictionary class, my first suggestion was going to be switch Dictionary to a ConcurrenctDictionary but this class isn't supported in a portable library. I then thought maybe I could scatter locks all over the place but that won't work.

Maybe we can lock exceptionless reporting when it is in startup?

I'm happy to help fix this issue but being unfamiliar with this code i'm not sure where to go next. Any ideas how to write a test to replicate the issue?

(ps, I was going to post this on user voice as per guidelines (as this may need more discussion) but it looks inactive, maybe the guidelines need updating.)

ApiKey can't be changed after the client has been initialized.

This occurs when the autostart property of IIS is enabled (IIS 8 and MVC 5).

[ArgumentException: ApiKey can't be changed after the client has been initialized.]
   Exceptionless.ExceptionlessConfiguration.set_ApiKey(String value) +127
   Exceptionless.ExceptionlessExtraConfigurationExtensions.ReadFromConfigSection(ExceptionlessConfiguration config) +224
   Exceptionless.ExceptionlessExtraConfigurationExtensions.ReadAllConfig(ExceptionlessConfiguration config, Assembly[] configAttributesAssemblies) +232
   Exceptionless.ExceptionlessClientExtensions.Startup(ExceptionlessClient client, AppDomain appDomain) +82
   Exceptionless.Mvc.ExceptionlessModule.Init(HttpApplication app) +43
   System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +530
   System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +304
   System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +404
   System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +475

[HttpException (0x80004005): ApiKey can't be changed after the client has been initialized.]
   System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +12979668
   System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +159
   System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +12819261

Queue data is not persisted

After 3 unsuccessful attempts to upload event data or 1 day in the queue, event data is lost. This data is vital for my team, where the application is used 80% offline.

Exception occurred while creating an instance of the ExceptionlessClient

(SocketException) An operation was attempted on something that is not a socket

at System.Net.SafeCloseSocketAndEvent.CreateWSASocketWithEvent(AddressFamily addressFamily, SocketType socketType, ProtocolType protocolType, Boolean autoReset, Boolean signaled)
   at System.Net.NetworkInformation.NetworkChange.AddressChangeListener.StartHelper(NetworkAddressChangedEventHandler caller, Boolean captureContext, StartIPOptions startIPOptions)
   at System.Net.NetworkInformation.NetworkChange.AvailabilityChangeListener.Start(NetworkAvailabilityChangedEventHandler caller)
   at System.Net.NetworkInformation.NetworkChange.add_NetworkAvailabilityChanged(NetworkAvailabilityChangedEventHandler value)
   at Exceptionless.ExceptionlessClient..ctor(IQueueStore store, IExceptionlessLog log)
   at Exceptionless.ExceptionlessClient.<.cctor>b__11()
   at System.Lazy`1.CreateValue()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Lazy`1.get_Value()
   at Exceptionless.ExceptionlessClient.get_Current()
   at Exceptionless.ErrorExtensions.ToExceptionless(Exception exception, Boolean addDefaultInformation, IDictionary`2 pluginContextData, ExceptionlessClient client)
   at Exceptionless.ErrorExtensions.ToExceptionless(Exception exception)
   at Example.ErrorHandling.ErrorsLogProvider.WriteLogEntry(ErrorLevel level, Object message, Exception exception) in c:\Users\USER\Source\Repos\Example\Source\Example\ErrorHandling\ErrorsLogProvider.cs:line 166
   at Example.ErrorHandling.ErrorsLogProvider.Error(String message, Exception exception) in c:\Users\USER\Source\Repos\Example\Source\Example\ErrorHandling\ErrorsLogProvider.cs:line 55
   at Example.External.ExampleMethods.FetchExampleRating() in c:\Users\USER\Source\Repos\Example\Source\Example\External\ExampleMethods.cs:line 35
   at Example.Presentation.SiteCache.BragAboutExampleReviews() in c:\Users\USER\Source\Repos\Example\Source\Example\Presentation\SiteCache.cs:line 70
   at Example.ViewModels.SupplierRegisterViewModel..ctor() in c:\Users\USER\Source\Repos\Example\Source\Example.Web\ViewModels\SupplierRegisterViewModel.cs:line 33
   at Example.Controllers.SuppliersController.Register(String version, Boolean campaign) in c:\Users\USER\Source\Repos\Example\Source\Example.Web\Controllers\SuppliersController.cs:line 59
   at lambda_method(Closure , ControllerBase , Object[] )
   at System.Web.Mvc.ActionMethodDispatcher.Execute(ControllerBase controller, Object[] parameters)
   at System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters)
   at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters)
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.ActionInvocation.InvokeSynchronousActionMethod()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.<BeginInvokeSynchronousActionMethod>b__39(IAsyncResult asyncResult, ActionInvocation innerInvokeState)
   at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`2.CallEndDelegate(IAsyncResult asyncResult)
   at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End()
   at System.Web.Mvc.Async.AsyncResultWrapper.End[TResult](IAsyncResult asyncResult, Object tag)
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethod(IAsyncResult asyncResult)
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3d()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.<>c__DisplayClass46.<InvokeActionMethodFilterAsynchronouslyRecursive>b__3f()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass33.<BeginInvokeActionMethodWithFilters>b__32(IAsyncResult asyncResult)
   at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult)
   at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End()
   at System.Web.Mvc.Async.AsyncResultWrapper.End[TResult](IAsyncResult asyncResult, Object tag)
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethodWithFilters(IAsyncResult asyncResult)
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass21.<>c__DisplayClass2b.<BeginInvokeAction>b__1c()
   at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass21.<BeginInvokeAction>b__1e(IAsyncResult asyncResult)

Version: 1.5.2121

Add support for ASP.NET Core

I realize that it's still in preview/beta, but as it stands any project using vNext, cannot use Exceptionless

Duplicate errors with unhandled exceptions in ASP.NET MVC application

I just switched from AppFail.Net due to extremely lengthy delays in notification, to try out Exceptionless.Net. I was able to easily add the libraries using NuGet:

PM> Install-Package Exceptionless.MVC -Source nuget.org
Attempting to resolve dependency 'Exceptionless.Portable (= 3.2.1424)'.
Installing 'Exceptionless.Portable 3.2.1424'.
Successfully installed 'Exceptionless.Portable 3.2.1424'.
Installing 'Exceptionless.Mvc 3.2.1424'.
Successfully installed 'Exceptionless.Mvc 3.2.1424'.
Adding 'Exceptionless.Portable 3.2.1424' to PTS.WebUI.
Successfully added 'Exceptionless.Portable 3.2.1424' to PTS.WebUI.
Adding 'Exceptionless.Mvc 3.2.1424' to PTS.WebUI.
Successfully added 'Exceptionless.Mvc 3.2.1424' to PTS.WebUI.

However, after compiling and triggering an unhandled exception, I receive two identical errors logged in the Exceptionless dashboard (in my case, it's a System.NullReferenceException) for every exception I generate.

I have made no changes to the default configuration other than setting my Exceptionless apiKey in Web.config. I have already removed the AppFail libraries and configuration from web.config.

Feature request: OnSended event (WPF)

When a user have submitted an issue from the submission dialog, it would be great to have an event so that the app can decide (for example) weather the applications execution should continue or if it should terminate.

Thanks in advance :)

Handling of AggregateExceptions data of some inner exceptions is lost

The current ErrorModel allows for just one inner exception, whereas the AggregateException allows for multiple inner exceptions. Right now it appears that the aggregate exception is logged; the first inner exception is logged, but the rest of the inner exceptions gets lost.

Also when AggregateExceptions is nested within another AggregateException information is lost, because of a missing .Flatten() call.

ToExceptionless breaks when the exception isn't loadable. FileNotFoundException is thrown.

ToExceptionless should never (ever) fail, because we use it in error handling code. :)

When the exception is thrown in another app domain and caught in the appdomain that doesn’t have the exception defined, when we call ToExceptionless is throws a FileNotFound exception.
Can you add error handling in ToExceptionless so if it fails with this, it gives the best report it can but doesn’t fail?

Here is my hack at error handling with a custom extension method that calls ToExceptionless:

    public static EventBuilder ToExceptionModel(this Exception exception, ContextData pluginContextData = null, 
        ExceptionlessClient client = null)
    {
        try
        {
            try
            {
                return exception.ToExceptionless();
            }
            catch (FileNotFoundException)
            {
                if (client == null)
                {
                    client = ExceptionlessClient.Default;
                }
                if (pluginContextData == null)
                {
                    pluginContextData = new ContextData();
                }

                pluginContextData.SetException(new ApplicationException(exception.Message));
                var builder = client.CreateEvent(pluginContextData);
                builder.AddObject(exception.StackTrace, name: "StackTrace");
                return builder;
            }
            catch
            {
                return new ApplicationException("Could not create exception model. Original exception: "
                    + exception.Message).ToExceptionless();
            }
        }
        catch {
            return new ApplicationException(
                "An unknown error occurred and we could not create the exception model.").ToExceptionless();
        }
    }

Here’s an example stack trace from our app that causes this:

System.IO.FileNotFoundException: Could not load file or assembly 'Demo.Service, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.
at System.Reflection.RuntimeAssembly._nLoad(System.Reflection.AssemblyName fileName, System.String codeBase, System.Security.Policy.Evidence assemblySecurity, System.Reflection.RuntimeAssembly locationHint, System.Threading.StackCrawlMark& stackMark, System.IntPtr pPrivHostBinder, System.Boolean throwOnFileNotFound, System.Boolean forIntrospection, System.Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(System.Reflection.AssemblyName assemblyRef, System.Security.Policy.Evidence assemblySecurity, System.Reflection.RuntimeAssembly reqAssembly, System.Threading.StackCrawlMark& stackMark, System.IntPtr pPrivHostBinder, System.Boolean throwOnFileNotFound, System.Boolean forIntrospection, System.Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoad(System.String assemblyString, System.Security.Policy.Evidence assemblySecurity, System.Threading.StackCrawlMark& stackMark, System.IntPtr pPrivHostBinder, System.Boolean forIntrospection)
at System.Reflection.RuntimeAssembly.InternalLoad(System.String assemblyString, System.Security.Policy.Evidence assemblySecurity, System.Threading.StackCrawlMark& stackMark, System.Boolean forIntrospection)
at System.Reflection.Assembly.Load(System.String assemblyString)
at System.Runtime.Serialization.FormatterServices.LoadAssemblyFromString(System.String assemblyName)
at System.Reflection.MemberInfoSerializationHolder..ctor(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context)
at System.Exception.GetExceptionMethodFromString
at System.Exception.GetTargetSiteInternal
at Exceptionless.Extensions.ToErrorModelExtensions.ToErrorModel(System.Exception exception, Exceptionless.Logging.IExceptionlessLog log)
at Exceptionless.ExceptionlessClient.ToError(Exceptionless.ExceptionlessClient client, System.Exception exception, System.String submissionMethod, System.Collections.Generic.IDictionary2 contextData) at Exceptionless.ErrorExtensions.ToExceptionless(System.Exception exception, System.Boolean addDefaultInformation, System.Collections.Generic.IDictionary2 pluginContextData, Exceptionless.ExceptionlessClient client)
at CustomerCodeRemovedHere.cs

EnvironmentInfoCollector in Exceptionless.Extras throws Exceptions on Mono

On my test maschine (Ubuntu 14.04) i first had to install: libmono-microsoft-visualbasic11.0-cil

otherwise:

System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.
File name: 'Microsoft.VisualBasic, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

after installing the related package i got:

EnvironmentInfoCollector: Unable to get physical memory. Error message: The requested feature is not implemented.
EnvironmentInfoCollector: Unable to get process id. Error message: GetCurrentProcessId
EnvironmentInfoCollector: Unable to get process name. Error message: GetModuleHandle
EnvironmentInfoCollector: Unable to get thread id. Error message: GetCurrentThreadId

The problem is, that in Microsoft.VisualBasic.Devices the needed methods are not implemented:

See: https://github.com/mono/mono-basic/blob/master/vbruntime/Microsoft.VisualBasic/Microsoft.VisualBasic.Devices/ComputerInfo.vb

The report still works, but you will see reported errors in your log file.

Not every exceptions are caught in MVC or WebAPI

Some exceptions in my MVC application are not caught by Exceptionless and don't know why:

  • When a mvc controller cannot be created

InvalidOperationException: An error occurred when trying to create a controller of type 'WebApplication2.Controllers.HomeController'. Make sure that the controller has a parameterless public constructor.

  • If the error is outside MVC, the error is not caught. For example, if a class is being created from Autofac and his constructor throw an exception, Exceptionless will not caught the error. If a create the same object from an ActionResult and the constructor throw the error, it WILL be caught.
  • If i have a bad link (404 not found), i have nothing in the Exception dashboard nor broken links dashboard.
  • in WebAPI, if an api call my repository and my repository throw an exception, it is not caught. This is strange because if i call the same method from MVC, the error IS caught.

Any idea why some exceptions are logged and others don't?

Config Section wasn't added when installing nuget package


PM> Install-Package Exceptionless 
Attempting to gather dependencies information for package 'Exceptionless.3.1.1382' with respect to project targeting '.NETFramework, Version=v4.5.2'
Attempting to resolve dependencies for package 'Exceptionless.3.1.1382' with DependencyBehavior 'Lowest'
Resolving actions to install package 'Exceptionless.3.1.1382'
Resolved actions to install package 'Exceptionless.3.1.1382'
Adding package 'Exceptionless 3.1.1382' to folder 'C:\Users\Jonas\Documents\Visual Studio 2015\Projects\JonasDralle.Höheninterpolation\packages'
Added package 'Exceptionless 3.1.1382' to folder 'C:\Users\Jonas\Documents\Visual Studio 2015\Projects\JonasDralle.Höheninterpolation\packages'
Added package 'Exceptionless 3.1.1382' to 'packages.config'
Executing script file 'C:\Users\Jonas\Documents\Visual Studio 2015\Projects\JonasDralle.Höheninterpolation\packages\Exceptionless.3.1.1382\tools\install.ps1'
Unable to index into an object of type System.Xml.XmlChildNodes.
At C:\Users\Jonas\Documents\Visual Studio 2015\Projects\JonasDralle.Höheninterpolation\packages\Exceptionless.3.1.1382\tools\exceptionless.psm1:46 char:178
+                     $parentNode = $configXml.SelectSingleNode("configuration").InsertBefore($configXml.CreateElement('configSections'), $configXml.SelectSingleNode("configuration").ChildNodes[ <<<< 0])
    + CategoryInfo          : InvalidOperation: (0:Int32) [], RuntimeException
    + FullyQualifiedErrorId : CannotIndex

You cannot call a method on a null-valued expression.
At C:\Users\Jonas\Documents\Visual Studio 2015\Projects\JonasDralle.Höheninterpolation\packages\Exceptionless.3.1.1382\tools\exceptionless.psm1:53 char:27
+             $parentNode.AppendChild <<<< ($configSection)
    + CategoryInfo          : InvalidOperation: (AppendChild:String) [], RuntimeException
    + FullyQualifiedErrorId : InvokeMethodOnNull

Successfully installed 'Exceptionless 3.1.1382' to JonasDralle.Höheninterpolation.
PM>

References exceptionless/Exceptionless#128

Using IsolatedStorage fails with TinyIoc Exception

ExceptionlessClient.Default.Configuration.UseIsolatedStorage();
var storage = ExceptionlessClient.Default.Configuration.Resolver.GetFileStorage();
TinyIoC.TinyIoCContainer.ConstructType(Type requestedType, Type implementationType, ConstructorInfo constructor, NamedParameterOverloads parameters, ResolveOptions options) TinyIoC.cs: line: 3793
TinyIoC.TinyIoCContainer.ConstructType(Type requestedType, Type implementationType, ConstructorInfo constructor, ResolveOptions options) TinyIoC.cs: line: 3739
TinyIoC.TinyIoCContainer.SingletonFactory.GetObject(Type requestedType, TinyIoCContainer container, NamedParameterOverloads parameters, ResolveOptions options) TinyIoC.cs: line: 2947
TinyIoC.TinyIoCContainer.ResolveInternal(TypeRegistration registration, NamedParameterOverloads parameters, ResolveOptions options) TinyIoC.cs: line: 3486
TinyIoC.TinyIoCContainer.Resolve(Type resolveType) TinyIoC.cs: line: 1578
Exceptionless.Dependency.DefaultDependencyResolver.Resolve(Type serviceType) DefaultDependencyResolver.cs: line: 12
Exceptionless.Dependency.DependencyResolverExtensions.Resolve[TService](IDependencyResolver resolver, TService defaultImplementation) DependencyResolverExtensions.cs: line: 32
Exceptionless.Dependency.DependencyResolverExtensions.GetFileStorage(IDependencyResolver resolver) DependencyResolverExtensions.cs: line: 74
Exceptionless.SampleWpf.App.Application_Startup(Object sender, StartupEventArgs e) App.xaml.cs: line: 10
System.Windows.Application.OnStartup(StartupEventArgs e)
System.Windows.Application.<_ctor>b__0(Object unused)
System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
System.Windows.Threading.DispatcherOperation.InvokeImpl()
System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
System.Windows.Threading.DispatcherOperation.Invoke()
System.Windows.Threading.Dispatcher.ProcessQueue()
System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
System.Windows.Application.RunDispatcher(Object ignore)
System.Windows.Application.RunInternal(Window window)
Exceptionless.SampleWpf.App.Main() App.g.cs: line: 0
System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
System.Threading.ThreadHelper.ThreadStart()

Also by default we are not using IsolatedStorage.

Silverlight has issues posting errors and getting project settings.

I noticed two issues with the latest client when targeting Silverlight. The first issue is a security exception is thrown when posting an error but doesn't happen when debugging (only in release mode). I was able to track down the following stack trace:

System.Security.SecurityException occurred
  Message=Security error.
  StackTrace:
          at System.Net.Browser.ClientHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
          at System.Func`2.Invoke(T arg)
          at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise)
  InnerException: 

Next, noticed that there was an issue trying to GetSettings in the DefaultSubmissionClient. The server returns an OK result with the settings but the client errors out.

System.Net.WebException occurred
  Message=The remote server returned an error: NotFound.
  StackTrace:
       at System.Net.Browser.ClientHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
  InnerException: 

readme.txt epansion

As a noob coder loading Exceptionless.Windows into my project for the first time...

readme.txt showing up right on the load of the nuget package was awesome, and the text reads really well, easy to follow, but....

Right after the initial setup, I want a link to take me to more small examples on how to set up the cool implementations of your project like Blake showed me in a demo. Just small things so as a visual learner, I can jump right in to catching exceptions the way I want to, setting up user recording, adding variables to set on my dashboard and the implementation of that in my code.

Exceptionles web module gets removed by Exceptionless.WebApi

To repro:

  • Install Exceptionless.WebApi
  • Install Exceptionless.Web into the same project
  • Observe that the module is installed in the <modules> section in web.config
  • Run Update-Package -Reinstall Exceptionless.WebApi
  • Observe that the module is now gone

Already set valid api key is overwritten with default api key.

I was setting my api key in code and I noticed that it was being overwritten on the call to register:

ExceptionlessClient.Default.Configuration.ApiKey = "My Key";
ExceptionlessClient.Default.Register();
// Api Key is now set to API_KEY_HERE

My app config had:

<exceptionless apiKey="API_KEY_HERE" />

Fix CrashReportDialog styling or add dialog provider configuration?

I am using MaterialDesignInXamlToolkit together with Exceptionless and the CrashReportDialog does not look OK to me. I guess other themes applied at the application level can cause similar issues.

image

I have two problems with the look of the CrashReportDialog when the material design theme is applied:

  1. The buttons use hardcoded width which cause problems with the material design style for buttons. This is potential problem any style.
  2. The CrashReportDialog use default styles which are overridden at the application level to use the material design styles. This might be ok for certain styles/themes but for the material design style I think I would like more control to make it look even more "material".

Some suggestions that can be implemented separately or in combination as a solution to the styling issues:

  1. Provide ICrashReportDialog abstraction and ability to configure a factory. This would allow a developer to provide his own implementation and total control over the user experience.
  2. Make sure the CrashReportDialog use its own styles for the presentation and does not rely on default styles that can be overriden at application level.

Add expander showing actual Exception

It would be great to have an expander button (either horizontal or vertical, vertical being proffered) that would expand the dialog and show the actual Exception that occurred in a read-only textbox.

This could include additional info such as Date/Time, machine name, etc.

This would be good for advanced and curious users.

ExceptionlessClientExtensions.Startup override ISubmissionClient previously set by user

Hi,

In the ExceptionlessClientExtensions.Startup method, the default ISubmissionClient is registered even if the user has set a custom ISubmissionClient.

I set my ISubmissionClient before calling client.Register(), so I lost an hour understanding why my ISubmissionClient was not used while submitting events.

It's because Register() --> Startup() override unconditionally the ISubmissionClient:

client.Configuration.Resolver.Register<ISubmissionClient, SubmissionClient>();

Perhaps you could check for already ISubmissionClient registered before registering the default one?

Here is a code showing the issue:

var config = new ExceptionlessConfiguration(DependencyResolver.Default);
         config.Resolver.Register<ISubmissionClient, MySubmissionClient>();
         config.ApiKey = "BD0A3EDC-CA53-4E1A-A82A-882284A24D4C";

         var client = new ExceptionlessClient(config);
        // ISubmissionClient == MySubmissionClient
         client.Register(); 
         // ISubmissionClient == Exceptionless.Extras.Submission.SubmissionClient

How to do logging in Application_Start?

I would like to log when my application start and when the application end. My code look like this but it doesn't log anything but it work when i log something in an ActionResult.

protected void Application_Start()
{
    AreaRegistration.RegisterAllAreas();
    FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
    RouteConfig.RegisterRoutes(RouteTable.Routes);
    BundleConfig.RegisterBundles(BundleTable.Bundles);

    ExceptionlessClient.Default.SubmitLog("Application started");
}

And any idea why the logging doesn't work there?

Configuration Changes event

Hi,

I am 'upgrading' our existing exceptionless implementation from v1 to v2 and came across this line of code :

client.ConfigurationUpdated += (sender, args) => UpdateConfiguration();

It no longer exists and I don't see this documented on the upgrade page. Is this an oversight (or am I just plain blind) ?

(Email received from Blake reads)

I currently don't see any event for this in the new system. I think we need to add something back to: https://github.com/exceptionless/Exceptionless.Net/blob/master/Source/Shared/Configuration/SettingsManager.cs to fire when it's been updated. Could you please log this here: https://github.com/exceptionless/Exceptionless.Net/issues/new

Blake Niemyjski from Exceptionless 8 May 2015

Regards,

Alex Caudron

DuplicateCheckerPlugin

This DuplicateCheckerPlugin is too strict, take this for example:

new Exception("Exception)"
vs
new Exception("OtherException)"
vs
new Exception("Exception", new Exception("InnerException"));

These should not be marked as a duplicate.

Use Isolated Storage by default

Currently isolated storage is not used by default because the registration exists.

I propose we move use isolated storage to the Startup call. The downside of this is what happens if you want to use in memory storage.. you now have to call that call after the startup call. Also, there is no retry or fallback logic in case isolated storage doesn't work (we know there are some issues with this on some machines a long time ago).

@ejsmith thoughts?

Restrict the Priority attribute to only be definable on classes.

The following code compiles and runs without issue but the priority is never picked up. This should be a compile time error. References #35

    public class MyEventPlugin : IEventPlugin
    {
        [Priority(1000)]
        public void Run(EventPluginContext context)
        {
            context.Cancel = true;                                  // I set a breakpoint on this line.
            throw new NotImplementedException();
        }
    }

Processing the queue increments the # attempts after submission.

This should be moved to increment the number of attempts after it has failed. The reason for this is if you start your application and it dies, the queue might be processing but didn't succeed. If this happens three times, the event will be completely discarded without ever being sent.

Event when crash report is submitted successfully

Feature Request:
Whenever a crash/exception happens, the submission form pops up.
When the user submits the report, after submitting it, he should get a messagebox where he sees that it was submitted successfully. For any reason, if the submission wasn’t successful, he should see that it wasn’t able to submit it successfully. Probably a callback on push crash report fail/success would be best.

Looks like this feature isn't there yet. Request you to add support for this feature.

ExceptionlessClient.Default.Register() throws a TypeInitializationException on machines with .NET Framework 4.0 Client Profile only

It appears that the .NET PCL library fails to load (cannot find System.Core 2.0.5.0) on machines with .NET Framework 4.0 Client Profile installed

Stack trace:

Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.TypeInitializationException
Stack:
Server stack trace:
at TinyIoC.TinyIoCContainer..ctor()
at Exceptionless.ExceptionlessClient..ctor()
at Exceptionless.ExceptionlessClient.<.cctor>b__d()
at System.Lazy1.CreateValue() at System.Lazy1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].get_Value()
at Exceptionless.ExceptionExtensions.ToExceptionless(System.Exception, Exceptionless.Enrichments.ContextData, Exceptionless.ExceptionlessClient)
at Celavimus.Client.ApplicationBootstrapper.AttemptToStartClient()
at Celavimus.Client.ApplicationBootstrapper.Main(System.String[])

Based on this blog post it appears to be related to PCLs.

Logging aggregates when throtling has kicked in

After monthly throttling has kicked in, I would like to see the top n (n =10?) issues be captured in aggregate, at least for paid accounts. Instead of shutting off logging until the next reset, can we get something like the following:

You've hit the limit and are being throttled. Here are the top exceptions that might be causing this:

NullRefException Count 10000
DivideByZeroException Count 3400

...in which you stop recording exception details, but when new NullRefExceptions come in you just increment the count without storing it?

Would that be possible? Are you throttling because the customer (me) is paying for a limited number of storage, in which this would be possible?

Also, email notifications when error counts increase over a given threshold would be nice. "We've detected 340 exceptions more per day in the last 24 hours." Or something like that, where the number is a 40% increase over the previous weekly day average. So if something is loaded and exceptionless starts to get spammed we know.

Unable to add plugin to MVC app

I am trying to include a plugin for use within my ASP.NET MVC app. In an attempt to do this, I reviewed this blog post and this sample. When I run my app, it shows my plugin is registered. However, the breakpoint never gets tripped. I have the following:

Global.asax

protected void Application_Start()
{
  ExceptionlessClient.Default.Configuration.AddPlugin<MyEventPlugin>();
}

MyEventPlugin.cs

    public class MyEventPlugin : IEventPlugin
    {
        [Priority(1000)]
        public void Run(EventPluginContext context)
        {
            context.Cancel = true;                                  // I set a breakpoint on this line.
            throw new NotImplementedException();
        }
    }

Finally, in an effort to test my plugin, I have the following:
HomeController.cs
public class HomeController : Controller
{
public ActionResult Test()
{
try
{
int i = 1;
i = i / 0;
}
catch (Exception ex)
{
foreach (var plugin in Exceptionless.ExceptionlessClient.Default.Configuration.Plugins)
{
var pluginName = plugin.Key;
// Via a breakpoint, on the next line, I can see MyEventPlugin is included.
Console.WriteLine(pluginName);
}

 // When the following line is executed, the Run method in MyEventPlugin never gets executed. I am stating this because the breakpoint does not get fired.
 ex.ToExceptionless().Submit();

}
return View();
}

What am I missing?

.NET 4.0 build target

Everything seems to use the Exceptionless.Portable package, which is a portable client package (as the name suggests). However, PCL is not supported on .NET 4.0 unless patched. Can you add another, non-portable, build target for .NET 4.0?

This seems related to #5

Log4net client does not honor a LevelEvaluator

So inside of a log4net appender you can add something like this

<appender name="exceptionless" type="Exceptionless.Log4net.ExceptionlessAppender,Exceptionless.Log4net">
  <layout type="log4net.Layout.PatternLayout">
    <conversionPattern value="%date %-5level %property{version} %property{username} [%thread] %logger - %message%newline %exception"/>
  </layout>
  <evaluator type="log4net.Core.LevelEvaluator">
    <threshold value="INFO"/>
  </evaluator>
</appender>

The idea is that it will only log things that are equal to or over the threshold. Currently it doesn't seem to honor this since it doesn't inherit BufferedAppenderSkeleton.

Maybe a nice answer would be a new appender, like BufferedExceptionlessAppender ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.