LDEV-4411 Stop using collection cache for nowCache annotations were commented out so we can come back to them easilyin the future.Collection cache is not detecting changes made to entities. When a newentity is added, collection cache does not see the change.Properly tweaking concurrency strategy does not seem possible at themoment, so we just turn it off.
LDEV-4411 Native SQL queries are not cacheable by defaultThere seems to be a bug in Hibernatehttps://hibernate.atlassian.net/browse/HHH-9111There is a way to make native queries cacheable, but since there are sofew of them in LAMS, it is not worth the effort.
LDEV-4288 Prevent duplicate entries in Gradebook activity tableUnique key allows us to track situations in which duplicate entries getcreated in the table.There is no point in copying Gradebook entries on tool content copy - wenever copy live lessons, only template Learning Designs which should nothave any gradebook entries set.
LDEV-5248, LDEV-4411 Mark some collections as cacheableSimilar to query cache, the collection cache makes sense if the tablewhich collection elements map to do not change often. Each modificationto table content invalidates the given collection cache.
LDEV-5248, LDEV-4411 Mark some queries as cacheableQuery cache makes sense if tables which the query reference does notchange often. Each modification to table content invalidates the givenquery's cache. Also each set of query parameters is a different cacheentry, so if there are various parameter values the cache overhead cangenerate more load than benefit.
LDEV-5248, LDEV-4411 Add 2nd level cache to selected elementsDisplaying Assessment results is too DB-intense for multiple learners.We can enable a short-lived query cache for some entities which havemost impact on the results page. This way multiple requests can reusesame objects from cache and there is little danger of inconsistency.
LDEV-5227 Use CellUtil to set cell style propertiesExcel keeps all cell style definitions in memory and then only appliesthem to cells. Creating a new style for each cell is inefficient and hasbuilt-in limitations. CellUtil keeps track of existing cell styles andreuses existing ones when possible.