The main steps are discussed here and again the integration depends on the transaction manager and database you choose.
If you like, I can provide a sample description using Bitronix transaction manager and h2 database. Then you can extend it for the transaction manager/database you choose.