private void clearConfigCache() { Cache workflowCache = Caching.getCacheManager(APIConstants.API_MANAGER_CACHE_MANAGER) .getCache(APIConstants.WORKFLOW_CACHE_NAME); String tenantDomain = PrivilegedCarbonContext.getThreadLocalCarbonContext().getTenantDomain(); String cacheName = tenantDomain + "_" + APIConstants.WORKFLOW_CACHE_NAME; if (workflowCache.containsKey(cacheName)) { workflowCache.remove(cacheName); } }
protected List<ValueEval> fetchValuesWithOptimisations( DsLookupParameters parameters, OperationEvaluationContext ec) { DataSetOptimisationsCache caches = (DataSetOptimisationsCache) ec.getCustomEvaluationContext().get(DataSetOptimisationsCache.class); if (caches == null) { caches = this.external.getDataSetOptimisationsCache(); } Cache<DsLookupParameters, List> cache = caches.getDataSetToDsLookupParameters(); if (cache.containsKey(parameters)) { return cache.get(parameters); } return null; }
public boolean containsKey(Object arg0) { if (localCache.containsKey(arg0)) { return true; } return cache.containsKey(arg0); }
@Override public boolean containsKey(Object key) { return map.containsKey(key) || cache.containsKey(key); }