/
getZoneQueuedResource.go
152 lines (127 loc) · 7.54 KB
/
getZoneQueuedResource.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
// Code generated by the Pulumi SDK Generator DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package alpha
import (
"context"
"reflect"
"github.com/pulumi/pulumi-google-native/sdk/go/google/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// Returns the specified QueuedResource resource.
func LookupZoneQueuedResource(ctx *pulumi.Context, args *LookupZoneQueuedResourceArgs, opts ...pulumi.InvokeOption) (*LookupZoneQueuedResourceResult, error) {
opts = internal.PkgInvokeDefaultOpts(opts)
var rv LookupZoneQueuedResourceResult
err := ctx.Invoke("google-native:compute/alpha:getZoneQueuedResource", args, &rv, opts...)
if err != nil {
return nil, err
}
return &rv, nil
}
type LookupZoneQueuedResourceArgs struct {
Project *string `pulumi:"project"`
QueuedResource string `pulumi:"queuedResource"`
Zone string `pulumi:"zone"`
}
type LookupZoneQueuedResourceResult struct {
// Specification of VM instances to create.
BulkInsertInstanceResource BulkInsertInstanceResourceResponse `pulumi:"bulkInsertInstanceResource"`
// Creation timestamp in RFC3339 text format.
CreationTimestamp string `pulumi:"creationTimestamp"`
// An optional description of this resource. Provide this property when you create the resource.
Description string `pulumi:"description"`
// Type of the resource. Always compute#queuedResource for QueuedResources.
Kind string `pulumi:"kind"`
// Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Name string `pulumi:"name"`
// Queuing parameters for the requested capacity.
QueuingPolicy QueuingPolicyResponse `pulumi:"queuingPolicy"`
// [Output only] Server-defined URL for the resource.
SelfLink string `pulumi:"selfLink"`
// Server-defined URL for this resource with the resource id.
SelfLinkWithId string `pulumi:"selfLinkWithId"`
// [Output only] High-level status of the request.
State string `pulumi:"state"`
// [Output only] Result of queuing and provisioning based on deferred capacity.
Status QueuedResourceStatusResponse `pulumi:"status"`
// URL of the zone where the resource resides. Only applicable for zonal resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
Zone string `pulumi:"zone"`
}
func LookupZoneQueuedResourceOutput(ctx *pulumi.Context, args LookupZoneQueuedResourceOutputArgs, opts ...pulumi.InvokeOption) LookupZoneQueuedResourceResultOutput {
return pulumi.ToOutputWithContext(context.Background(), args).
ApplyT(func(v interface{}) (LookupZoneQueuedResourceResult, error) {
args := v.(LookupZoneQueuedResourceArgs)
r, err := LookupZoneQueuedResource(ctx, &args, opts...)
var s LookupZoneQueuedResourceResult
if r != nil {
s = *r
}
return s, err
}).(LookupZoneQueuedResourceResultOutput)
}
type LookupZoneQueuedResourceOutputArgs struct {
Project pulumi.StringPtrInput `pulumi:"project"`
QueuedResource pulumi.StringInput `pulumi:"queuedResource"`
Zone pulumi.StringInput `pulumi:"zone"`
}
func (LookupZoneQueuedResourceOutputArgs) ElementType() reflect.Type {
return reflect.TypeOf((*LookupZoneQueuedResourceArgs)(nil)).Elem()
}
type LookupZoneQueuedResourceResultOutput struct{ *pulumi.OutputState }
func (LookupZoneQueuedResourceResultOutput) ElementType() reflect.Type {
return reflect.TypeOf((*LookupZoneQueuedResourceResult)(nil)).Elem()
}
func (o LookupZoneQueuedResourceResultOutput) ToLookupZoneQueuedResourceResultOutput() LookupZoneQueuedResourceResultOutput {
return o
}
func (o LookupZoneQueuedResourceResultOutput) ToLookupZoneQueuedResourceResultOutputWithContext(ctx context.Context) LookupZoneQueuedResourceResultOutput {
return o
}
// Specification of VM instances to create.
func (o LookupZoneQueuedResourceResultOutput) BulkInsertInstanceResource() BulkInsertInstanceResourceResponseOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) BulkInsertInstanceResourceResponse {
return v.BulkInsertInstanceResource
}).(BulkInsertInstanceResourceResponseOutput)
}
// Creation timestamp in RFC3339 text format.
func (o LookupZoneQueuedResourceResultOutput) CreationTimestamp() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.CreationTimestamp }).(pulumi.StringOutput)
}
// An optional description of this resource. Provide this property when you create the resource.
func (o LookupZoneQueuedResourceResultOutput) Description() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.Description }).(pulumi.StringOutput)
}
// Type of the resource. Always compute#queuedResource for QueuedResources.
func (o LookupZoneQueuedResourceResultOutput) Kind() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.Kind }).(pulumi.StringOutput)
}
// Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression `[a-z]([-a-z0-9]*[a-z0-9])?` which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
func (o LookupZoneQueuedResourceResultOutput) Name() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.Name }).(pulumi.StringOutput)
}
// Queuing parameters for the requested capacity.
func (o LookupZoneQueuedResourceResultOutput) QueuingPolicy() QueuingPolicyResponseOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) QueuingPolicyResponse { return v.QueuingPolicy }).(QueuingPolicyResponseOutput)
}
// [Output only] Server-defined URL for the resource.
func (o LookupZoneQueuedResourceResultOutput) SelfLink() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.SelfLink }).(pulumi.StringOutput)
}
// Server-defined URL for this resource with the resource id.
func (o LookupZoneQueuedResourceResultOutput) SelfLinkWithId() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.SelfLinkWithId }).(pulumi.StringOutput)
}
// [Output only] High-level status of the request.
func (o LookupZoneQueuedResourceResultOutput) State() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.State }).(pulumi.StringOutput)
}
// [Output only] Result of queuing and provisioning based on deferred capacity.
func (o LookupZoneQueuedResourceResultOutput) Status() QueuedResourceStatusResponseOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) QueuedResourceStatusResponse { return v.Status }).(QueuedResourceStatusResponseOutput)
}
// URL of the zone where the resource resides. Only applicable for zonal resources. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body.
func (o LookupZoneQueuedResourceResultOutput) Zone() pulumi.StringOutput {
return o.ApplyT(func(v LookupZoneQueuedResourceResult) string { return v.Zone }).(pulumi.StringOutput)
}
func init() {
pulumi.RegisterOutputType(LookupZoneQueuedResourceResultOutput{})
}