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 all the objects by stepping the webservice repeatedly. #5

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

runephilosof
Copy link
Contributor

Yes, this will be slow for large lists! We might consider inserting a pager in the frontend.
But it is nicer than the current loan lists missing some titles when the limit of 50 uncached objects are hit.
opensearch limits stepValue to 50 (even though it doesn't say so in the documentation)...

Yes, this will be slow for large lists! We might consider inserting a pager in the frontend.
But it is nicer than the current loan lists missing some titles when the limit of 50 uncached objects are hit.
opensearch limits stepValue to 50 (even though it doesn't say so in the documentation)...
@kasperg
Copy link
Member

kasperg commented Feb 18, 2013

Nice catch!

Could you please add a sprinkle of code comments? It is very important that we explain the reasoning behind such workarounds.

@runephilosof
Copy link
Contributor Author

@kasperg there you go. Let me know if it still isn't spicy enough.

// opensearch is limited to 50 results per call, so iterate until all have been fetched.
$i = 0;
do {
// I query is empty, then don't do it.
Copy link
Member

Choose a reason for hiding this comment

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

Little typo I => If

@cableman
Copy link
Member

I have pulled this PR into ding2tal as i ran into the same problem, hence this PR will be part of a larger PR from ding2tal as well.

cableman added a commit that referenced this pull request Sep 26, 2014
Send smaller requests to avoid breaking opensearch.
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.

3 participants