BookStackApp / BookStack

A platform to create documentation/wiki content built with PHP & Laravel
https://www.bookstackapp.com/
MIT License
15.47k stars 1.94k forks source link

User Avatar Caching #5072

Open BloodyIron opened 5 months ago

BloodyIron commented 5 months ago

Describe the feature you'd like

I'm doing some performance tuning for a Bookstack instance I have on a slower environment, and I've noticed that my User Avatar (which pulls from LDAPS/AD) never gets cached by my browser (or allowed to do so), pulling from the server every time.

I think it would be beneficial for User Avatars to be cached in the user's browser upon login (whether #5066 happens or not) such that it only gets replaced in cache when the User's Avatar changes (one way or another), but otherwise stays in the browser.

This User Avatar gets requested from the server on every page load (once logged in) from what I see. While it isn't a huge payload, the wait times from the server seems to (in my case) double the loading time of the page in an avoidable way.

I'm not really seeing any downside to having this aspect cache-able by the browser, so could we please have this added at some point? Thanks! :)

Describe the benefits this would bring to existing BookStack users

All page loading once logging in would be faster due to reduced redundant requests.

Can the goal of this request already be achieved via other means?

Not that I know of.

Have you searched for an existing open/closed issue?

How long have you been using BookStack?

3 months to 1 year

Additional context

/\ ___ /\ ( o o ) \ >#< / / \ / \ ^ | | // \ / // /// /// --

BloodyIron commented 5 months ago

Ugh my kitty got squished.