sebawagner commented on a change in pull request #67:
URL: https://github.com/apache/openmeetings/pull/67#discussion_r415142860



##########
File path: 
openmeetings-web/src/main/java/org/apache/openmeetings/web/admin/connection/ConnectionsPanel.java
##########
@@ -45,75 +51,203 @@
 import org.apache.wicket.markup.repeater.RepeatingView;
 import org.apache.wicket.model.ResourceModel;
 import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 import 
de.agilecoders.wicket.core.markup.html.bootstrap.button.BootstrapAjaxLink;
 import de.agilecoders.wicket.core.markup.html.bootstrap.button.Buttons;
 
 public class ConnectionsPanel extends AdminBasePanel {
+       
+       private static final Logger log = 
LoggerFactory.getLogger(ConnectionsPanel.class);
+       
        private static final long serialVersionUID = 1L;
        @SpringBean
        private ClientManager cm;
        @SpringBean
        private KurentoHandler scm;
        @SpringBean
+       private StreamProcessor streamProcessor;
+       @SpringBean
        private IUserManager userManager;
+       
+       /**
+        * This needs to combine two lists as we currently hold a reference to 
the KStream in two places:
+        * <ul>
+        * <li>{@link StreamProcessor#getStreams()}}</li>
+        * <li>{@link KRoom#getParticipants()}</li>
+        * </ul>
+        * Both are singletons and hold a reference to a stream list and can 
get out of sync or leak.
+        * 
+        * TODO: Investigate if we can have 1 source of truth.
+        *
+        * @return list of KStreams registered
+        */
+       public Collection<ConnectionListKStreamItem> getAllStreams() {

Review comment:
       I had a mocked unit test for this method. But when moving it into a 
WicketPanel it was getting very difficult to Mock up the wicket part and test 
it.




----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to