From e346358eaae79796b5c36fdf6455e70072bcd7ca Mon Sep 17 00:00:00 2001 From: Vladimir Krivosheev Date: Thu, 18 Jun 2020 18:49:43 +0200 Subject: [PATCH] IDEA-242605 PCE must not be logged during indexing in DomExtenderEP IDEA-243959 PCE must not be logged from XmlExtensionAdapter GitOrigin-RevId: 8441e5aa9e11189a5e731b130ed753b4d24614c1 --- .../util/concurrency/AppScheduledExecutorService.java | 5 +++-- .../src/com/intellij/util/xml/reflect/DomExtenderEP.java | 4 ++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/platform/util/src/com/intellij/util/concurrency/AppScheduledExecutorService.java b/platform/util/src/com/intellij/util/concurrency/AppScheduledExecutorService.java index 91783dce5ad0..779e9fbf75f9 100644 --- a/platform/util/src/com/intellij/util/concurrency/AppScheduledExecutorService.java +++ b/platform/util/src/com/intellij/util/concurrency/AppScheduledExecutorService.java @@ -1,8 +1,9 @@ -// Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. +// Copyright 2000-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.util.concurrency; import com.intellij.diagnostic.ThreadDumper; import com.intellij.openapi.diagnostic.Logger; +import com.intellij.openapi.progress.ProcessCanceledException; import com.intellij.openapi.util.Disposer; import com.intellij.openapi.util.LowMemoryWatcherManager; import com.intellij.util.IncorrectOperationException; @@ -135,7 +136,7 @@ public final class AppScheduledExecutorService extends SchedulingWrapper { @Override protected void afterExecute(Runnable r, Throwable t) { - if (t != null) { + if (t != null && !(t instanceof ProcessCanceledException)) { Logger.getInstance(SchedulingWrapper.class).error("Worker exited due to exception", t); } } diff --git a/xml/dom-impl/src/com/intellij/util/xml/reflect/DomExtenderEP.java b/xml/dom-impl/src/com/intellij/util/xml/reflect/DomExtenderEP.java index ea98f9c20106..d6a98916968e 100644 --- a/xml/dom-impl/src/com/intellij/util/xml/reflect/DomExtenderEP.java +++ b/xml/dom-impl/src/com/intellij/util/xml/reflect/DomExtenderEP.java @@ -7,6 +7,7 @@ import com.intellij.openapi.extensions.ExtensionPointName; import com.intellij.openapi.extensions.PluginAware; import com.intellij.openapi.extensions.PluginDescriptor; import com.intellij.openapi.extensions.RequiredElement; +import com.intellij.openapi.progress.ProcessCanceledException; import com.intellij.openapi.project.Project; import com.intellij.util.xml.DomElement; import com.intellij.util.xml.impl.DomInvocationHandler; @@ -70,6 +71,9 @@ public final class DomExtenderEP implements PluginAware { try { myExtender = project.instantiateExtensionWithPicoContainerOnlyIfNeeded(extenderClassName, pluginDescriptor); } + catch (ProcessCanceledException e) { + throw e; + } catch (Throwable e) { LOG.error(e); return registrar;