middleware: remove oslo.context usage
There's nothing interesting in the fake context we're passing. Let's stop depending on oslo.context all together here. Change-Id: I7784bc3b818e67118e03905857c39eac66765fad
This commit is contained in:
parent
5840ab3340
commit
47a906aff3
@ -22,7 +22,6 @@ import sys
|
|||||||
import traceback as tb
|
import traceback as tb
|
||||||
|
|
||||||
from oslo_config import cfg
|
from oslo_config import cfg
|
||||||
from oslo_context import context
|
|
||||||
from oslo_middleware import base
|
from oslo_middleware import base
|
||||||
import six
|
import six
|
||||||
import webob.dec
|
import webob.dec
|
||||||
@ -85,7 +84,7 @@ class RequestNotifier(base.Middleware):
|
|||||||
'request': self.environ_to_dict(request.environ),
|
'request': self.environ_to_dict(request.environ),
|
||||||
}
|
}
|
||||||
|
|
||||||
self.notifier.info(context.get_admin_context(),
|
self.notifier.info({},
|
||||||
'http.request',
|
'http.request',
|
||||||
payload)
|
payload)
|
||||||
|
|
||||||
@ -108,7 +107,7 @@ class RequestNotifier(base.Middleware):
|
|||||||
'traceback': tb.format_tb(traceback)
|
'traceback': tb.format_tb(traceback)
|
||||||
}
|
}
|
||||||
|
|
||||||
self.notifier.info(context.get_admin_context(),
|
self.notifier.info({},
|
||||||
'http.response',
|
'http.response',
|
||||||
payload)
|
payload)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user