Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/06chaynes/http-cache
/ functions
Functions
612 in github.com/06chaynes/http-cache
⨍
Functions
612
◇
Types & classes
100
↓ 440 callers
Method
clone
(&self)
http-cache-tower/src/lib.rs:702
↓ 274 callers
Method
body
Create a body processing error # Examples ```rust use http_cache::HttpCacheError; let err = HttpCacheError::body("Failed to collect request body");
http-cache/src/error.rs:121
↓ 219 callers
Method
get
Create a GET request
http-cache-ureq/src/lib.rs:371
↓ 147 callers
Method
header
Get a header value
http-cache-ureq/src/lib.rs:709
↓ 106 callers
Method
status
Get the response status code
http-cache-ureq/src/lib.rs:699
↓ 96 callers
Method
build
Build the cached agent
http-cache-ureq/src/lib.rs:300
↓ 73 callers
Method
call
Execute the request with caching
http-cache-ureq/src/lib.rs:514
↓ 66 callers
Method
call
(&mut self, req: Request<ReqBody>)
http-cache-tower-server/src/lib.rs:614
↓ 59 callers
Method
insert
Inserts a header key-value pair, replacing any existing values for that key Keys are normalized to lowercase per RFC 7230
http-cache/src/lib.rs:682
↓ 54 callers
Method
method
(&self)
http-cache-tower/src/lib.rs:293
↓ 53 callers
Method
call
(&mut self, _req: Request<Full<Bytes>>)
http-cache-tower/src/test.rs:75
↓ 49 callers
Method
layer
(&self, inner: S)
http-cache-tower/src/lib.rs:671
↓ 48 callers
Function
url_parse
(s: &str)
http-cache/src/lib.rs:363
↓ 38 callers
Method
layer
(&self, inner: S)
http-cache-tower-server/src/lib.rs:556
↓ 37 callers
Method
cache_manager
Set the cache manager
http-cache-ureq/src/lib.rs:282
↓ 36 callers
Method
cache_mode
Set the cache mode
http-cache-ureq/src/lib.rs:288
↓ 35 callers
Function
create_cache_manager
Helper function to create a temporary cache manager
http-cache-reqwest/src/test.rs:15
↓ 33 callers
Method
create_cache_key
( &self, parts: &request::Parts, override_method: Option<&str>, )
http-cache/src/lib.rs:1714
↓ 33 callers
Method
delete
(&self, cache_key: &str)
http-cache/src/managers/moka.rs:215
↓ 29 callers
Method
analyze_request
( &self, parts: &request::Parts, mode_override: Option<CacheMode>, )
http-cache/src/lib.rs:3064
↓ 29 callers
Function
build_mock
( cache_control_val: &str, body: &[u8], status: u16, expect: u64, )
http-cache-reqwest/src/test.rs:24
↓ 29 callers
Method
get
Retrieves the first value for a given header key Keys are normalized to lowercase per RFC 7230
http-cache/src/lib.rs:717
↓ 27 callers
Function
build_mock
( cache_control_val: &str, body: &[u8], status: u16, expect: u64, )
http-cache-ureq/src/test.rs:18
↓ 26 callers
Method
get
( &self, cache_key: &str, )
http-cache-tower-server/tests/integration.rs:33
↓ 26 callers
Method
iter
Returns an iterator over the header key-value pairs
http-cache/src/lib.rs:755
↓ 24 callers
Method
put
( &self, cache_key: String, response: Response<B>, policy: CachePolicy,
http-cache/src/managers/streaming_cache.rs:859
↓ 24 callers
Function
response_with_body
(bytes: Bytes)
http-cache/src/managers/streaming_cache.rs:1138
↓ 24 callers
Function
sample_policy
()
http-cache/src/managers/streaming_cache.rs:1120
↓ 24 callers
Function
test_url
()
http-cache/src/managers/streaming_cache.rs:1134
↓ 20 callers
Function
build_mock
( cache_control_val: &str, body: &[u8], status: u16, expect: u64, )
http-cache-surf/src/test.rs:86
↓ 18 callers
Method
method
(&self)
http-cache-surf/src/lib.rs:253
↓ 16 callers
Method
append
Appends a header value, preserving existing values for the same key Keys are normalized to lowercase per RFC 7230
http-cache/src/lib.rs:698
↓ 16 callers
Method
lookup_cached_response
( &self, key: &str, )
http-cache/src/lib.rs:3072
↓ 14 callers
Method
cache_options
Set cache options
http-cache-ureq/src/lib.rs:294
↓ 14 callers
Method
run
The main streaming cache orchestrator. This mirrors the logic of [`HttpCache::run`] but operates on streaming `Response<B>` bodies and delegates upst
http-cache/src/lib.rs:2172
↓ 13 callers
Function
create_streaming_cache_manager
Helper function to create a streaming cache manager
http-cache-reqwest/src/test.rs:1281
↓ 13 callers
Method
process_response
( &self, analysis: CacheAnalysis, response: Response<B>, metadata: Option<Vec<
http-cache/src/lib.rs:3079
↓ 13 callers
Method
remove
Removes a header key and its associated values Keys are normalized to lowercase per RFC 7230
http-cache/src/lib.rs:730
↓ 12 callers
Method
get
( &self, cache_key: &str, )
http-cache/src/managers/streaming_cache.rs:761
↓ 12 callers
Method
into_response
Convert to an HTTP response.
http-cache-tower-server/src/lib.rs:404
↓ 12 callers
Method
put
( &self, cache_key: String, response: HttpResponse, policy: CachePolicy, )
http-cache/src/managers/moka.rs:184
↓ 11 callers
Function
body_hash_for
Compute the deterministic on-disk body hash for a cache key.
http-cache/src/managers/streaming_cache.rs:155
↓ 11 callers
Function
extract_url_from_request_parts
Extract a URL from HTTP request parts for cache key generation This function reconstructs the full URL from the request parts, handling both HTTP and
http-cache/src/lib.rs:553
↓ 11 callers
Method
parts
Returns `http::response::Parts`
http-cache/src/lib.rs:904
↓ 10 callers
Method
cache_lookup_status
Adds the custom `x-cache-lookup` header to the response
http-cache/src/lib.rs:987
↓ 10 callers
Method
cache_status
Adds the custom `x-cache` header to the response
http-cache/src/lib.rs:982
↓ 10 callers
Method
invalidate
Invalidate a specific cache entry by its key.
http-cache-tower-server/src/lib.rs:533
↓ 9 callers
Function
response_cache_lookup_status
Adds the custom `x-cache-lookup` status header to an `http::Response`.
http-cache/src/lib.rs:2042
↓ 9 callers
Function
response_cache_status
Adds the custom `x-cache` status header to an `http::Response`.
http-cache/src/lib.rs:2032
↓ 9 callers
Method
run_pending_tasks
Runs pending maintenance tasks (eviction, etc). This is called automatically but can be invoked manually to force immediate cleanup.
http-cache/src/managers/streaming_cache.rs:611
↓ 8 callers
Method
apply_rate_limiting
(&self, url: &Url)
http-cache/src/lib.rs:2119
↓ 8 callers
Function
body_path_for
Compute the full body file path for a given body hash.
http-cache/src/managers/streaming_cache.rs:160
↓ 8 callers
Method
cache_err
(self)
http-cache-tower/src/lib.rs:198
↓ 8 callers
Method
clear
Clears out the entire cache.
http-cache/src/managers/moka.rs:112
↓ 8 callers
Method
current_usage
(&self)
http-cache-tower/examples/tower_streaming_memory_profile.rs:33
↓ 8 callers
Method
current_usage
(&self)
http-cache-reqwest/examples/reqwest_streaming_memory_profile.rs:36
↓ 8 callers
Method
get
( &self, cache_key: &str, )
http-cache-quickcache/src/lib.rs:208
↓ 7 callers
Function
has_directive
Determine if a response should be cached based on its headers. Implements RFC 7234/9111 requirements for shared caches. Helper function to check if a
http-cache-tower-server/src/lib.rs:817
↓ 7 callers
Method
redb_remove
Remove a key from redb. Swallows errors at debug level; used by self-heal paths.
http-cache/src/managers/streaming_cache.rs:617
↓ 7 callers
Method
request
Create a request with a custom method
http-cache-ureq/src/lib.rs:421
↓ 7 callers
Method
until_key_ready
( &self, key: &str, )
http-cache/src/test.rs:1314
↓ 7 callers
Method
with_options
Set custom options.
http-cache-tower-server/src/lib.rs:522
↓ 6 callers
Method
cache_key
(&self, req: &Request<B>)
http-cache-tower-server/src/lib.rs:202
↓ 6 callers
Method
call
(&mut self, _req: Request<Full<Bytes>>)
http-cache-tower/benches/streaming_benchmark.rs:39
↓ 6 callers
Method
can_cache_request
Determines if the request described by `parts` should be cached, taking into account any `mode_override`.
http-cache/src/lib.rs:2104
↓ 6 callers
Method
convert_body
( &self, response: Response<B>, )
http-cache/src/managers/streaming_cache.rs:1037
↓ 6 callers
Method
post
Create a POST request
http-cache-ureq/src/lib.rs:381
↓ 6 callers
Method
remote_fetch
( &self, middleware: &mut impl Middleware, )
http-cache/src/lib.rs:2818
↓ 6 callers
Function
to_middleware_error
Helper function to convert our error types to reqwest middleware errors
http-cache-reqwest/src/lib.rs:300
↓ 5 callers
Method
as_bytes
Get the response body as bytes
http-cache-ureq/src/lib.rs:736
↓ 5 callers
Method
generate_metadata
Generates metadata for a response using the metadata_provider callback if configured
http-cache/src/lib.rs:1796
↓ 5 callers
Method
head
Create a HEAD request
http-cache-ureq/src/lib.rs:411
↓ 5 callers
Method
parts
(&self)
http-cache-reqwest/src/lib.rs:415
↓ 5 callers
Method
remote_fetch_and_cache
Processes a fresh upstream response and potentially caches it. Mirrors [`HttpCache::remote_fetch`] but receives the response directly rather than cal
http-cache/src/lib.rs:2324
↓ 5 callers
Method
should_cache_response
Determines if a response should be cached based on cache mode and HTTP semantics
http-cache/src/lib.rs:1890
↓ 5 callers
Method
update_headers
Update the headers from `http::response::Parts`
http-cache/src/lib.rs:960
↓ 5 callers
Function
url_hostname
(url: &Url)
http-cache/src/lib.rs:415
↓ 4 callers
Method
add_warning
Adds a warning header to a response
http-cache/src/lib.rs:928
↓ 4 callers
Method
contains_key
Checks if a header key exists Keys are normalized to lowercase per RFC 7230
http-cache/src/lib.rs:745
↓ 4 callers
Method
evaluate_response_cache_mode
Evaluates response-based cache mode override
http-cache/src/lib.rs:1779
↓ 4 callers
Function
execute_request
Universal function to execute HTTP requests - replaces all method-specific duplication
http-cache-ureq/src/lib.rs:603
↓ 4 callers
Method
method
(&self)
http-cache-reqwest/src/lib.rs:440
↓ 4 callers
Method
modify_response_before_caching
Modifies the response before caching if a modifier function is provided
http-cache/src/lib.rs:1807
↓ 4 callers
Method
parts
(&self)
http-cache-surf/src/lib.rs:234
↓ 4 callers
Method
run_no_cache
Performs cache-busting housekeeping for requests that should not be cached. Mirrors [`HttpCache::run_no_cache`].
http-cache/src/lib.rs:2135
↓ 3 callers
Function
apply_modify_response_shim
Applies [`HttpCacheOptions::modify_response_before_caching`] to a streaming `Response<B>`. The callback expects `&mut HttpResponse`, so we build a te
http-cache/src/lib.rs:2058
↓ 3 callers
Function
apply_ttl_constraints
Apply min/max TTL constraints from options.
http-cache-tower-server/src/lib.rs:924
↓ 3 callers
Method
build_http_parts
(&self)
http-cache-ureq/src/lib.rs:894
↓ 3 callers
Function
build_mock
( cache_control_val: &str, body: &[u8], status: u16, expect: u64, )
http-cache-quickcache/src/test.rs:14
↓ 3 callers
Function
cache_bust
()
http-cache-surf/src/test.rs:705
↓ 3 callers
Method
create_cache_policy
Creates a cache policy for the given request and response
http-cache/src/lib.rs:1814
↓ 3 callers
Method
delete
(&self, cache_key: &str)
http-cache/src/managers/streaming_cache.rs:1080
↓ 3 callers
Method
into_iter
(self)
http-cache/src/lib.rs:816
↓ 3 callers
Method
next
(&mut self)
http-cache/src/lib.rs:843
↓ 3 callers
Method
overridden_cache_mode
Allows the cache mode to be overridden. This overrides any cache mode set in the configuration, including cache_mode_fn.
http-cache/src/lib.rs:1093
↓ 3 callers
Method
parts
(&self)
http-cache-tower/src/lib.rs:285
↓ 3 callers
Function
response_add_warning
Adds an RFC 2616 §14.46 warning header to an `http::Response`.
http-cache/src/lib.rs:1996
↓ 3 callers
Method
run_no_cache_from_parts
Cache-busting for non-cacheable requests, taking pre-extracted parts.
http-cache/src/lib.rs:2666
↓ 3 callers
Method
url
(&self)
http-cache-reqwest/src/lib.rs:436
↓ 3 callers
Method
url
Get the response URL
http-cache-ureq/src/lib.rs:704
next →
1–100 of 612, ranked by callers