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

[BUG] pagination does not improve response time #532

Open
mmaeffert opened this issue Nov 20, 2024 · 5 comments
Open

[BUG] pagination does not improve response time #532

mmaeffert opened this issue Nov 20, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@mmaeffert
Copy link

Describe the bug
When using the ?limit query parameter, it does not improve the response time compared to not setting a limit at all

To Reproduce
Steps to reproduce the behavior:

  1. Create 300k twins
  2. use GET /submodels endpoint
  3. see that the response takes more than a minute
  4. use GET /submodels?limit=5 endpoint
  5. See that the response takes equally long

Expected behavior
I would expect a faster response time nearly equivalent to the set limit / number of submodels ratio

BaSyx (please complete the following information):

Additional context
I suspect that application still querries every submodel and just adds the first five to the response

@mmaeffert mmaeffert added the bug Something isn't working label Nov 20, 2024
@zhangzai123
Copy link
Contributor

Hi @mmaeffert , thank you for your report. What kind of persistence / backend do you use? InMemory or MongoDb?

@mmaeffert
Copy link
Author

I am using MongoDB.
FYI: I hosted it locally on my laptop, I suppose hosting it remotely would increase the response time even further.

@zhangzai123
Copy link
Contributor

Thank you for your fast response. We are aware of the pagination issue with MongoDB backend. We are working on this with the PR #516 . The pagination response time will be improved after this PR is merged.

@zhangzai123 zhangzai123 transferred this issue from eclipse-basyx/basyx-java-server-sdk Nov 21, 2024
@zhangzai123 zhangzai123 transferred this issue from eclipse-basyx/basyx-applications Nov 21, 2024
@mmaeffert
Copy link
Author

This is great news, thank you.
However, is there a way to disable the functionality to get every submodel alltogether? Imagine hosting this to a customer, you would not want him to keep using that endpoint

@zhangzai123
Copy link
Contributor

#516

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: In progress
Development

No branches or pull requests

2 participants