-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't configure programatically in MVC or WebApi #93
Comments
@ChadBurggraf we did take a shortcut here to get this out, are you able to explain a bit more to me about how you would expect to use/configure the bugsnag client in this scenario? You can post in here or email me [email protected]. Thanks! |
I would like to set the API key, release stage and app version at runtime. I would also like to dynamically disable/enable reporting at runtime, but I think that's possible through the middleware system. |
Would you be entirely configuring the client programmatically or would you also be using the web.config? You can ignore reports using the middleware system. What would be the conditions that you would be using to disable/enable reporting? |
I'm okay with doing either (a combination of programatically and web.config, or just programatically). Yes, thank you, I did see that I can use the middleware system to disable reporting. |
I just tried upgrading our BugSnag libraries to 2.0 and ran smack into this as well. We need to ability to set global configuration for the MVC/WebAPI clients programatically. |
@ChadBurggraf @tynorton thanks for letting us know that you want to use Bugsnag like this, we have added this to our backlog of things that we really want to add. I'll keep you up to date with our progress on it |
I've upgraded and hit the same issue too. We dynamically set the app version at runtime based on the assembly version of our site; and the release stage depending on if the site is running in development, staging, or production. |
Hi everyone, unfortunately I don't have any progress to report on this issue at the moment. The only work around I can suggest right now is to use the core Bugsnag nuget package only and take a look at the code in the other packages as it's quite minimal to see how it hooks into the ASP.NET lifecycle. I'll update this issue when I can jump back onto implementing this |
I have been playing with some ways of making this possible, and I hope you don't mind but I've submitted an example PR (#108) with what I've come up with to make this possible. It may be rubbish. It may be completely unsuitable. But it's what I might for the time being to get around the configuration constraints in one of our web apps. |
Any update on this? It's been nearly half a year since this issue was reported. |
@martin308 - Any update on whether this item has made it out of your backlog yet? |
I really need to be able to set at least the appVersion programmatically as well. |
All of the configuration sections' properties are read-only.
The text was updated successfully, but these errors were encountered: