rollbar / Rollbar.NET

Rollbar for .NET
https://docs.rollbar.com/docs/dotnet
MIT License
65 stars 44 forks source link

Rollbar NuGet package version 5.x does not work according to onboarding examples #641

Closed thomaseyde closed 11 months ago

thomaseyde commented 1 year ago

The code examples given during the onboarding process is incorrect.

To Reproduce

  1. Sign up for an account, select .NET as framework, continue the onboarding process
  2. Install Rollbar from NuGet
  3. Copy-paste "Send a Message" code
  4. Observe there are no RollbackConfig and the code will not compile
  5. Replace RollbackConfig with RollbackLoggerConfig, code compiles
  6. Run the code
  7. Observe no message arrives in Rollbar
  8. Downgrade Rollbar NuGet package to version 4.0.3
  9. Replace RollbackLoggerConfig with RollbackConfig
  10. Run code and observe message arrives in Rollbar

Expected behavior Code example should match latest NuGet package version. No compilation errors. Latest version should send message to Rollbar.

Rollbar Client - Rollbar.NET Hosting Environment (please complete the following information):

supertr0n commented 1 year ago

Sadly I've just gone through this exact same process. Not a great onboarding experience.

cyrusradfar commented 1 year ago

@thomaseyde @basecde hear you, we'll look at getting those updated and I'll follow up. Appreciate voicing your concerns so thoughtfully and helpfully 🙏🏽

dan-luk-labx commented 1 year ago

I've the same problem on 5.2.0.

cyrusradfar commented 1 year ago

@rollbar-bborsits can you follow up with status please, seems like the thread is lacking our progress. Thanks @dan-luk-labx

ghost commented 1 year ago

@dan-luk-labx Thanks for the additional info. We'll look into this and try to assist you.

ghost commented 1 year ago

Hey @thomaseyde, You were right. Using the RollbackLoggerConfig would be best to configure the integration properly. I'm sorry for the confusion, the fix is on its way to be released. As the logger works async, the application might close before the SDK sends the payload Rollbar.

The following example logs synchronously:

RollbarInfrastructure.Instance.Init(new RollbarInfrastructureConfig(TOKEN));
RollbarLocator.RollbarInstance.AsBlockingLogger(TimeSpan.FromSeconds(10)).Info("Rollbar is configured properly.");

This should be more suitable for testing Rollbar.

Let me know if this works for you.

ghost commented 11 months ago

It has been a while since I've heard from you, so I'm closing this issue. Don't hesitate to reopen if you need any more help.