ThreeMammals / Ocelot

.NET API Gateway

Home Page:https://www.nuget.org/packages/Ocelot

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Routes containing attribute "UpstreamHost " cannot be found

nrllhylmz opened this issue · comments

Hi,

My routes worked fine for ocelot 18.0.0
But it didn't work for ocelot 22.0.1

warn: Ocelot.DownstreamRouteFinder.Middleware.DownstreamRouteFinderMiddleware[0]
	  requestId: 0HN0N5ETGHV6K:00000001, previousRequestId: No PreviousRequestId, message: 'DownstreamRouteFinderMiddleware setting pipeline errors. IDownstreamRouteFinder returned Error Code: UnableToFindDownstreamRouteError Message: Failed to match Route configuration for upstream path: /test/WeatherForecast, verb: GET.'
warn: Ocelot.Responder.Middleware.ResponderMiddleware[0]
	  requestId: 0HN0N5ETGHV6K:00000001, previousRequestId: No PreviousRequestId, message: 'Error Code: UnableToFindDownstreamRouteError Message: Failed to match Route configuration for upstream path: /test/WeatherForecast, verb: GET. errors found in ResponderMiddleware. Setting error response for request path:/test/WeatherForecast, request method: GET'

Sample project link for you to try: https://github.com/nrllhylmz/Example
Sample project's details: #1925 (comment)

Thanks

@ks1990cn Hello Tanmay!
How do you do?
Please help us to reproduce this "bug"! 🙏 What I see now, is a misconfiguration issue...
Also, attached solution is learning one, and it has no Docker Compose setup and it will be hard to reproduce juggling multiple Visual Studio debug sessions for each service instance... 😄 But possible to juggle multiple console apps and start each service in separate console using self-hosted scenarios.