-
Notifications
You must be signed in to change notification settings - Fork 135
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
Replace Non Standard IfMatch Header with Standard If-Match Header #747
Comments
Can you please tell me which version of Restier you are using? Looking at the code, Restier just gets the information from OData, and the latest versions of both |
“If-Match” header is defined in OData protocol 3.0/4.0/4.01. and restier 1.0.0 beta supports it perfectly. I was wondering something was wrong in later version upgrade. mybe the first initials for supporting netcore. @robertmclaws related testcases is also important.. |
Pretty sure that I got that method from OData source at that time to minimize reflection calls. It might be beneficial to either get OData to friend us (InternalsVisibleTo), or to use reflection anyway to avoid having to fix these things in both projects. @robertmclaws what do you think? Be smart and try to fix it the proper way or just do a simple bugfix... Scratch that, I think it's a copy of the controller at that time. |
@jspuij I mean, we need to catch up on some stuff, so happy to grab some time to dig in. I seem to remember taking a look and seeing that we were doing it the OData way, so if there's a problem it may be in WebAPI or ODL, at which point we may need to contribute a fix higher up the stack. |
When working with the OData E-Tag, Restier expects the Header to contain
IfMatch
.This Header actually contains a hyphen, according (see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/If-Match).
Per RFC 7232 the Notation is also
If-Match
(see https://www.rfc-editor.org/rfc/rfc7232#section-3.1)When working with E-Tags, we currently require a fix in our request pipeline to rewrite the header:
For Batch Requests we need an additional Batch-Interceptor to rewrite the header (which I am currently still working on)
Expected result
I expect ResTier to work with Standard HTTP Headers and not need a workaround for this
Actual result
Restier expects the Header in the Notation
IfMatch
The text was updated successfully, but these errors were encountered: