updateBiReservation method
- BiReservation request,
- String name, {
- String? updateMask,
- String? $fields,
Updates a BI reservation.
Only fields specified in the field_mask
are updated. A singleton BI
reservation always exists with default size 0. In order to reserve BI
capacity it needs to be updated to an amount greater than 0. In order to
release BI capacity reservation size must be set to 0.
request
- The metadata request object.
Request parameters:
name
- The resource name of the singleton BI reservation. Reservation
names have the form
projects/{project_id}/locations/{location_id}/biReservation
.
Value must have pattern
^projects/\[^/\]+/locations/\[^/\]+/biReservation$
.
updateMask
- A list of fields to be updated in this request.
$fields
- Selector specifying which fields to include in a partial
response.
Completes with a BiReservation.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client
completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<BiReservation> updateBiReservation(
BiReservation request,
core.String name, {
core.String? updateMask,
core.String? $fields,
}) async {
final body_ = convert.json.encode(request);
final queryParams_ = <core.String, core.List<core.String>>{
if (updateMask != null) 'updateMask': [updateMask],
if ($fields != null) 'fields': [$fields],
};
final url_ = 'v1/' + core.Uri.encodeFull('$name');
final response_ = await _requester.request(
url_,
'PATCH',
body: body_,
queryParams: queryParams_,
);
return BiReservation.fromJson(
response_ as core.Map<core.String, core.dynamic>);
}