From b45e9e5c1696a2e729dcecac0f58d16c15391770 Mon Sep 17 00:00:00 2001 From: Tuukka Lehtonen Date: Wed, 20 Nov 2019 20:34:59 +0200 Subject: [PATCH] Log throwables in DiagramViewerLoadJob instead of swallowing them gitlab #420 Change-Id: I493d7eeb0a6a13a188578fe218d68de8e195080e --- .../modeling/ui/diagramEditor/DiagramViewerLoadJob.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bundles/org.simantics.modeling.ui/src/org/simantics/modeling/ui/diagramEditor/DiagramViewerLoadJob.java b/bundles/org.simantics.modeling.ui/src/org/simantics/modeling/ui/diagramEditor/DiagramViewerLoadJob.java index 62b1d028f..decf3356c 100644 --- a/bundles/org.simantics.modeling.ui/src/org/simantics/modeling/ui/diagramEditor/DiagramViewerLoadJob.java +++ b/bundles/org.simantics.modeling.ui/src/org/simantics/modeling/ui/diagramEditor/DiagramViewerLoadJob.java @@ -24,9 +24,13 @@ import org.simantics.g2d.diagram.IDiagram; import org.simantics.modeling.ui.Activator; import org.simantics.utils.DataContainer; import org.simantics.utils.threads.ThreadUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; public class DiagramViewerLoadJob extends DatabaseJob { + private static final Logger LOGGER = LoggerFactory.getLogger(DiagramViewerLoadJob.class); + private static final boolean PROFILE = false; private DiagramViewer viewer; @@ -108,6 +112,7 @@ public class DiagramViewerLoadJob extends DatabaseJob { END(task); } catch (Throwable t) { viewer = null; + LOGGER.error("Failed to complete loading of diagram {} in the canvas thread", viewer.diagramResource, t); } } }); -- 2.47.1