-
-
Notifications
You must be signed in to change notification settings - Fork 54
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
Add source header #6
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have one outstanding question that I don't feel qualified to answer without some extra research, before merging.
@@ -110,11 +113,15 @@ function fetchConfigFromReq({ network, req }) { | |||
fetchParams.method = 'POST' | |||
fetchParams.headers = { | |||
'Accept': 'application/json', | |||
'Content-Type': 'application/json' | |||
'Content-Type': 'application/json', | |||
[source]: requestOrigin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess my big question about adding a new header: Does this cause a pre-flight, doubling our load on Infura? I'm not a header pre-flight expert, that would really be my top question for @kumavis.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jennypollack @danfinlay if you inspect the network requests on the BG and you see a bunch of OPTIONS requests right before the POST then the answer is yes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just spent some time clocking network activity between my branch and the current release (5.3.1) for mainnet and rinkeby and the numbers don't lead me to believe that there is a pre-flight. i'm also not seeing any OPTIONS requests before the POST as @brunobar79 mentioned
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed my concern, looks good!
No description provided.