Time to first byte

99 views
Skip to first unread message

Igor Baptista Da Costa

unread,
Sep 18, 2023, 10:39:43 PM9/18/23
to DSpace Technical Support
Hello,

there is any thing to do in DSpace (beside all stuff in performace tuning documentation, hardware upgrade and turn on server side render) to reduce the time to first byte in DSpace 7x frontend ? This issue only happens with the frontend, the backend url have a low TTFB, but the frontend TTFB is very high.

Regards

Max Nuding

unread,
Sep 19, 2023, 7:28:00 AM9/19/23
to dspac...@googlegroups.com
Hello,

enabling server side rendering actually *increases* TTFB for the
frontend, because the server waits until it has finished rendering
before it sends a response.

You can use more powerful servers for the frontend (faster CPU and/or
more cores so you can increase the amount of PM2 threads), but TTFB will
still be high. Caching frequently accessed pages helps a lot, either
with DSpace built-in caching or by configuring apache or varnish. We've
made great experiences with the latter!

We've disabled server side rendering for logged-in users (but that does
require code changes), because that is faster for them and less load on
our frontend server for us.


Best regards,

Max Nuding

On 19.09.23 04:39, Igor Baptista Da Costa wrote:
> Hello,
>
> there is any thing to do in DSpace (beside all stuff in performace
> tuning documentation
> <https://wiki.lyrasis.org/display/DSDOC7x/Performance+Tuning+DSpace>, hardware
> upgrade and turn on server side render) to reduce the time to first
> byte in DSpace 7x frontend ? This issue only happens with the
> frontend, the backend url have a low TTFB, but the frontend TTFB is
> very high.
>
> Regards
> --
> All messages to this mailing list should adhere to the Code of
> Conduct: https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx

DSpace Technical Support

unread,
Sep 22, 2023, 11:32:13 AM9/22/23
to DSpace Technical Support
Hi all,

Please be aware that disabling server-side rendering (SSR) for all users is never recommended because it will guarantee that your site cannot be indexed by Google Scholar.  This is why we have purposely made it difficult to disable SSR after consulting with the Google Scholar team.  See our SEO guide: https://wiki.lyrasis.org/display/DSDOC7x/Search+Engine+Optimization

As noted above, we do offer a way to *cache* server-side rendered pages in memory.  This can be used to achieve a lower TTFB for frequently accessed pages, as a cached page is returned instead of re-rendering the page on every request.  See the Performance Tuning Guide section here: https://wiki.lyrasis.org/display/DSDOC7x/Performance+Tuning+DSpace#PerformanceTuningDSpace-Turnon(orincrease)cachingofServer-SideRenderedpages   This caching can be configured to cache large numbers of pages if you wish to do so, but keep in mind the more you cache, the more memory it uses... as all the cached pages are currently stored in memory.

Tim

Reply all
Reply to author
Forward
0 new messages