Please consider adding generic type to the MessageBodyWriter declaration.