SplitScreen-Me / splitscreenme-hub

SplitScreen.Me - Public Hub 📦
https://hub.splitscreen.me
12 stars 4 forks source link

Add pagination to the API #69

Open Snailedlt opened 2 years ago

Snailedlt commented 2 years ago

Currently when using the API, we are getting all the handlers and hub information from the database.

This is not scaleable, and we will soon start to notice lag on the website.

To fix this we need to implement either pagination or caching.

Snailedlt commented 2 years ago

https://github.com/SplitScreen-Me/splitscreenme-hub/blob/7f02a9a0967b75ce64fa4d329d663644f36594e5/imports/api/Handlers/server/publications.js#L38

https://github.com/SplitScreen-Me/splitscreenme-hub/blob/7f02a9a0967b75ce64fa4d329d663644f36594e5/imports/api/Handlers/server/publications.js#L180