Skip to content

BucketService

Defined in: core/src/bucket/bucket.service.ts:16

Hands out Bucket instances by definition, caching one per id. A service resolved via the Services container.

new BucketService(services): BucketService;

Defined in: core/src/bucket/bucket.service.ts:20

Parameter Type
services Services

BucketService

getInstance(options): Bucket;

Defined in: core/src/bucket/bucket.service.ts:31

Returns the bucket for options, creating it on first use. The definition object itself is the identity: passing a different object with an id that is already taken throws BucketIdConflictError, so two providers cannot silently end up writing into the same bucket. Sharing a bucket is still possible — share the definition.

Parameter Type
options BucketOptions

Bucket