CloudBlob.breakLease Method

Definition

Overloads

breakLease(final Integer breakPeriodInSeconds)

Breaks the lease and ensures that another client cannot acquire a new lease until the current lease period has expired.

breakLease(final Integer breakPeriodInSeconds, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)

Breaks the existing lease, using the specified request options and operation context, and ensures that another client cannot acquire a new lease until the current lease period has expired.

breakLease(final Integer breakPeriodInSeconds)

Breaks the lease and ensures that another client cannot acquire a new lease until the current lease period has expired.

public final long breakLease(final Integer breakPeriodInSeconds)
Parameters
breakPeriodInSeconds
final Integer

Specifies the time to wait, in seconds, until the current lease is broken. If null, the break period is the remainder of the current lease, or zero for infinite leases.

Returns
final long

An long which specifies the time, in seconds, remaining in the lease period.

Exceptions

If a storage service error occurred.

breakLease(final Integer breakPeriodInSeconds, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)

Breaks the existing lease, using the specified request options and operation context, and ensures that another client cannot acquire a new lease until the current lease period has expired.

public final long breakLease(final Integer breakPeriodInSeconds, final AccessCondition accessCondition, BlobRequestOptions options, OperationContext opContext)
Parameters
breakPeriodInSeconds
final Integer

An Integer which specifies the time to wait, in seconds, until the current lease is broken. If null, the break period is the remainder of the current lease, or zero for infinite leases.

accessCondition
final AccessCondition

An AccessCondition object that represents the access conditions for the blob.

options
BlobRequestOptions

A BlobRequestOptions object that specifies any additional options for the request. Specifying null will use the default request options from the associated service client (CloudBlobClient).

opContext
OperationContext

An OperationContext object that represents the context for the current operation. The context is used to track requests to the storage service, and to provide additional runtime information about the operation.

Returns
final long

An long which represents the time, in seconds, remaining in the lease period.

Exceptions

If a storage service error occurred.

Applies to