ISPN-2708 Fix support for custom marshallers