X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.db.indexing%2Fsrc%2Forg%2Fsimantics%2Fdb%2Findexing%2FIndexUtils.java;fp=bundles%2Forg.simantics.db.indexing%2Fsrc%2Forg%2Fsimantics%2Fdb%2Findexing%2FIndexUtils.java;h=0cb5d9c4d9f5a78fedb3d8038bc1785bcbc6bb88;hb=da749c56c5caad4252cd27276bf19b08f4dcb778;hp=760acd68c465578b269cdf12e164dafbb65a2516;hpb=dca20c7c10ae30a7ea50a22e15a043dc8d71af1b;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/IndexUtils.java b/bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/IndexUtils.java index 760acd68c..0cb5d9c4d 100644 --- a/bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/IndexUtils.java +++ b/bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/IndexUtils.java @@ -119,23 +119,20 @@ public class IndexUtils { } return results; } - - public static void flushIndexCaches(IProgressMonitor progress, Session session) throws Exception { - MemoryIndexing mem = MemoryIndexing.getInstance(session); - mem.flush(progress); - + public static void flushIndexCaches(IProgressMonitor monitor, Session session) throws Exception { + session.getService(IndexedRelations.class).flush(monitor, session); } - + public static List list(IProgressMonitor progress, Session session, Resource indexRoot) throws Exception { - + if(progress == null) progress = new NullProgressMonitor(); MemoryIndexing mem = MemoryIndexing.getInstance(session); Layer0X L0X = Layer0X.getInstance(session); - mem.flush(progress); - + session.getService(IndexedRelations.class).flush(progress, session); + IndexedRelationsSearcher searcher = mem.get(session, L0X.DependenciesRelation, indexRoot); List results; try {