From 318923234272a5551214160e8a1c89d1d918fc34 Mon Sep 17 00:00:00 2001 From: gmyasoedov Date: Fri, 13 Dec 2024 21:48:09 +0300 Subject: [PATCH] chore: remove unused code --- .../server/GServerRemoteProcessSupport.java | 88 ------ .../gmaven/server/MavenServerCmdState.java | 250 ------------------ .../gmaven/project/MavenProjectResolver.kt | 10 +- .../GDependencyAnalyzerContributor.kt | 17 +- .../project/process/BaseMavenCommandLine.kt | 17 +- .../gmaven/project/task/MavenTaskManager.kt | 19 +- 6 files changed, 21 insertions(+), 380 deletions(-) delete mode 100644 gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/GServerRemoteProcessSupport.java delete mode 100644 gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/MavenServerCmdState.java diff --git a/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/GServerRemoteProcessSupport.java b/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/GServerRemoteProcessSupport.java deleted file mode 100644 index 9b798187..00000000 --- a/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/GServerRemoteProcessSupport.java +++ /dev/null @@ -1,88 +0,0 @@ -package ru.rzn.gmyasoedov.gmaven.server; - -import com.intellij.execution.Executor; -import com.intellij.execution.configurations.RunProfileState; -import com.intellij.execution.process.ProcessEvent; -import com.intellij.execution.rmi.RemoteProcessSupport; -import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskId; -import com.intellij.openapi.util.Key; -import com.intellij.openapi.util.registry.Registry; -import com.intellij.openapi.util.text.StringUtil; -import com.intellij.util.execution.ParametersListUtil; -import org.jetbrains.annotations.NotNull; -import ru.rzn.gmyasoedov.gmaven.settings.MavenExecutionWorkspace; -import ru.rzn.gmyasoedov.serverapi.GMavenServer; - -import java.nio.file.Path; -import java.util.Collections; -import java.util.List; - -import static ru.rzn.gmyasoedov.gmaven.project.wrapper.MvnDotProperties.getJvmConfig; - -public class GServerRemoteProcessSupport extends RemoteProcessSupport { - private final @NotNull GServerRequest request; - private final List jvmConfigOptions; - private final Path workingDirectory; - private final boolean isImport; - - public GServerRemoteProcessSupport(@NotNull GServerRequest request) { - this(request, true); - } - - public GServerRemoteProcessSupport(@NotNull GServerRequest request, boolean isImport) { - super(GMavenServer.class); - this.isImport = isImport; - this.request = request; - this.workingDirectory = getWorkingDirectory(request); - this.jvmConfigOptions = getJvmConfigOptions(this.workingDirectory); - } - - public static List getJvmConfigOptions(Path workingDirectory) { - String jvmConfig = getJvmConfig(workingDirectory); - return StringUtil.isEmpty(jvmConfig) - ? Collections.emptyList() : ParametersListUtil.parse(jvmConfig, true, true); - } - - @Override - protected void fireModificationCountChanged() { - } - - @Override - protected String getName(@NotNull Object file) { - return "GServerRemoteProcessSupport"; - } - - public ExternalSystemTaskId getId() { - return request.getTaskId(); - } - - @Override - protected void logText(@NotNull Object configuration, - @NotNull ProcessEvent event, - @NotNull Key outputType) { - String text = StringUtil.notNullize(event.getText()); - if (Registry.is("gmaven.server.debug")) { - System.out.println(text); - } - if (request.getListener() != null) { - request.getListener().onTaskOutput(request.getTaskId(), text, true); - } - } - - @Override - protected RunProfileState getRunProfileState(@NotNull Object o, - @NotNull Object configuration, - @NotNull Executor executor) { - return new MavenServerCmdState(request, workingDirectory, jvmConfigOptions, isImport); - } - - private static Path getWorkingDirectory(@NotNull GServerRequest request) { - MavenExecutionWorkspace workspace = request.getSettings().getExecutionWorkspace(); - if (workspace.getMultiModuleProjectDirectory() != null) { - return Path.of(workspace.getMultiModuleProjectDirectory()); - } else { - return request.getProjectPath().toFile().isDirectory() - ? request.getProjectPath() : request.getProjectPath().getParent(); - } - } -} \ No newline at end of file diff --git a/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/MavenServerCmdState.java b/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/MavenServerCmdState.java deleted file mode 100644 index 9914d9d0..00000000 --- a/gmaven/src/main/java/ru/rzn/gmyasoedov/gmaven/server/MavenServerCmdState.java +++ /dev/null @@ -1,250 +0,0 @@ -package ru.rzn.gmyasoedov.gmaven.server; - -import com.intellij.execution.DefaultExecutionResult; -import com.intellij.execution.ExecutionException; -import com.intellij.execution.ExecutionResult; -import com.intellij.execution.Executor; -import com.intellij.execution.configurations.CommandLineState; -import com.intellij.execution.configurations.GeneralCommandLine; -import com.intellij.execution.configurations.ParametersList; -import com.intellij.execution.configurations.SimpleJavaParameters; -import com.intellij.execution.process.OSProcessHandler; -import com.intellij.execution.process.ProcessHandler; -import com.intellij.execution.rmi.RemoteServer; -import com.intellij.execution.runners.ProgramRunner; -import com.intellij.openapi.util.registry.Registry; -import com.intellij.openapi.util.text.StringUtil; -import com.intellij.openapi.util.text.StringUtilRt; -import com.intellij.util.PathUtil; -import com.intellij.util.net.NetUtils; -import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; -import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.MavenCompilerFullImportPlugin; -import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.MavenFullImportPlugin; -import ru.rzn.gmyasoedov.gmaven.utils.MavenLog; -import ru.rzn.gmyasoedov.serverapi.GMavenServer; - -import java.io.IOException; -import java.nio.file.Files; -import java.nio.file.Path; -import java.util.*; -import java.util.stream.Stream; - -import static java.lang.String.format; -import static ru.rzn.gmyasoedov.serverapi.GMavenServer.*; - -public class MavenServerCmdState extends CommandLineState { - private static final String DEFAULT_XMX = "-Xmx768m"; - - private final @NotNull GServerRequest request; - private final Path mavenPath; - private final Path workingDirectory; - private final List jvmConfigOptions; - - private final Integer debugPort; - private final boolean isImport; - - public MavenServerCmdState(@NotNull GServerRequest request, - @NotNull Path workingDirectory, - @NotNull List jvmConfigOptions, - boolean isImport) { - super(null); - this.request = request; - this.mavenPath = request.getMavenPath(); - this.workingDirectory = workingDirectory; - this.jvmConfigOptions = jvmConfigOptions; - this.debugPort = getDebugPort(); - this.isImport = isImport; - } - - protected SimpleJavaParameters createJavaParameters() { - final SimpleJavaParameters params = new SimpleJavaParameters(); - params.setJdk(request.getSdk()); - params.setWorkingDirectory(workingDirectory.toFile()); - setupDebugParam(params); - setupClasspath(params); - setupGmavenPluginsProperty(params); - processVmOptions(jvmConfigOptions, params); - setupMavenOpts(params); - params.setMainClass("ru.rzn.gmyasoedov.gmaven.server.RemoteGMavenServer"); - return params; - } - - private void setupGmavenPluginsProperty(SimpleJavaParameters params) { - List extensionList = MavenFullImportPlugin.EP_NAME.getExtensionList(); - List pluginsForImport = new ArrayList<>(extensionList.size()); - List pluginsForResolve = new ArrayList<>(1); - for (MavenFullImportPlugin plugin : extensionList) { - pluginsForImport.add(plugin.getKey()); - if (plugin instanceof MavenCompilerFullImportPlugin) { - if (((MavenCompilerFullImportPlugin) plugin).resolvePlugin()) { - pluginsForResolve.add(plugin.getArtifactId()); - } - String annotationPath = ((MavenCompilerFullImportPlugin) plugin).getAnnotationProcessorTagName(); - if (StringUtilRt.isEmpty(annotationPath)) continue; - params.getVMParametersList() - .addProperty(format(GMAVEN_PLUGIN_ANNOTATION_PROCESSOR, plugin.getArtifactId()), annotationPath); - } - } - - if (!pluginsForImport.isEmpty()) { - params.getVMParametersList().addProperty(GMAVEN_PLUGINS, String.join(";", pluginsForImport)); - } - if (!pluginsForResolve.isEmpty()) { - params.getVMParametersList().addProperty(GMAVEN_PLUGINS_RESOLVE, String.join(",", pluginsForResolve)); - } - } - - private void setupClasspath(SimpleJavaParameters params) { - String mavenServerJarPathString; - String mavenExtClassesJarPathString; - try { - mavenServerJarPathString = PathUtil - .getJarPathForClass(Class.forName("ru.rzn.gmyasoedov.gmaven.server.RemoteGMavenServer")); - mavenExtClassesJarPathString = PathUtil - .getJarPathForClass(Class.forName("ru.rzn.gmyasoedov.event.handler.EventSpyResultHolder")); - } catch (ClassNotFoundException e) { - throw new RuntimeException(e); - } - String mavenServerApiJarPathString = PathUtil.getJarPathForClass(GMavenServer.class); - params.getClassPath().add(mavenServerJarPathString); - params.getClassPath().add(mavenServerApiJarPathString); - params.getClassPath().add(getPlexusClassWorlds(mavenPath)); - params.getClassPath().addAll(collectIdeaRTLibraries()); - - params.getVMParametersList().addProperty(MAVEN_EXT_CLASS_PATH_PROPERTY, mavenExtClassesJarPathString); - params.getVMParametersList().addProperty(GMAVEN_HOME, mavenPath.toAbsolutePath().toString()); - request.getSettings().getEnv().forEach((k, v) -> addProperty(params, k, v)); - } - - private static void addProperty(SimpleJavaParameters params, String k, String v) { - if (v != null) { - params.getVMParametersList().addProperty(k, v); - } else { - params.getVMParametersList().addProperty(k); - } - } - - private void processVmOptions(List jvmConfigOptions, SimpleJavaParameters params) { - boolean hasXmxProperty = false; - boolean hasXmsProperty = false; - List vmOptions = new ArrayList<>(jvmConfigOptions); - vmOptions.addAll(request.getSettings().getJvmArguments()); - for (String param : vmOptions) { - if (param.startsWith("-Xmx")) { - hasXmxProperty = true; - } - if (param.startsWith("-Xms")) { - hasXmsProperty = true; - } - if (isImport && Registry.is("gmaven.vm.remove.javaagent") && param.startsWith("-javaagent")) { - continue; - } - params.getVMParametersList().add(param); - } - if (!hasXmxProperty && !hasXmsProperty - && (request.getSettings().isNonRecursive()) || request.getInstallGMavenPlugin()) { - params.getVMParametersList().add(DEFAULT_XMX); - } - } - - private void setupDebugParam(SimpleJavaParameters params) { - if (debugPort != null) { - params.getVMParametersList().addProperty(SERVER_DEBUG_PROPERTY, Boolean.TRUE.toString()); - params.getVMParametersList().addParametersString( - "-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=*:" + debugPort); - } - } - - public static void setupMavenOpts(@NotNull SimpleJavaParameters params) { - String mavenOpts = System.getenv("MAVEN_OPTS"); - Map mavenOptsMap; - if (StringUtil.isNotEmpty(mavenOpts)) { - ParametersList mavenOptsList = new ParametersList(); - mavenOptsList.addParametersString(mavenOpts); - mavenOptsMap = mavenOptsList.getProperties(); - } else { - mavenOptsMap = new HashMap<>(); - } - configureSslRelatedOptions(mavenOptsMap); - mavenOptsMap.put("java.awt.headless", "true"); - - for (Map.Entry each : mavenOptsMap.entrySet()) { - params.getVMParametersList().defineProperty(each.getKey(), each.getValue()); - } - } - - private static void configureSslRelatedOptions(Map defs) { - for (Map.Entry each : System.getProperties().entrySet()) { - Object key = each.getKey(); - Object value = each.getValue(); - if (key instanceof String && value instanceof String && ((String) key).startsWith("javax.net.ssl")) { - defs.put((String) key, (String) value); - } - } - } - - @Nullable - public static Integer getDebugPort() { - if (Registry.is("gmaven.server.debug")) { - try { - return NetUtils.findAvailableSocketPort(); - } catch (IOException e) { - MavenLog.LOG.warn(e); - } - } - return null; - } - - protected @NotNull List collectIdeaRTLibraries() { - return new ArrayList<>(Set.of( - PathUtil.getJarPathForClass(RemoteServer.class),//remote-util-rt - PathUtil.getJarPathForClass(NotNull.class)));//annotations-java5 - } - - private static @NotNull String getPlexusClassWorlds(@NotNull Path mavenPath) { - Path mavenBootPath = mavenPath.resolve("boot"); - String bootJarPrefix = Registry.stringValue("gmaven.boot.jar.prefix"); - try { - Optional bootJarPath; - try (Stream files = Files.walk(mavenBootPath, 1)) { - bootJarPath = files.filter(f -> isBootJar(f, bootJarPrefix)) - .map(Path::toString) - .findFirst(); - } - if (bootJarPath.isEmpty()) { - try (Stream files = Files.walk(mavenPath)) { - bootJarPath = files.filter(f -> isBootJar(f, bootJarPrefix)) - .map(Path::toString) - .findFirst(); - } - } - return bootJarPath.orElseThrow(); - } catch (IOException e) { - throw new RuntimeException("maven boot jar not found in: " + mavenPath, e); - } - } - - private static boolean isBootJar(Path f, String bootJarPrefix) { - String name = f.getFileName().toString(); - return name.startsWith(bootJarPrefix) && name.endsWith(".jar"); - } - - @NotNull - @Override - public ExecutionResult execute(@NotNull Executor executor, @NotNull ProgramRunner runner) - throws ExecutionException { - ProcessHandler processHandler = startProcess(); - return new DefaultExecutionResult(processHandler); - } - - @Override - @NotNull - protected ProcessHandler startProcess() throws ExecutionException { - SimpleJavaParameters params = createJavaParameters(); - GeneralCommandLine commandLine = params.toCommandLine(); - OSProcessHandler processHandler = new OSProcessHandler.Silent(commandLine); - processHandler.setShouldDestroyProcessRecursively(false); - return processHandler; - } -} diff --git a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/MavenProjectResolver.kt b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/MavenProjectResolver.kt index f597cb90..469908d1 100644 --- a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/MavenProjectResolver.kt +++ b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/MavenProjectResolver.kt @@ -22,7 +22,6 @@ import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.CompilerData import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.MavenFullImportPlugin import ru.rzn.gmyasoedov.gmaven.project.externalSystem.model.SourceSetData import ru.rzn.gmyasoedov.gmaven.project.policy.ReadProjectResolverPolicy -import ru.rzn.gmyasoedov.gmaven.server.GServerRemoteProcessSupport import ru.rzn.gmyasoedov.gmaven.server.GServerRequest import ru.rzn.gmyasoedov.gmaven.server.getProjectModel import ru.rzn.gmyasoedov.gmaven.settings.MavenExecutionSettings @@ -40,7 +39,7 @@ import kotlin.io.path.absolutePathString class MavenProjectResolver : ExternalSystemProjectResolver { - private val cancellationMap = ConcurrentHashMap() + private val cancellationMap = ConcurrentHashMap() override fun cancelTask(id: ExternalSystemTaskId, listener: ExternalSystemTaskNotificationListener): Boolean { cancelTask(id, cancellationMap) @@ -187,11 +186,8 @@ class MavenProjectResolver : ExternalSystemProjectResolver) { - when (val remove = cancellationMap.remove(id)) { - is GServerRemoteProcessSupport -> remove.stopAll() - is OSProcessHandler -> remove.destroyProcess() - } + fun cancelTask(id: ExternalSystemTaskId, cancellationMap: MutableMap) { + cancellationMap.remove(id)?.destroyProcess() } } } \ No newline at end of file diff --git a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/dependencyanalyzer/GDependencyAnalyzerContributor.kt b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/dependencyanalyzer/GDependencyAnalyzerContributor.kt index 1bff892f..20a78492 100644 --- a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/dependencyanalyzer/GDependencyAnalyzerContributor.kt +++ b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/dependencyanalyzer/GDependencyAnalyzerContributor.kt @@ -10,11 +10,7 @@ import com.intellij.openapi.externalSystem.model.ExternalProjectInfo import com.intellij.openapi.externalSystem.model.ProjectKeys import com.intellij.openapi.externalSystem.model.execution.ExternalSystemTaskExecutionSettings import com.intellij.openapi.externalSystem.model.project.ModuleData -import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskId -import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskNotificationListener -import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskType import com.intellij.openapi.externalSystem.service.execution.ProgressExecutionMode -import com.intellij.openapi.externalSystem.service.notification.ExternalSystemProgressNotificationManager import com.intellij.openapi.externalSystem.service.project.ProjectDataManager import com.intellij.openapi.externalSystem.task.TaskCallback import com.intellij.openapi.externalSystem.util.ExternalSystemApiUtil @@ -52,18 +48,7 @@ class GDependencyAnalyzerContributor(private val project: Project) : DependencyA private var moduleMapByProject: Map>? = null private val dependencyTreeByProject: MutableMap> = ConcurrentHashMap() - override fun whenDataChanged(listener: () -> Unit, parentDisposable: Disposable) { - val progressManager = ExternalSystemProgressNotificationManager.getInstance() - progressManager.addNotificationListener(object : ExternalSystemTaskNotificationListener { - override fun onEnd(id: ExternalSystemTaskId) { - if (id.type != ExternalSystemTaskType.RESOLVE_PROJECT) return - if (id.projectSystemId != SYSTEM_ID) return - moduleMapByProject = null - dependencyTreeByProject.clear() - listener() - } - }, parentDisposable) - } + override fun whenDataChanged(listener: () -> Unit, parentDisposable: Disposable) {} override fun getProjects(): List { val moduleMap = getModuleMap() diff --git a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/process/BaseMavenCommandLine.kt b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/process/BaseMavenCommandLine.kt index 84b7d1f7..554b3616 100644 --- a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/process/BaseMavenCommandLine.kt +++ b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/process/BaseMavenCommandLine.kt @@ -4,12 +4,14 @@ import com.intellij.execution.configurations.GeneralCommandLine import com.intellij.openapi.util.SystemInfo import com.intellij.openapi.util.registry.Registry import com.intellij.util.execution.ParametersListUtil +import com.intellij.util.net.NetUtils import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.MavenCompilerFullImportPlugin import ru.rzn.gmyasoedov.gmaven.extensionpoints.plugin.MavenFullImportPlugin import ru.rzn.gmyasoedov.gmaven.server.GServerRequest -import ru.rzn.gmyasoedov.gmaven.server.MavenServerCmdState import ru.rzn.gmyasoedov.gmaven.util.MavenPathUtil.getExtClassesJarPathString +import ru.rzn.gmyasoedov.gmaven.utils.MavenLog import ru.rzn.gmyasoedov.serverapi.GMavenServer +import java.io.IOException import java.nio.file.Path import kotlin.io.path.absolutePathString import kotlin.io.path.exists @@ -99,7 +101,7 @@ class BaseMavenCommandLine(private val request: GServerRequest, private val isIm if (Registry.`is`("gmaven.process.jsonPrettyPrinting")) { commandLine.parametersList.addProperty("jsonPrettyPrinting", "true") } - val debugPort = MavenServerCmdState.getDebugPort() ?: return + val debugPort = getDebugPort() ?: return commandLine.parametersList.addProperty("jsonPrettyPrinting", "true") commandLine.addParameter("-Xdebug") commandLine.addParameter("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=*:$debugPort") @@ -136,5 +138,16 @@ class BaseMavenCommandLine(private val request: GServerRequest, private val isIm } private fun createListParameter(plugins: MutableList) = plugins.joinToString(",") + + private fun getDebugPort(): Int? { + if (Registry.`is`("gmaven.server.debug")) { + try { + return NetUtils.findAvailableSocketPort() + } catch (e: IOException) { + MavenLog.LOG.warn(e) + } + } + return null + } } } \ No newline at end of file diff --git a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/task/MavenTaskManager.kt b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/task/MavenTaskManager.kt index ed06d1ac..75a9d4a1 100644 --- a/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/task/MavenTaskManager.kt +++ b/gmaven/src/main/kotlin/ru/rzn/gmyasoedov/gmaven/project/task/MavenTaskManager.kt @@ -1,8 +1,6 @@ package ru.rzn.gmyasoedov.gmaven.project.task -import com.intellij.ide.actions.ShowLogAction -import com.intellij.notification.NotificationType.WARNING -import com.intellij.openapi.actionSystem.ActionManager +import com.intellij.execution.process.OSProcessHandler import com.intellij.openapi.externalSystem.model.ExternalSystemException import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskId import com.intellij.openapi.externalSystem.model.task.ExternalSystemTaskNotificationListener @@ -11,20 +9,17 @@ import com.intellij.openapi.externalSystem.service.execution.ProjectJdkNotFoundE import com.intellij.openapi.externalSystem.task.ExternalSystemTaskManager import com.intellij.openapi.util.registry.Registry import org.jetbrains.annotations.VisibleForTesting -import ru.rzn.gmyasoedov.gmaven.bundle.GBundle.message import ru.rzn.gmyasoedov.gmaven.project.MavenProjectResolver import ru.rzn.gmyasoedov.gmaven.project.getMavenHome import ru.rzn.gmyasoedov.gmaven.server.GServerRequest import ru.rzn.gmyasoedov.gmaven.server.runTasks import ru.rzn.gmyasoedov.gmaven.settings.MavenExecutionSettings -import ru.rzn.gmyasoedov.gmaven.util.GMavenNotification -import ru.rzn.gmyasoedov.gmaven.utils.MavenLog import java.nio.file.Path import java.util.* import java.util.concurrent.ConcurrentHashMap class MavenTaskManager : ExternalSystemTaskManager { - private val cancellationMap = ConcurrentHashMap() + private val cancellationMap = ConcurrentHashMap() override fun executeTasks( id: ExternalSystemTaskId, @@ -67,16 +62,6 @@ class MavenTaskManager : ExternalSystemTaskManager { return true } - private fun processErrorAndShowNotify(e: Throwable) { - MavenLog.LOG.warn(e) - GMavenNotification.createNotification( - message("gmaven.mvnd.notification.title"), - message("gmaven.mvnd.notification.error"), - WARNING, - listOf(ActionManager.getInstance().getAction("OpenLog"), ShowLogAction.notificationAction()) - ) - } - @VisibleForTesting fun prepareTaskOrder(taskNames: List): List { if (taskNames.size < 2) return taskNames