class ProjectsLocationsReservations extends Resource (View source)

The "reservations" collection of methods.

Typical usage is:

 $bigqueryreservationService = new Google\Service\BigQueryReservation(...);
 $reservations = $bigqueryreservationService->projects_locations_reservations;

Methods

create(string $parent, Reservation $postBody, array $optParams = [])

Creates a new reservation resource. (reservations.create)

delete(string $name, array $optParams = [])

Deletes a reservation. Returns google.rpc.Code.FAILED_PRECONDITION when reservation has assignments. (reservations.delete)

failoverReservation(string $name, FailoverReservationRequest $postBody, array $optParams = [])

Failover a reservation to the secondary location. The operation should be done in the current secondary location, which will be promoted to the new primary location for the reservation. Attempting to failover a reservation in the current primary location will fail with the error code google.rpc.Code.FAILED_PRECONDITION. (reservations.failoverReservation)

get(string $name, array $optParams = [])

Returns information about the reservation. (reservations.get)

listProjectsLocationsReservations(string $parent, array $optParams = [])

Lists all the reservations for the project in the specified location.

patch(string $name, Reservation $postBody, array $optParams = [])

Updates an existing reservation resource. (reservations.patch)

Details

Reservation create(string $parent, Reservation $postBody, array $optParams = [])

Creates a new reservation resource. (reservations.create)

Parameters

string $parent

Required. Project, location. E.g., projects/myproject/locations/US

Reservation $postBody
array $optParams

Optional parameters.

Return Value

Reservation

Exceptions

Exception

BigqueryreservationEmpty delete(string $name, array $optParams = [])

Deletes a reservation. Returns google.rpc.Code.FAILED_PRECONDITION when reservation has assignments. (reservations.delete)

Parameters

string $name

Required. Resource name of the reservation to retrieve. E.g., projects/myproject/locations/US/reservations/team1-prod

array $optParams

Optional parameters.

Return Value

BigqueryreservationEmpty

Exceptions

Exception

Reservation failoverReservation(string $name, FailoverReservationRequest $postBody, array $optParams = [])

Failover a reservation to the secondary location. The operation should be done in the current secondary location, which will be promoted to the new primary location for the reservation. Attempting to failover a reservation in the current primary location will fail with the error code google.rpc.Code.FAILED_PRECONDITION. (reservations.failoverReservation)

Parameters

string $name

Required. Resource name of the reservation to failover. E.g., projects/myproject/locations/US/reservations/team1-prod

FailoverReservationRequest $postBody
array $optParams

Optional parameters.

Return Value

Reservation

Exceptions

Exception

Reservation get(string $name, array $optParams = [])

Returns information about the reservation. (reservations.get)

Parameters

string $name

Required. Resource name of the reservation to retrieve. E.g., projects/myproject/locations/US/reservations/team1-prod

array $optParams

Optional parameters.

Return Value

Reservation

Exceptions

Exception

ListReservationsResponse listProjectsLocationsReservations(string $parent, array $optParams = [])

Lists all the reservations for the project in the specified location.

(reservations.listProjectsLocationsReservations)

Parameters

string $parent

Required. The parent resource name containing project and location, e.g.: projects/myproject/locations/US

array $optParams

Optional parameters.

Return Value

ListReservationsResponse

Exceptions

Exception

Reservation patch(string $name, Reservation $postBody, array $optParams = [])

Updates an existing reservation resource. (reservations.patch)

Parameters

string $name

The resource name of the reservation, e.g., projects/locations/reservations/team1-prod. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.

Reservation $postBody
array $optParams

Optional parameters.

Return Value

Reservation

Exceptions

Exception