Skip to content
This repository has been archived by the owner on Jan 24, 2021. It is now read-only.

Switch off the default diagnostic provider #1106

Merged
merged 6 commits into from
Jun 20, 2013

Conversation

jrsconfitto
Copy link
Contributor

Remove the default testing diagnostic provider if another implementation
is found.

i'm not sure if this is the way we want to do it, but here it is for the sake of discussion. What do you think @grumpydev?

Remove the default testing diagnostic provider if another implementation
is found.
@thecodejunkie
Copy link
Member

I know I'm way too tired because I am asking this, but for what scenario is this modification intended? Thanks!

@grumpydev
Copy link
Member

Its because there's no way to hide/disable it.. Its only there to act as a sample - we thought about pulling it out, but having it enabled if nothing else is found is quite nice.

-----Original Message-----
From: "Andreas Håkansson" notifications@github.com
Sent: ‎02/‎06/‎2013 21:48
To: "NancyFx/Nancy" Nancy@noreply.github.com
Cc: "Steven Robbins" steve@robbins.me.uk
Subject: Re: [Nancy] Switch off the default diagnostic provider (#1106)

I know I'm way too tired because I am asking this, but for what scenario is this modification intended? Thanks!

Reply to this email directly or view it on GitHub.

@jrsconfitto
Copy link
Contributor Author

Sorry, i could've explained it better. We're embedding Nancy in one of our products, and i want to improve our diagnostic situation to make our lives better, but i don't want to have customers (or my co-workers) seeing the example diagnostics provider. It wouldn't be a big deal, but i prefer a little more polish in my work.

Also, i'm not sure how to turn it off. Is it possible to get rid of it by adding it to the ignored assemblies?

Being unable to easily disable this example provider doesn't feel very SDHP to me either, i want to help Nancy get better, even if it's something small 😉

@grumpydev
Copy link
Member

Just looked at the code - I would probably exclude the nancy assembly from the scan of diagnostics providers, then just do an Any check in the DefaultDiagnostics ctor that adds the default ones in if there aren't any passed in - rather than trying to remove them if there's other specified.

This will exclude the testing diagnostics provider from Nancy if there's
another interactive diagnostics provider available.
@jrsconfitto
Copy link
Contributor Author

i don't think i did it exactly the way you were suggesting, but is this better @grumpydev ?

grumpydev added a commit that referenced this pull request Jun 20, 2013
@grumpydev grumpydev merged commit 398b685 into NancyFx:master Jun 20, 2013
@jrsconfitto jrsconfitto deleted the adjust-default-diagnostics branch June 20, 2013 14:21
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants