Hi Marina,
the <persistence-unit> element in the persistence.xml file has an
attribute transaction-type which defaults to JTA. I think this default
is not useful in a Java SE environment, so the persistence.xml file
should explicitly set the attribute to RESOURCE_LOCAL in this case.
We should update the persistence.xml in the Java SE available on the
glassfish "Persistence Example" page. What do you think?
Regards Michael