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

load-frontend-fits-file-uri #708

Merged
merged 8 commits into from
Sep 4, 2024
Merged

Conversation

burnout87
Copy link
Collaborator

No description provided.

Copy link

codecov bot commented Aug 29, 2024

Codecov Report

Attention: Patch coverage is 95.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 62.40%. Comparing base (6e98f24) to head (9faf4bd).
Report is 9 commits behind head on master.

Files with missing lines Patch % Lines
cdci_data_analysis/flask_app/app.py 95.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #708      +/-   ##
==========================================
+ Coverage   62.33%   62.40%   +0.07%     
==========================================
  Files          50       50              
  Lines        8982     9002      +20     
==========================================
+ Hits         5599     5618      +19     
- Misses       3383     3384       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dsavchenko
Copy link
Member

So the difference from the existing file upload endpoint is that this basically acts as middleware that appends required headers, but doesn't persist the file itself?

Copy link
Member

@dsavchenko dsavchenko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, this approach will work as long as dispatcher and frontend have the same Origin (i.e. served on the same domain. Which is the case in our deployments, the dispatcher is proxied through frontend's webserver at /dispatch-data endpoint.)
So there is no need to set any additional header.

@francoismg
Copy link

Well, this approach will work as long as dispatcher and frontend have the same Origin (i.e. served on the same domain. Which is the case in our deployments, the dispatcher is proxied through frontend's webserver at /dispatch-data endpoint.) So there is no need to set any additional header.

Yes and if it were to change it would be easy to check the origin against a list of authorized origins and set the origin in the header response if there's a match

@burnout87 burnout87 merged commit eb99daa into master Sep 4, 2024
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants