Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,7 @@ protected void deletePetriNet(String processId, LoggedUser loggedUser, boolean f
publisher.publishEvent(new ProcessDeleteEvent(petriNet, EventPhase.PRE));
repository.deleteBy_id(petriNet.getObjectId());
evictCache(petriNet);
functionCacheService.reloadCachedGlobalFunctions(petriNet);
functionCacheService.removeCachedPetriNetFunctions(petriNet.getIdentifier());
if (petriNet.isDefaultVersion()) {
PetriNet processToMakeDefault = self.getLatestVersionByIdentifier(petriNet.getIdentifier());
if (processToMakeDefault != null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,13 @@ public void cachePetriNetFunctions(PetriNet petriNet) {
}

@Override
public void reloadCachedGlobalFunctions(String processIdentifier) {
public void removeCachedPetriNetFunctions(String processIdentifier) {
getRequiredCache(CacheMapKeys.GLOBAL_FUNCTIONS).evictIfPresent(processIdentifier);
}

@Override
public void reloadCachedGlobalFunctions(String processIdentifier) {
removeCachedPetriNetFunctions(processIdentifier);
PetriNet petriNet = petriNetService.getDefaultVersionByIdentifier(processIdentifier);
if (petriNet != null) {
cachePetriNetFunctions(petriNet);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,12 @@ public interface IFieldActionsCacheService {

void cachePetriNetFunctions(PetriNet petriNet);

void reloadCachedGlobalFunctions(String petriNetId);
void reloadCachedGlobalFunctions(String processIdentifier);

void reloadCachedGlobalFunctions(PetriNet petriNet);

void removeCachedPetriNetFunctions(String processIdentifier);

Closure getCompiledAction(Action action, boolean shouldRewriteCachedActions);

List<CachedFunction> getCachedFunctions(List<Function> functions);
Expand Down
Loading