Sockets or database?

I am creating a drawing application in flash 8. i want to make it realtime app.
To create a session among a no: of persons whitch method will give more performance,xml sockets or database?

Thanks in advance