Waiting for host after admitToMeeting is called for participant waiting to join

Description
waiting for host after admitToMeeting is called for participant waiting to join.

Which version?
zoom-sdk-android-5.4.3.613

To Reproduce(If applicable)
Steps to reproduce the behavior:

  1. Go to ‘Using android sdk first enable waiting room, start meeting with params.’
  2. Share invite to client and let client join waiting room.
  3. onWatingRoomUserJoin call admitToMeeting for user.
  4. admitToMeeting error: SDKERR_SUCCESS but client is still waiting to join in waiting room.

Screenshots

Smartphone (please complete the following information):

  • Device: [OnePlus6]
  • OS: [Android 10]
  • Version [Oxygen os 10.3.7]

Additional context
Add any other context about the problem here.

Hi @taher.lakdawala, thanks for using our SDK.

I have not been able to reproduce this behavior in our sample app. Can you please provide all relevant code snippets detailing how you are admitting the attendee from the waiting room?

Thanks!

Below code snippets are followed in sequences:

Initialising SDK:

``ZoomSDK zoomSDK = ZoomSDK.getInstance();

ZoomSDKInitParams initParams = new ZoomSDKInitParams();
initParams.jwtToken = “”;
initParams.enableLog = true;
initParams.logSize = 50;
initParams.domain= “zoom.us”;
initParams.appKey = “";
initParams.appSecret = "
”;
initParams.videoRawDataMemoryMode = ZoomSDKRawDataMemoryMode.ZoomSDKRawDataMemoryModeStack;
zoomSDK.initialize(this, mZoomSDKListener, initParams);
zoomSDK.addAuthenticationListener(mZoomSDKListener);``

Enable waiting room:

``PreMeetingService preMeetingService = ZoomSDK.getInstance().getPreMeetingService();

if (preMeetingService == null) {
Log.i(TAG, “preMeetingService is null.”);
return;
}
MeetingItem meetingItem = preMeetingService.getMeetingItemByUniqueId(Long.parseLong(MEETING_ID));
if (meetingItem == null) {
Log.i(TAG, “meetingItem is null.”);
return;
}
meetingItem.setMeetingTopic("***");
meetingItem.setEnableWaitingRoom(true);
meetingItem.setCanJoinBeforeHost(false);
InMeetingWaitingRoomController waitingRoomController = ZoomSDK.getInstance().getInMeetingService().getInMeetingWaitingRoomController();
if (waitingRoomController.isSupportWaitingRoomUponEntryFeature()) {
waitingRoomController.enableWaitingRoomOnEntry(true);
}``

Enabling customised UI:

ZoomSDK.getInstance().getMeetingSettingsHelper().setCustomizedMeetingUIEnabled(true);

Start meeting:

``if (ZoomSDK.getInstance().getMeetingSettingsHelper().isCustomizedMeetingUIEnabled()) {
QtNative.activity().runOnUiThread(new Runnable() {

@Override
public void run() {
Log.i(TAG, “startMeeting, runOnUiThread”);
MeetingService meetingService = ZoomSDK.getInstance().getMeetingService();
if (meetingService == null) {
Log.i(TAG, “startMeeting, meetingService is null”);
return;
}
StartMeetingOptions opts = new StartMeetingOptions();
opts.no_video=true;
if (ZoomSDK.getInstance().isLoggedIn()) {
StartMeetingParams4NormalUser params = new StartMeetingParams4NormalUser();
params.meetingNo = MEETING_ID;
int res = meetingService.startMeetingWithParams(QtNative.activity(), params, opts);
Log.i(TAG, "startMeeting, startMeetingWithParams with login res: " + res);
} else {
StartMeetingParamsWithoutLogin params = new StartMeetingParamsWithoutLogin();
APIUserInfo userInfo = getAPIUserInfo();
if (userInfo != null) {
params.userId = userInfo.userId;
params.userType = STYPE;
params.displayName = “***”;
params.zoomAccessToken = userInfo.userZoomAccessToken;
params.meetingNo = MEETING_ID;
int res = meetingService.startMeetingWithParams(QtNative.activity(), params, opts);
Log.i(TAG, "startMeeting, startMeetingWithParams without login res: " + res);
} else {
Log.i(TAG, “startMeeting, Invalid User Info”);
}
}
}
});``

When client joins:

``@Override

public void onWatingRoomUserJoin(long userId) {
String user_name = ZoomSDK.getInstance().getInMeetingService().getUserInfoById(userId).getUserName();
Log.i(TAG, "onWatingRoomUserJoin userId: " + userId + " user_name: " + user_name);
userJoinedWaitingRoom(String.valueOf(userId), user_name);
}``

After host allows to admit to meeting:

MobileRTCSDKError error = ZoomSDK.getInstance().getInMeetingService().getInMeetingWaitingRoomController().admitToMeeting(Long.parseLong(user_id));

@taher.lakdawala

After host admit user . Uer will receive onMeetingStatusChanged callback.
When the status is MeetingStatus.MEETING_STATUS_CONNECTING. You should start you customize meeting activity by self .

Thanks

We don’t have control over client’s side, as client will be joining the meeting from zoom app or browser by clicking on the meeting link shared from my app, which is shown in the screens shot, so ideally when from my app the host admits the client it should reflect on the client’s side which is not happening but my side log says: admitToMeeting error: SDKERR_SUCCESS

The sample app does not contain example code related to admitToMeeting and onWatingRoomUserJoin.

@taher.lakdawala
If you use zoom meeting ui,you should
call ZoomSDK.getInstance().getMeetingSettingsHelper().setCustomizedMeetingUIEnabled(false);

admitToMeeting the user will rejoin the meeting.

If you use customized ui, you should start you customized meeting activity by self.

Thanks

No no that is wrong, what i was asking is if one side app is using customised UI and starts meeting, then anyone can join meeting by browser or zoom app or my customised UI app. Now i cannot force them to join from my app only.

Anyway i found the solution, the problem was threading. When setting customised UI enable, we need to make all API calls from UI thread as follows:

`` QtNative.activity().runOnUiThread(new Runnable() {

@Override
public void run() {
MobileRTCSDKError error = ZoomSDK.getInstance().getInMeetingService().getInMeetingWaitingRoomController().admitToMeeting(Long.parseLong(user_id));
Log.i(TAG, " admitToMeeting user_id: " + user_id + "error: " + error);
}
});``

@taher.lakdawala Thanks for you feedback. Our api must call in the main thread.

Thanks