JBTM-1852 and JBTM-1364

Needs testing with: https://github.com/jbosstm/jboss-as/pull/19