https://docs.jboss.org/hibernate/orm/5.3/userguide/html_single/Hibernate_User_Guide.html#configurations-logging
xml version="1.0" encoding="UTF-8"
<persistence version="2.1" xmlns="http://xmlns.jcp.org/xml/ns/persistence" xmlnsxsi="http://www.w3.org/2001/XMLSchema-instance" xsischemaLocation="http://xmlns.jcp.org/xml/ns/persistence http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd">
<persistence-unit name="XXX" transaction-type="JTA">
<properties>
<property name="hibernate.show_sql" value="true" />
<property name="hibernate.format_sql" value="true" />
<property name="hibernate.use_sql_comments" value="true" />
</properties>
</persistence-unit>
</persistence>