various bug fixes to work with latest jbosseap6 openshift cartridge