Replies: 7 comments 5 replies
-
What's your thinking on why a JavaScript driven fetch would scale better than standard HTTP requests? |
Beta Was this translation helpful? Give feedback.
-
With a JS fetch, the returned object can be all (or some) of the developers and their attributes. For example,
Then we can iterate through on the client side which will speed things up and we could give some CSS flare on load (not JS specific required for this at all but an opportunity). Additionally, we can use that data for all the filtering and pagination with JS. Currently, the initial devs grab, pagination, sorting, filters, etc are all server sided rendered and we could prevent each one of those calls to the server. |
Beta Was this translation helpful? Give feedback.
-
Is
I'm not sure I follow, there's only a single call to the server right now. What are you proposing moving to JavaScript would avoid? |
Beta Was this translation helpful? Give feedback.
-
The server isn't slow today, no. But as for scaling the platform then this could result in a high amount of calls and server resources. I'm not 100% sure I am going to be able to explain this. But I'll try. Your active record calls are going to increase as your views increase. This is because every time someone visits the What I am proposing is that if we made that page SPA-like, then the additional navigations of filters & page views will result in near zero server sided resources being called as the page views increase. The whole I can probably code this in order to show it better than I can explain it... lol |
Beta Was this translation helpful? Give feedback.
-
Even if this ends up being much faster down the road I'm hesitant to add SPA-like pages now (or ever) for a few reasons:
But hey, prove me wrong! Seed your local database with 10,000 developer profiles and run some filters. How much slower is that than with the current count? How quickly does it get out of hand? |
Beta Was this translation helpful? Give feedback.
-
Sounds good. I'll do some testing and let you know of any gains I find. |
Beta Was this translation helpful? Give feedback.
-
My thinking is that the
/developers
search page could be completely JS driven with a fetch request to an internal API. That way the filters can be JS driven and not a REST call each time.This should improve scalability as users, in-platform devs, & filter features increase.
Any thoughts on this?
Beta Was this translation helpful? Give feedback.
All reactions