mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-11-20 00:07:01 +00:00
fix: hit the volume cache on Azure and keep a volume's lease through its pull (#12520)
* fix: hit the volume cache on Azure and keep a volume's lease through its pull Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore: update ee-repo-ref to 1eb95bcdc7624b90074e8c3a4eaba011b3b5100d This commit updates the EE repository reference after PR #991 was merged in windmill-ee-private. Previous ee-repo-ref: 1fac8e2335e3de98e96d602aa6e0a59e8f8f35b8 New ee-repo-ref: 1eb95bcdc7624b90074e8c3a4eaba011b3b5100d Automated by sync-ee-ref workflow. --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Co-authored-by: windmill-internal-app[bot] <windmill-internal-app[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
windmill-internal-app[bot]
parent
39cb251ab8
commit
97b80aef5e
@@ -1 +1 @@
|
||||
e8f950759d65f1ccc98a4a91c8900709eb8d545a
|
||||
1eb95bcdc7624b90074e8c3a4eaba011b3b5100d
|
||||
|
||||
@@ -17,6 +17,10 @@ pub struct FileEntry {
|
||||
pub size: u64,
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
pub md5: Option<String>,
|
||||
/// The object's ETag when this content was last read or written. A store's ETag need not be
|
||||
/// a content hash (Azure's never is), so only the same store's ETag can vouch for a copy.
|
||||
#[serde(default, skip_serializing_if = "Option::is_none")]
|
||||
pub e_tag: Option<String>,
|
||||
}
|
||||
|
||||
pub fn compute_md5_hex(data: &[u8]) -> String {
|
||||
@@ -31,14 +35,14 @@ pub fn compute_md5_hex(data: &[u8]) -> String {
|
||||
hex
|
||||
}
|
||||
|
||||
/// Extract an MD5 hash from an S3 ETag, if it's a simple (non-multipart) ETag.
|
||||
/// The content MD5 an ETag carries, if it is one: S3's for a single-part upload. Multipart S3
|
||||
/// ETags (`<hex>-<parts>`) and Azure's (`0x8D…`) are opaque and must not be compared with a hash.
|
||||
pub fn etag_to_md5(e_tag: Option<&str>) -> Option<String> {
|
||||
let tag = e_tag?.trim_matches('"');
|
||||
// Multipart ETags contain a '-' (e.g. "abc123-5"), skip those
|
||||
if tag.contains('-') || tag.is_empty() {
|
||||
if tag.len() != 32 || !tag.bytes().all(|b| b.is_ascii_hexdigit()) {
|
||||
return None;
|
||||
}
|
||||
Some(tag.to_string())
|
||||
Some(tag.to_ascii_lowercase())
|
||||
}
|
||||
|
||||
lazy_static::lazy_static! {
|
||||
|
||||
Reference in New Issue
Block a user