[CXF-6015] Providing a workaround, a better solution will need to be provided in due time, also removing some redundant code to do with creating Context resolvers