Struct google_api_proto::google::cloud::tasks::v2beta2::RenewLeaseRequest
source · pub struct RenewLeaseRequest {
pub name: String,
pub schedule_time: Option<Timestamp>,
pub lease_duration: Option<Duration>,
pub response_view: i32,
}
Expand description
Request message for renewing a lease using [RenewLease][google.cloud.tasks.v2beta2.CloudTasks.RenewLease].
Fields§
§name: String
Required. The task name. For example:
projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID
schedule_time: Option<Timestamp>
Required. The task’s current schedule time, available in the [schedule_time][google.cloud.tasks.v2beta2.Task.schedule_time] returned by [LeaseTasks][google.cloud.tasks.v2beta2.CloudTasks.LeaseTasks] response or [RenewLease][google.cloud.tasks.v2beta2.CloudTasks.RenewLease] response. This restriction is to ensure that your worker currently holds the lease.
lease_duration: Option<Duration>
Required. The desired new lease duration, starting from now.
The maximum lease duration is 1 week.
lease_duration
will be truncated to the nearest second.
response_view: i32
The response_view specifies which subset of the [Task][google.cloud.tasks.v2beta2.Task] will be returned.
By default response_view is [BASIC][google.cloud.tasks.v2beta2.Task.View.BASIC]; not all information is retrieved by default because some data, such as payloads, might be desirable to return only when needed because of its large size or because of the sensitivity of data that it contains.
Authorization for [FULL][google.cloud.tasks.v2beta2.Task.View.FULL]
requires cloudtasks.tasks.fullView
Google
IAM permission on the
[Task][google.cloud.tasks.v2beta2.Task] resource.
Implementations§
source§impl RenewLeaseRequest
impl RenewLeaseRequest
sourcepub fn response_view(&self) -> View
pub fn response_view(&self) -> View
Returns the enum value of response_view
, or the default if the field is set to an invalid enum value.
sourcepub fn set_response_view(&mut self, value: View)
pub fn set_response_view(&mut self, value: View)
Sets response_view
to the provided enum value.
Trait Implementations§
source§impl Clone for RenewLeaseRequest
impl Clone for RenewLeaseRequest
source§fn clone(&self) -> RenewLeaseRequest
fn clone(&self) -> RenewLeaseRequest
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for RenewLeaseRequest
impl Debug for RenewLeaseRequest
source§impl Default for RenewLeaseRequest
impl Default for RenewLeaseRequest
source§impl Message for RenewLeaseRequest
impl Message for RenewLeaseRequest
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for RenewLeaseRequest
impl PartialEq for RenewLeaseRequest
source§fn eq(&self, other: &RenewLeaseRequest) -> bool
fn eq(&self, other: &RenewLeaseRequest) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for RenewLeaseRequest
Auto Trait Implementations§
impl Freeze for RenewLeaseRequest
impl RefUnwindSafe for RenewLeaseRequest
impl Send for RenewLeaseRequest
impl Sync for RenewLeaseRequest
impl Unpin for RenewLeaseRequest
impl UnwindSafe for RenewLeaseRequest
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request