Skip to content
This repository has been archived by the owner on Nov 7, 2018. It is now read-only.

IOptionsMonitor should be updated for 2.0 #201

Closed
HaoK opened this issue Jun 15, 2017 · 4 comments
Closed

IOptionsMonitor should be updated for 2.0 #201

HaoK opened this issue Jun 15, 2017 · 4 comments
Assignees
Milestone

Comments

@HaoK
Copy link
Member

HaoK commented Jun 15, 2017

Related #199

Snapshot shouldn't responsible for registering IOptionsChangeTokenSource

I think we need to update IOptionsMonitor to use the new 2.0 functionality especially now that logging uses it.

Proposed changes for IOptionsMonitor

  • Use IOptionsFactory / support names / post configures
  • Use the IOptionsCache to get live updates / handle cache invalidations (should potentially revisit the config reload token hookup to see if there's any improvements there)

@ajcvickers @divega thoughts? With logging using options monitor, its gone from not very important to super important scenario, and it got 0 love in 2.0 so far...

@HaoK
Copy link
Member Author

HaoK commented Jun 15, 2017

Note: if we don't end up updating IOptionsMonitor to use IOptionsCache in 2.0, we should remove the public IOptionsCache since it won't be used anywhere now that Snapshot isn't using it. cc @pakrym

@divega
Copy link

divega commented Jun 15, 2017

@HaoK I like the idea because if I understand correctly this also helps making things more consistent across all options flavors. It adds to the work that you need to do for 2.0, and I am not sure if that is a good idea 😄

@HaoK
Copy link
Member Author

HaoK commented Jun 15, 2017

@divega and I chatted and we're going to try and make options consistent for 2.0.

IOptions/IOptionsMonitor should both switch to using IOptionsFactory to pickup IPostConfigureOptions.

We should support named options at a minimum for IOptionsMonitor and maybe IOptions if I have time

@HaoK
Copy link
Member Author

HaoK commented Jun 26, 2017

50a900b

@HaoK HaoK closed this as completed Jun 26, 2017
@HaoK HaoK added 3 - Done and removed 2 - Working labels Jun 26, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants