mirror of
https://github.com/cloudflare/pingora.git
synced 2024-09-20 02:31:35 +02:00
expose session to cache_hit_filter phase
This commit is contained in:
parent
cd5134431c
commit
026f483712
3 changed files with 3 additions and 7 deletions
2
.bleep
2
.bleep
|
@ -1 +1 @@
|
|||
d44d3b13cb33c5163561923a94d62baed216767d
|
||||
b0438fe62f4b4004646ca3621a0c0215c6385f6f
|
|
@ -116,11 +116,7 @@ impl<SV> HttpProxy<SV> {
|
|||
// (this is a soft purge which tries to revalidate,
|
||||
// vs. hard purge which forces miss)
|
||||
// TODO: allow hard purge
|
||||
match self
|
||||
.inner
|
||||
.cache_hit_filter(&meta, ctx, session.req_header())
|
||||
.await
|
||||
{
|
||||
match self.inner.cache_hit_filter(session, &meta, ctx).await {
|
||||
Err(e) => {
|
||||
error!(
|
||||
"Failed to filter cache hit: {e}, {}",
|
||||
|
|
|
@ -109,9 +109,9 @@ pub trait ProxyHttp {
|
|||
// flex purge, other filtering, returns whether asset is should be force expired or not
|
||||
async fn cache_hit_filter(
|
||||
&self,
|
||||
_session: &Session,
|
||||
_meta: &CacheMeta,
|
||||
_ctx: &mut Self::CTX,
|
||||
_req: &RequestHeader,
|
||||
) -> Result<bool>
|
||||
where
|
||||
Self::CTX: Send + Sync,
|
||||
|
|
Loading…
Reference in a new issue