added a new implementation that stores the ocelot config in consul kv store, had to change some major things and add cache settings as default

This commit is contained in:
TomPallister
2017-04-16 19:35:59 +01:00
parent ab9c8e30b2
commit c3cd181b90
34 changed files with 623 additions and 309 deletions

View File

@ -199,7 +199,7 @@ namespace Ocelot.UnitTests.DownstreamRouteFinder
_reRoutesConfig = reRoutesConfig;
_mockConfig
.Setup(x => x.Get())
.Returns(new OkResponse<IOcelotConfiguration>(new OcelotConfiguration(_reRoutesConfig, adminPath)));
.ReturnsAsync(new OkResponse<IOcelotConfiguration>(new OcelotConfiguration(_reRoutesConfig, adminPath)));
}
private void GivenThereIsAnUpstreamUrlPath(string upstreamUrlPath)
@ -209,7 +209,7 @@ namespace Ocelot.UnitTests.DownstreamRouteFinder
private void WhenICallTheFinder()
{
_result = _downstreamRouteFinder.FindDownstreamRoute(_upstreamUrlPath, _upstreamHttpMethod);
_result = _downstreamRouteFinder.FindDownstreamRoute(_upstreamUrlPath, _upstreamHttpMethod).Result;
}
private void ThenTheFollowingIsReturned(DownstreamRoute expected)