Take a look at the JPA example - that runs completely outside of a J2ee env and is a version of the booking example. There are also examples there for several different application containers.
As for how to get Mysql data source setup the easiest way might be to run seam gen and tell it that you are using mysql. Set what ever values you want for the other questions but answer the ones below. Check the seam-gen instructions for more information if needed.
..... [input] What kind of database are you using? [mysql] (hsql, [mysql], oracle, postgres, mssql, db2, sybase, enterprisedb, ) [input] Enter the Hibernate dialect for your database [org.hibernate.dialect.MySQLDialect] [org.hibernate.dialect.MySQLDialect] [input] Enter the filesystem path to the JDBC driver jar [lib/mysql.jar] [lib/mysql.jar] [input] Enter JDBC driver class for your database [com.mysql.jdbc.Driver] [com.mysql.jdbc.Driver] [input] Enter the JDBC URL for your database [jdbc:mysql:///youdbname] [jdbc:mysql:///yourdbname] [input] Enter database username [user] [user] [input] Enter database password [password] [password] .......
Then have seam-gen create a new project.
Your options are then to use that generated project as a starting point, or extract from it the important bits for the mysql config (elements of persistence.xml and components.xml).