pub struct WorkerProjectStorage {
pub account_id: String,
pub region: String,
pub credential: WorkerR2Credential,
pub private_object_storage_bucket: String,
pub public_object_storage_bucket: String,
pub public_object_storage_base_url: String,
pub config_version: u64,
}Expand description
Where one project’s objects live, as the worker sees it.
One credential, scoped to exactly the three buckets named here. The frontend-asset bucket is deliberately outside it: nothing in the worker serves assets — the CDN does, straight off the bucket — so a fleet-wide credential able to rewrite a deployed frontend would be reach with no use for it.
Fields§
§account_id: String§region: String§credential: WorkerR2Credential§private_object_storage_bucket: String§public_object_storage_bucket: String§public_object_storage_base_url: StringCDN origin for public_object_storage_bucket, without a trailing slash.
config_version: u64Bumped by control on every credential or bucket change, so a worker can skip re-decrypting a target it already holds.
Trait Implementations§
Source§impl Clone for WorkerProjectStorage
impl Clone for WorkerProjectStorage
Source§fn clone(&self) -> WorkerProjectStorage
fn clone(&self) -> WorkerProjectStorage
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'de> Deserialize<'de> for WorkerProjectStorage
impl<'de> Deserialize<'de> for WorkerProjectStorage
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for WorkerProjectStorage
Source§impl PartialEq for WorkerProjectStorage
impl PartialEq for WorkerProjectStorage
Source§impl Serialize for WorkerProjectStorage
impl Serialize for WorkerProjectStorage
impl StructuralPartialEq for WorkerProjectStorage
Auto Trait Implementations§
impl Freeze for WorkerProjectStorage
impl RefUnwindSafe for WorkerProjectStorage
impl Send for WorkerProjectStorage
impl Sync for WorkerProjectStorage
impl Unpin for WorkerProjectStorage
impl UnsafeUnpin for WorkerProjectStorage
impl UnwindSafe for WorkerProjectStorage
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