kwin commented on a change in pull request #1: [SLING-8246]Fix server side test 
hang with repeat "Waiting for the following bund…
URL: 
https://github.com/apache/sling-org-apache-sling-junit-core/pull/1#discussion_r363089758
 
 

 ##########
 File path: 
src/main/java/org/apache/sling/junit/impl/servlet/JUnitResultRenderer.java
 ##########
 @@ -23,21 +23,24 @@
 
 import javax.servlet.http.HttpServletResponse;
 
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Service;
 import org.apache.sling.junit.Renderer;
 import org.apache.sling.junit.RendererFactory;
 import org.apache.sling.junit.TestSelector;
 import org.junit.runner.Result;
 import org.junit.runner.notification.RunListener;
+import org.osgi.service.component.annotations.Component;
+import org.osgi.service.component.annotations.ServiceScope;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 /** Renderer for Sling JUnit server-side testing, which
  *  renders the serialized JUnit Result object.
  */
-@Component
-@Service
+@Component(
+    service = Renderer.class,
+    immediate = false,
+    scope = ServiceScope.BUNDLE
 
 Review comment:
   scope=bundle changes the semantics, IMHO a global singleton should be fine 
(which is the default scope)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to