Page 1 of 1

Using a database for buddylist

Posted: 25 Oct 2010, 16:33
by cpdavidd
Hello,

I'm encourcing a small problem. I'm going to have more than 1 game server. And I need, that the buddylist for the x user would be same at any server. So I thought that the best way would be, that the buddylist would be stored in database like MySQL.

It is possible to use MySQL with the current SFS buddy persister?

Thanks

Posted: 25 Oct 2010, 20:13
by BigFIsh
BuddyList v2 uses an embedded database (h2database) - so that'll be ideal for your purpose.

Posted: 26 Oct 2010, 13:03
by cpdavidd
Um... thanks for the fast response. :)

H2 database is interesting, but I prefer MySQL (because I can't run H2?)... is there any way to use MySQL

Posted: 26 Oct 2010, 13:07
by TiagoR
cpdavidd wrote:Um... thanks for the fast response. :)

H2 database is interesting, but I prefer MySQL (because I can't run H2?)... is there any way to use MySQL
Yes, but you need to create your Persister class which handles the loading and saving of the buddy list.

Go to http://www.smartfoxserver.com/docs/docP ... yList2.htm and read under Custom Persistence classes

Posted: 27 Oct 2010, 05:31
by cpdavidd
Thanks for a really fast answer :) (unfortunately, I'm really stupid on Java :oops:)