Startup | |||
Path | Current | Recommended | Comment |
/ | ETag | ETag | This file basically never changes but if it does we need it to be updated instantly The file itself could do with additional minification of the javascript to make it smaller. The logo is base64 encoded into the page to prevent the overhead of another network request we should review if we can optimize the file/convert it into an SVG and if inlining it is actually better than a cached request |
favicon.ico | ETag | Public / long & Etag | Currently the caching of this file is not working, it does the request every time with a 200 not 304 in Chrome but Firefox seems to correctly cache it |
app-authentication.min.js | ETag | ETag / hash | Similar to the root this file is shared across versions as it does the initial authentication and so if we change it we need it to be updated instantly We may want to refactor the login process to be more like the CET to remove the reliance on the Oidc library and have a cut down version of this file that ONLY does the authentication and then loads the correct bundle. Another option is to rename this file to the hash and each time we update it also update the reference in the root html, this means that on a "normal" request you will get 1 less request but on a change of the file (which is rare) you will get 2 |
/{version}/bundle.js | ETag | ETag | This file is currently loaded via ajax which means that the caching on it doesnt work "normally" and so it doesnt actually seem to respect the ETag caching and instead caches semi permanently. We can change the load to use script tag instead so it follows standard request caching. If we want to be able to create EBFs (that automatically update) then we need to leave this how it is currently cached so when the file is updated it will update automatically. If we change to simply doing a new release version or requiring a hard reload (as it currently is) then we could change this to be cached permanently |
/{version}/{hash}.{ext} | ETag | Public / forever | Webpack automatically renames files based on the hash of their content then updates references in the code to these new names. This means that we can move a lot of these files out of the version specific folder as they are not really version specific and have them cached permanently as they will never change. |
/{version}/{lang}.json | ETag | Public / forever / hash | This is currently loaded via ajax which means it is cached heavily. We may want to change it to be renamed to the hash of the content so we can do EBFs or leave it how it is if we don’t mind. |
api-batch/Warm() | N/A | N/A | We may want to change this to call a function that does the request to the OData batch service. This request can take a long time if the service is not spun up and may be causing requests to queue if the maximum number of concurrent requests is reached. I've not seen any issues with this but it is something to consider. |
api/Layout stuff | N/A | N/A | We should convert this call into one that works the same as the new custom translations |
We may also want to look into ETags with OData as they are possibly supported and could potentially massively reduce serialization time