Added an alternative implementation of WINDUP-147

https://issues.jboss.org/browse/WINDUP-147
What about renaming it to attachToDB(), save() or something?