@Override public List<GSChatRoom> getChatRooms() throws RemoteException { synchronized (this) { logger.debug("query session"); if (this.userState != GSUserState.Login) { logger.debug("query session error"); return new ArrayList<>(); } List<GSChatRoom> chatRooms = null; try { chatRooms = binderDataBase.getChatRooms(); logger.debug("query session -- success"); } catch (Exception e) { logger.error("get chat rooms error", e); } return chatRooms; } }