pub struct MissingPlugin { /* private fields */ }Expand description
Takes the place of a plugin that a location names but that is not loaded: the name is misspelled, or the plugin failed to build. It fails every request of that location.
Leaving the name out instead served the location without the plugin, and when that plugin is the authentication or the access list, a broken config turned into an open door.
Implementations§
Trait Implementations§
Source§impl Plugin for MissingPlugin
impl Plugin for MissingPlugin
Source§fn handle_request<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_step: PluginStep,
_session: &'life1 mut Session,
_ctx: &'life2 mut Ctx,
) -> Pin<Box<dyn Future<Output = Result<RequestPluginResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn handle_request<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_step: PluginStep,
_session: &'life1 mut Session,
_ctx: &'life2 mut Ctx,
) -> Pin<Box<dyn Future<Output = Result<RequestPluginResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Processes an HTTP request at a specified lifecycle step. Read more
Source§fn config_key(&self) -> Cow<'_, str>
fn config_key(&self) -> Cow<'_, str>
Returns a unique key that identifies this specific plugin instance. Read more
Source§fn handle_response<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_session: &'life1 mut Session,
_ctx: &'life2 mut Ctx,
_upstream_response: &'life3 mut ResponseHeader,
) -> Pin<Box<dyn Future<Output = Result<ResponsePluginResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn handle_response<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
_session: &'life1 mut Session,
_ctx: &'life2 mut Ctx,
_upstream_response: &'life3 mut ResponseHeader,
) -> Pin<Box<dyn Future<Output = Result<ResponsePluginResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Processes an HTTP response at a specified lifecycle step. Read more
Source§fn handles_plugin_response(&self) -> bool
fn handles_plugin_response(&self) -> bool
Whether
handle_response is also to see the response that another
plugin answered the request with. Read moreSource§fn error_page(
&self,
_session: &Session,
_status: StatusCode,
_message: &str,
) -> Option<(HeaderValue, Bytes)>
fn error_page( &self, _session: &Session, _status: StatusCode, _message: &str, ) -> Option<(HeaderValue, Bytes)>
The page this plugin has for an error the proxy answers itself -
no upstream to be had, a request refused by a limit - in place of
the one of the server: its content type and its body.
None
from a plugin that has none, which is every plugin but
error_page, or none for this status. Read moreSource§fn handle_response_body(
&self,
_session: &mut Session,
_ctx: &mut Ctx,
_body: &mut Option<Bytes>,
_end_of_stream: bool,
) -> Result<ResponseBodyPluginResult>
fn handle_response_body( &self, _session: &mut Session, _ctx: &mut Ctx, _body: &mut Option<Bytes>, _end_of_stream: bool, ) -> Result<ResponseBodyPluginResult>
Processes an HTTP response body at a specified lifecycle step. Read more
Source§fn handle_upstream_response(
&self,
_session: &mut Session,
_ctx: &mut Ctx,
_upstream_response: &mut ResponseHeader,
) -> Result<ResponsePluginResult>
fn handle_upstream_response( &self, _session: &mut Session, _ctx: &mut Ctx, _upstream_response: &mut ResponseHeader, ) -> Result<ResponsePluginResult>
Processes an upstream response at a specified lifecycle step. Read more
Auto Trait Implementations§
impl Freeze for MissingPlugin
impl RefUnwindSafe for MissingPlugin
impl Send for MissingPlugin
impl Sync for MissingPlugin
impl Unpin for MissingPlugin
impl UnsafeUnpin for MissingPlugin
impl UnwindSafe for MissingPlugin
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more