From 4f431396c9393df4a250c6b3bdea140cca652e4f Mon Sep 17 00:00:00 2001 From: Antti Villberg Date: Tue, 8 Sep 2020 22:21:10 +0300 Subject: [PATCH] Statements request is missing dec gitlab #599 Change-Id: I199dbad157fc25302e56cc49a55900632b6752b0 --- .../src/org/simantics/db/impl/graph/ReadGraphImpl.java | 8 ++++++++ .../src/org/simantics/db/impl/query/Statements.java | 1 + 2 files changed, 9 insertions(+) diff --git a/bundles/org.simantics.db.impl/src/org/simantics/db/impl/graph/ReadGraphImpl.java b/bundles/org.simantics.db.impl/src/org/simantics/db/impl/graph/ReadGraphImpl.java index 2309af764..415df9af8 100644 --- a/bundles/org.simantics.db.impl/src/org/simantics/db/impl/graph/ReadGraphImpl.java +++ b/bundles/org.simantics.db.impl/src/org/simantics/db/impl/graph/ReadGraphImpl.java @@ -6426,4 +6426,12 @@ public class ReadGraphImpl implements AsyncReadGraph { return (T) processor.getL0(); } + /* + * This method can be called to obtain a stable resource identifier for debugging + */ + public String clusterAndIndex(int r) { + if(r < 0) return ""; + return "" + processor.querySupport.getClusterId(r) + ":" + (r & 0xfff); + } + } diff --git a/bundles/org.simantics.db.impl/src/org/simantics/db/impl/query/Statements.java b/bundles/org.simantics.db.impl/src/org/simantics/db/impl/query/Statements.java index 218777413..a8c1afc0a 100644 --- a/bundles/org.simantics.db.impl/src/org/simantics/db/impl/query/Statements.java +++ b/bundles/org.simantics.db.impl/src/org/simantics/db/impl/query/Statements.java @@ -383,6 +383,7 @@ public final class Statements extends CollectionBinaryQuery @Override public void finished(ReadGraphImpl graph) throws DatabaseException { + dec(graph); } @Override -- 2.47.1