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

[ENH] Server embedder: use queue, handle unsuccessful requests at the end #5835

Merged
merged 2 commits into from
Feb 25, 2022

Conversation

PrimozGodec
Copy link
Contributor

Issue

Server embedder retries sending unsuccessful requests immediately after the fauliture.
Since it is possible that the server needs longer to compute (the request was unsuccessful because of timeout) the results (the server will cache the result when finished) it is better to retry later (there is a higher chance that the server already finished processing).

Description of changes

Implemented described behaviour. To achieve it I needed to change embedders to use Queue instead of just gathering the results.

Includes
  • Code changes
  • Tests
  • Documentation

@codecov
Copy link

codecov bot commented Feb 8, 2022

Codecov Report

Merging #5835 (f3a9dde) into master (ba151c8) will increase coverage by 0.01%.
The diff coverage is 98.38%.

@@            Coverage Diff             @@
##           master    #5835      +/-   ##
==========================================
+ Coverage   86.24%   86.25%   +0.01%     
==========================================
  Files         315      315              
  Lines       66672    66695      +23     
==========================================
+ Hits        57503    57531      +28     
+ Misses       9169     9164       -5     

@PrimozGodec PrimozGodec force-pushed the embedders-change-order branch 2 times, most recently from a9bafc3 to 77db719 Compare February 9, 2022 10:22
@PrimozGodec PrimozGodec marked this pull request as ready for review February 9, 2022 10:56
@PrimozGodec PrimozGodec changed the title Server embedder: use queue, handle unsuccessful requests at the end [ENH] Server embedder: use queue, handle unsuccessful requests at the end Feb 9, 2022
@markotoplak
Copy link
Member

markotoplak commented Feb 21, 2022

@PrimozGodec, I like the concept and structuring. I left you some minor comments and suggestions.

In the end, I think I found:

  • 2 3 imaginary serious bugs, where I was only complaining because I did not understand the code properly.
  • 1 bug that I still believe in. :)

@PrimozGodec
Copy link
Contributor Author

PrimozGodec commented Feb 23, 2022

@markotoplak it should be ready now

@markotoplak markotoplak merged commit b8928c2 into biolab:master Feb 25, 2022
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

Successfully merging this pull request may close these issues.

2 participants