Backporting for EAP 5 & 6.
https://issues.jboss.org/browse/JBPAPP-9815 https://issues.jboss.org/browse/JBPAPP-9816
Backporting for EAP 5 & 6.
https://issues.jboss.org/browse/JBPAPP-9815
https://issues.jboss.org/browse/JBPAPP-9816