Log JPA Queries in WildFly (10.1)
Do the following changes in server configuration file (like standalone.xml); restart the server after wise.
Change the console handler to look like:
<console-handler name="CONSOLE">
<level name="TRACE"/>
<formatter>
<named-formatter name="COLOR-PATTERN"/>
</formatter>
</console-handler>
Add a logger for org.eclipse.persistence.sql
:
<logger category="org.eclipse.persistence.sql">
<level name="DEBUG"/>
</logger>
PGgxIGlkPSJsb2dqcGFxdWVyaWVzaW53aWxkZmx5MTAuMSI+TG9nIEpQQSBRdWVyaWVzIGlu
IFdpbGRGbHkgKDEwLjEpPC9oMT4NCg0KPHA+RG8gdGhlIGZvbGxvd2luZyBjaGFuZ2VzIGlu
IHNlcnZlciBjb25maWd1cmF0aW9uIGZpbGUgKGxpa2Ugc3RhbmRhbG9uZS54bWwpOyByZXN0
YXJ0IHRoZSBzZXJ2ZXIgYWZ0ZXIgd2lzZS48L3A+DQoNCjxwPkNoYW5nZSB0aGUgY29uc29s
ZSBoYW5kbGVyIHRvIGxvb2sgbGlrZTo8L3A+DQoNCjxwcmU+PGNvZGUgY2xhc3M9InhtbCI+
ICAgICAgICAgICAgJmx0O2NvbnNvbGUtaGFuZGxlciBuYW1lPSZxdW90O0NPTlNPTEUmcXVv
dDsmZ3Q7DQogICAgICAgICAgICAgICAgJmx0O2xldmVsIG5hbWU9JnF1b3Q7VFJBQ0UmcXVv
dDsvJmd0Ow0KICAgICAgICAgICAgICAgICZsdDtmb3JtYXR0ZXImZ3Q7DQogICAgICAgICAg
ICAgICAgICAgICZsdDtuYW1lZC1mb3JtYXR0ZXIgbmFtZT0mcXVvdDtDT0xPUi1QQVRURVJO
JnF1b3Q7LyZndDsNCiAgICAgICAgICAgICAgICAmbHQ7L2Zvcm1hdHRlciZndDsNCiAgICAg
ICAgICAgICZsdDsvY29uc29sZS1oYW5kbGVyJmd0Ow0KDQo8L2NvZGU+PC9wcmU+DQoNCjxw
PkFkZCBhIGxvZ2dlciBmb3IgPGNvZGU+b3JnLmVjbGlwc2UucGVyc2lzdGVuY2U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