datanucleus/samples-jpa — pull request #1 by MohamedNadjibMAMI (2014-05-15 16:59:48+00:00)
Title: Add connection to MySQL

It's identical to JDO, I got the code from there, and tested it. In JDO, it should work for MariaDB also, but since I didn't test there I just wrote "ENABLE FOR MySQL", but I believe it will work also.