Expect: 100-continue header - APIGEE sends 502 gateway error

HI,

Use-Case: In apigee, based on certain conditions, we wanted to send an error status code or 100-continue to the client. 

When we set 100-Continue in the response flow, the client always receives 502 gateway timeout error. Is this header blocked in APIGEE?

0 5 280
5 REPLIES 5

I  answered a similar question last week. 

https://www.googlecloudcommunity.com/gc/Apigee/Expect-100-continue-header-corrupted/m-p/468804

My question to you is similar to the one  I posed in that reply: 

What problem are you solving?   Can you explain why it is important to you that Apigee itself sends the 100-continue header?

HI @dchiesa1 

Thank for the response. I read the post earlier and it talks about intercepting the "Expect" header in the request.

We are using on-prem solution. While sending the request, instead of "Expect" header we used custom header. so it works 

Question: Is APIGEE intercepts and block(with 502 Gateway error) the response with 100-Continue status code?

Is APIGEE intercepts and block(with 502 Gateway error) the response with 100-Continue status code?

I'm sorry, I don't know the answer to that.

While sending the request, instead of "Expect" header we used custom header. so it works 

What do you mean "we used a custom header".?  the Expect header is sort of defined to have a specific meaning. If you use a different header to pass the same thing, then ... it doesn't mean the. same thing. If the upstream system sends a "100-continue," and Apigee didn't send an Expect header, then that seems like an error, which warrants a 502 error code. 

I don't understand what you're doing, and also I don't understand what problem you are solving. Why is it important that the Expect header and the 100-continue be explicitly managed in the Apigee layer?

If I understand what you're aiming for I might be better able to help or at least advise.

HI @dchiesa1 
Thank you for the response. I may not able to provide the full use case here but here are the technical flow.

1. APIGEE receives the request and route rule configured with no target and actual target. 

2. When certain conditions are met in the proxy pre-flow, we return the response with 100 status code to the client. The 100 status code is assigned in the proxy post flow.

Problem: In the trace file attached below, there are two statuses. In the left side, it says the status is 100 success but on the right side the status shows 502 errors. I am using postman to test and getting a gateway timeout error. 

Question: In APIGEE, are we allowed to send the 100 status response to clients?


err.png