AzureStor (version 2.0.1)

acquire_lease: Operations on blob leases

Description

Manage leases for blobs and blob containers.

Usage

acquire_lease(container, blob = "", duration = 60, lease = NULL)

break_lease(container, blob = "", period = NULL)

release_lease(container, blob = "", lease)

renew_lease(container, blob = "", lease)

change_lease(container, blob = "", lease, new_lease)

Arguments

container

A blob container object.

blob

The name of an individual blob. If not supplied, the lease applies to the entire container.

duration

For acquire_lease, The duration of the requested lease. For an indefinite duration, set this to -1.

lease

For acquire_lease an optional proposed name of the lease; for release_lease, renew_lease and change_lease, the name of the existing lease.

period

For break_lease, the period for which to break the lease.

new_lease

For change_lease, the proposed name of the lease.

Value

For acquire_lease and change_lease, a string containing the lease ID.

Details

Leasing is a way to prevent a blob or container from being accidentally deleted. The duration of a lease can range from 15 to 60 seconds, or be indefinite.

See Also

blob_container, Leasing a blob, Leasing a container