From 76f0fe7be81591ffced427e8c693b41e5c6429c0 Mon Sep 17 00:00:00 2001 From: Patrick Tasse Date: Thu, 2 Nov 2023 15:00:19 -0400 Subject: [PATCH] releng: Fix SLF4J logging for staging platform The bundle slf4j.simple is no longer a fragment of slf4j.api like org.slf4j.binding.simple was in SLF4J 1.7.30. As a consequence, the fragment org.eclipse.tracecompass.slf4j.binding.simple.properties must set slf4j.simple as its Fragment-Host because it is this plugin's class loader that will attempt to find the simplelogger.properties resource. In order for org.slf4j.simple.SimpleServiceProvider to be found by the ServiceLoader, plugins org.apache.aries.spifly.dynamic.bundle and slf4j.simple must have their autoStart set to "true" in the swtbot-test-plugin profile. For manual testing the user will need to manually set the Auto-Start to "true" for these two plugins in the JUnit Plug-in Test Run/Debug Configuration in Eclipse. Change-Id: I4a325248c1c5952e41fb0e4c3fb1d8163a631e90 Signed-off-by: Patrick Tasse Reviewed-on: https://git.eclipse.org/r/c/tracecompass/org.eclipse.tracecompass/+/205286 Tested-by: Trace Compass Bot Tested-by: Matthew Khouzam Reviewed-by: Matthew Khouzam --- pom.xml | 12 ++++++++++++ .../staging/MANIFEST.MF | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 9ea19ec1ed..45b6a3c619 100644 --- a/pom.xml +++ b/pom.xml @@ -285,6 +285,18 @@ org.eclipse.tycho tycho-surefire-plugin + + + org.apache.aries.spifly.dynamic.bundle + 2 + true + + + ${slf4j-bundle} + 2 + true + + true false diff --git a/releng/org.eclipse.tracecompass.slf4j.binding.simple.properties/staging/MANIFEST.MF b/releng/org.eclipse.tracecompass.slf4j.binding.simple.properties/staging/MANIFEST.MF index 1e7bd372d8..848228823c 100644 --- a/releng/org.eclipse.tracecompass.slf4j.binding.simple.properties/staging/MANIFEST.MF +++ b/releng/org.eclipse.tracecompass.slf4j.binding.simple.properties/staging/MANIFEST.MF @@ -4,6 +4,6 @@ Bundle-Name: Trace Compass SLF4J Simple Binding Properties Fragment Plug-in Bundle-SymbolicName: org.eclipse.tracecompass.slf4j.binding.simple.properties Bundle-Version: 1.0.1.qualifier Bundle-Vendor: Eclipse Trace Compass -Fragment-Host: slf4j.api +Fragment-Host: slf4j.simple Automatic-Module-Name: org.eclipse.tracecompass.slf4j.binding.simple.properties Bundle-RequiredExecutionEnvironment: JavaSE-11