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 acting as a proxy, mockey return proxied service's status code #45

Closed
boris73 opened this issue Jun 28, 2011 · 0 comments
Closed

Comments

@boris73
Copy link

boris73 commented Jun 28, 2011

Really, I'd like to see it return all of the headers and cookies too and be able to setup services / scenarios that let me copy these values from the service history, but all I'm suggesting be fixed in the short term is that the http status code of the proxied service be passed to client instead of always returning 200 OK.

Proposed fix in com.mockey.server.ResponseServlet (line 115) add line:

resp.setStatus(response.getStatusLine().getStatusCode());

else branch now reads:

           else {
        resp.setStatus(response.getStatusLine().getStatusCode());
        response.writeToOutput(resp);
    }

thanks.

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