'Generate a WSGI response based on the exception passed to ctor.'

@webob.dec.wsgify(RequestClass=Request)
def __call__(self, req):

    locale = req.best_match_language()
    code = self.wrapped_exc.status_int
    fault_name = self._fault_names.get(code, 'computeFault')
    explanation = self.wrapped_exc.explanation
    fault_data = {fault_name: {'code': code, 'message': i18n.translate(explanation, locale)}}
    if (code == http_client.REQUEST_ENTITY_TOO_LARGE):
        retry = self.wrapped_exc.headers.get('Retry-After', None)
        if retry:
            fault_data[fault_name]['retryAfter'] = retry
    if (req.api_version_request and (not _is_legacy_endpoint(req))):
        self.wrapped_exc.headers[API_VERSION_REQUEST_HEADER] = ((VOLUME_SERVICE + '    ') + req.api_version_request.get_string())
        self.wrapped_exc.headers['Vary'] = API_VERSION_REQUEST_HEADER
    content_type = req.best_match_content_type()
    serializer = {'application/json': JSONDictSerializer()}[content_type]
    body = serializer.serialize(fault_data)
    if isinstance(body, six.text_type):
        body = body.encode('utf-8')
    self.wrapped_exc.body = body
    self.wrapped_exc.content_type = content_type
    _set_request_id_header(req, self.wrapped_exc.headers)
    return self.wrapped_exc
