Description
As discussed on the Isis mailing list [1].
Currently, there's service called QueryResultsCache [2] that allows to cache the results of an Action/method invocation.
We want to introduce this capability for Safe Actions by simply annotating them.
Current proposal is to extend the "SemanticsOf" annotation param with a new type: SemanticsOf.SAFE_AND_REQUEST_CACHED
A usage example would be:
@Override @Action(semantics = SemanticsOf.SAFE_AND_REQUEST_CACHED) public SortedSet<IESG> relevantSnpGenotypes(final IE inputElement, final Kit kit) { if (kit != null) { return kit.findAllAssociatedSNPGenotypesForInputElement(inputElement, AlgorithmImplementation.this.IESGClass); } else { return Sets.newTreeSet(); } }
[2] https://isis.apache.org/reference/services/query-results-cache.html