use of org.red5.server.api.IConnection in project bigbluebutton by bigbluebutton.
the class Application method streamPublishStart.
@Override
public void streamPublishStart(IBroadcastStream stream) {
String clientId = Red5.getConnectionLocal().getClient().getId();
String userid = getUserId();
String username = getUsername();
log.debug("{} has started publishing stream [{}]", username + "[uid=" + userid + "][clientid=" + clientId + "]", stream.getPublishedName());
System.out.println("streamPublishStart: " + stream.getPublishedName());
IConnection conn = Red5.getConnectionLocal();
String peerId = (String) conn.getAttribute("VOICE_CONF_PEER");
if (peerId != null) {
super.streamPublishStart(stream);
sipPeerManager.startTalkStream(peerId, clientId, stream, conn.getScope());
// recordStream(stream);
}
}
use of org.red5.server.api.IConnection in project bigbluebutton by bigbluebutton.
the class Application method streamBroadcastClose.
@Override
public void streamBroadcastClose(IBroadcastStream stream) {
String clientId = Red5.getConnectionLocal().getClient().getId();
String userid = getUserId();
String username = getUsername();
log.debug("{} has stopped publishing stream [{}]", username + "[uid=" + userid + "][clientid=" + clientId + "]", stream.getPublishedName());
IConnection conn = Red5.getConnectionLocal();
String peerId = (String) conn.getAttribute("VOICE_CONF_PEER");
if (peerId != null) {
sipPeerManager.stopTalkStream(peerId, clientId, stream, conn.getScope());
super.streamBroadcastClose(stream);
}
}
use of org.red5.server.api.IConnection in project bigbluebutton by bigbluebutton.
the class SipPhoneApplication method streamPublishStart.
public void streamPublishStart(IBroadcastStream stream) {
loginfo("Red5SIP Stream publish start: " + stream.getPublishedName());
IConnection current = Red5.getConnectionLocal();
}
use of org.red5.server.api.IConnection in project bigbluebutton by bigbluebutton.
the class SipPhoneApplication method appConnect.
@Override
public boolean appConnect(IConnection conn, Object[] params) {
IServiceCapableConnection service = (IServiceCapableConnection) conn;
loginfo("Red5SIP Client connected " + conn.getClient().getId() + " service " + service);
return true;
}
use of org.red5.server.api.IConnection in project bigbluebutton by bigbluebutton.
the class VoiceConferenceApplication method login.
private void login(String obproxy, String uid, String phone, String username, String password, String realm, String proxy, int sipport, int rtpport) {
System.out.println("Red5SIP login " + uid);
IConnection conn = Red5.getConnectionLocal();
IServiceCapableConnection service = (IServiceCapableConnection) conn;
ConnectionClientMethodInvoker rtmpConnection = new ConnectionClientMethodInvoker(service, conn.getScope());
String userid = getSipUserId();
sipManager.createSipUser(userid, rtmpConnection, sipport, rtpport);
sipManager.login(userid, obproxy, phone, username, password, realm, proxy);
}
Aggregations