// choose the storage you want to use
//StorageProviderRegistry providerRegistry = new JcrStorageProviderRegistry();
StorageProviderRegistry providerRegistry = new MemoryStorageProviderRegistry();
final AccountManagement accountManagement = (AccountManagement) providerRegistry
.retrieve(AccountManagement.class);
if (!accountManagement.verifyAccountExists(EntityImpl.parse("user1@vysper.org"))) {
accountManagement.addUser("user1@vysper.org", "password1");
}
if (!accountManagement.verifyAccountExists(EntityImpl.parse("user2@vysper.org"))) {
accountManagement.addUser("user2@vysper.org", "password1");
}
if (!accountManagement.verifyAccountExists(EntityImpl.parse("user3@vysper.org"))) {
accountManagement.addUser("user3@vysper.org", "password1");
}
XMPPServer server = new XMPPServer("vysper.org");
server.addEndpoint(new TCPEndpoint());
//server.addEndpoint(new StanzaSessionFactory());