Process the request after routing.

        Serializer selection needs a resource to determine which
        serializers are allowed.

def process_resource(self, req, resp, resource):
        """ Process the request after routing.

        Serializer selection needs a resource to determine which
        serializers are allowed.
        """

        if resource:
            allowed = resource.serializer_mimetypes
            preferred = req.client_prefers(allowed)

            if not preferred:
                abort(RequestNotAcceptable(allowed))
            else:
                serializer = self._get_serializer(preferred)
                resp.serializer = serializer(req, resp)