I use "org.jivesoftware.smack.Roster.createEntry(java.lang.String user, java.lang.String name, java.lang.String[] groups
)" api to add an entry, it is throwing
internal-server-error(500)
at org.jivesoftware.smack.Roster.createEntry(Roster.java:284)
source code follows:
public void addUser(String userName, String name, String groupName) {
getRoster().createEntry(userName, name, new String[] { groupName });
}
public Roster getRoster() {
final Roster roster = xmppConnection.getConnection().getRoster();
roster.setSubscriptionMode(Roster.SubscriptionMode.accept_all);
roster.addRosterListener(rosterListener);
return roster;
}
Please help!