Skip to content
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

When making a get request that should return a Json body, the RequestContext returns nothing #126

Closed
dat-vikash opened this issue Jun 3, 2015 · 1 comment

Comments

@dat-vikash
Copy link

I am testing Zuul out as an edge gateway to a micro service that returns json for a GET request. I used the sample route filter in the simple-webapp, but nothing is returned. When I inspect the HttpResponse in the sendResponse() method I do see the json content in the entity.content , however when it is converted to a httpServerletResponse for the RequestContext all response body, code, and content length is lost. Is the example route filter incorrect or am I doing something wrong?

@dat-vikash
Copy link
Author

I figured this out, you need the post/SendResponse.groovy filter to actually write responses back to the client. I wish there was a way to make PR against the wiki to include this under the Writing Filters part, but since there is not, can someone at netflix please update the Wiki with this tidbit as it may save others some time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants