[CXF-6045] Changing the way BodyWriters are registered and fixing the test faiures