Can't you just extend the original class? Seems like there's not much wildfly specific code in there. Lot of duplication not good for maintainability