Show / Hide Table of Contents

Class ProjectsResource.LocationsResource.ReservationsResource.AssignmentsResource.CreateRequest

Creates an assignment object which allows the given project to submit jobs of a certain type using slots from the specified reservation. Currently a resource (project, folder, organization) can only have one assignment per each (job_type, location) combination, and that reservation will be used for all jobs of the matching type. Different assignments can be created on different levels of the projects, folders or organization hierarchy. During query execution, the assignment is looked up at the project, folder and organization levels in that order. The first assignment found is applied to the query. When creating assignments, it does not matter if other assignments exist at higher levels. Example: * The organization organizationA contains two projects, project1 and project2. * Assignments for all three entities (organizationA, project1, and project2) could all be created and mapped to the same or different reservations. "None" assignments represent an absence of the assignment. Projects assigned to None use on-demand pricing. To create a "None" assignment, use "none" as a reservation_id in the parent. Example parent: projects/myproject/locations/US/reservations/none. Returns google.rpc.Code.PERMISSION_DENIED if user does not have 'bigquery.admin' permissions on the project using the reservation and the project that owns this reservation. Returns google.rpc.Code.INVALID_ARGUMENT when location of the assignment does not match location of the reservation.

Inheritance
System.Object
Google.Apis.Requests.ClientServiceRequest
Google.Apis.Requests.ClientServiceRequest<Assignment>
BigQueryReservationBaseServiceRequest<Assignment>
ProjectsResource.LocationsResource.ReservationsResource.AssignmentsResource.CreateRequest
Implements
Google.Apis.Requests.IClientServiceRequest<Assignment>
Google.Apis.Requests.IClientServiceRequest
Inherited Members
BigQueryReservationBaseServiceRequest<Assignment>.Xgafv
BigQueryReservationBaseServiceRequest<Assignment>.AccessToken
BigQueryReservationBaseServiceRequest<Assignment>.Alt
BigQueryReservationBaseServiceRequest<Assignment>.Callback
BigQueryReservationBaseServiceRequest<Assignment>.Fields
BigQueryReservationBaseServiceRequest<Assignment>.Key
BigQueryReservationBaseServiceRequest<Assignment>.OauthToken
BigQueryReservationBaseServiceRequest<Assignment>.PrettyPrint
BigQueryReservationBaseServiceRequest<Assignment>.QuotaUser
BigQueryReservationBaseServiceRequest<Assignment>.UploadType
BigQueryReservationBaseServiceRequest<Assignment>.UploadProtocol
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.Execute()
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ExecuteAsStream()
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ExecuteAsync()
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ExecuteAsync(System.Threading.CancellationToken)
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ExecuteAsStreamAsync()
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ExecuteAsStreamAsync(System.Threading.CancellationToken)
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.CreateRequest(System.Nullable<System.Boolean>)
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.GenerateRequestUri()
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.GetDefaultETagAction(System.String)
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ETagAction
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ModifyRequest
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.ValidateParameters
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.RequestParameters
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.Service
Google.Apis.Requests.ClientServiceRequest._unsuccessfulResponseHandlers
Google.Apis.Requests.ClientServiceRequest._exceptionHandlers
Google.Apis.Requests.ClientServiceRequest._executeInterceptors
Google.Apis.Requests.ClientServiceRequest.AddUnsuccessfulResponseHandler(Google.Apis.Http.IHttpUnsuccessfulResponseHandler)
Google.Apis.Requests.ClientServiceRequest.AddExceptionHandler(Google.Apis.Http.IHttpExceptionHandler)
Google.Apis.Requests.ClientServiceRequest.AddExecuteInterceptor(Google.Apis.Http.IHttpExecuteInterceptor)
Google.Apis.Requests.ClientServiceRequest.Credential
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Google.Apis.BigQueryReservation.v1beta1
Assembly: Google.Apis.BigQueryReservation.v1beta1.dll
Syntax
public class CreateRequest : BigQueryReservationBaseServiceRequest<Assignment>, IClientServiceRequest<Assignment>, IClientServiceRequest

Constructors

CreateRequest(IClientService, Assignment, String)

Constructs a new Create request.

Declaration
public CreateRequest(IClientService service, Assignment body, string parent)
Parameters
Type Name Description
Google.Apis.Services.IClientService service
Assignment body
System.String parent

Properties

AssignmentId

The optional assignment ID. Assignment name will be generated automatically if this field is empty. This field must only contain lower case alphanumeric characters or dashes. Max length is 64 characters.

Declaration
[RequestParameter("assignmentId", RequestParameterType.Query)]
public virtual string AssignmentId { get; set; }
Property Value
Type Description
System.String

HttpMethod

Gets the HTTP method.

Declaration
public override string HttpMethod { get; }
Property Value
Type Description
System.String
Overrides
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.HttpMethod

MethodName

Gets the method name.

Declaration
public override string MethodName { get; }
Property Value
Type Description
System.String
Overrides
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.MethodName

Parent

Required. The parent resource name of the assignment E.g. projects/myproject/locations/US/reservations/team1-prod

Declaration
[RequestParameter("parent", RequestParameterType.Path)]
public virtual string Parent { get; }
Property Value
Type Description
System.String

RestPath

Gets the REST path.

Declaration
public override string RestPath { get; }
Property Value
Type Description
System.String
Overrides
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.RestPath

Methods

GetBody()

Returns the body of the request.

Declaration
protected override object GetBody()
Returns
Type Description
System.Object
Overrides
Google.Apis.Requests.ClientServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.GetBody()

InitParameters()

Initializes Create parameter list.

Declaration
protected override void InitParameters()
Overrides
Google.Apis.BigQueryReservation.v1beta1.BigQueryReservationBaseServiceRequest<Google.Apis.BigQueryReservation.v1beta1.Data.Assignment>.InitParameters()

Implements

Google.Apis.Requests.IClientServiceRequest<TResponse>
Google.Apis.Requests.IClientServiceRequest
In This Article
Back to top