generated from pulumi/pulumi-tf-provider-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 1
/
logAnalyticsImportCustomContent.go
377 lines (322 loc) · 18.8 KB
/
logAnalyticsImportCustomContent.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
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
// Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT.
// *** WARNING: Do not edit by hand unless you're certain you know what you are doing! ***
package loganalytics
import (
"context"
"reflect"
"errors"
"github.com/pulumi/pulumi-oci/sdk/go/oci/internal"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
// This resource provides the Log Analytics Import Custom Content resource in Oracle Cloud Infrastructure Log Analytics service.
//
// Imports the specified custom content from the input in zip format.
//
// ## Example Usage
//
// ```go
// package main
//
// import (
//
// "github.com/pulumi/pulumi-oci/sdk/go/oci/LogAnalytics"
// "github.com/pulumi/pulumi/sdk/v3/go/pulumi"
//
// )
//
// func main() {
// pulumi.Run(func(ctx *pulumi.Context) error {
// _, err := LogAnalytics.NewLogAnalyticsImportCustomContent(ctx, "test_log_analytics_import_custom_content", &LogAnalytics.LogAnalyticsImportCustomContentArgs{
// ImportCustomContentFile: pulumi.Any(logAnalyticsImportCustomContentImportCustomContentFile),
// Namespace: pulumi.Any(logAnalyticsImportCustomContentNamespace),
// Expect: pulumi.Any(logAnalyticsImportCustomContentExpect),
// IsOverwrite: pulumi.Any(logAnalyticsImportCustomContentIsOverwrite),
// })
// if err != nil {
// return err
// }
// return nil
// })
// }
//
// ```
//
// ## Import
//
// Import is not supported for LogAnalyticsImportCustomContent
type LogAnalyticsImportCustomContent struct {
pulumi.CustomResourceState
// LogAnalyticsImportCustomChangeList
ChangeLists LogAnalyticsImportCustomContentChangeListArrayOutput `pulumi:"changeLists"`
// The content name.
ContentName pulumi.StringOutput `pulumi:"contentName"`
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
Expect pulumi.StringOutput `pulumi:"expect"`
// The field names.
FieldNames pulumi.StringArrayOutput `pulumi:"fieldNames"`
// Path to the file to upload which contains the custom content.
ImportCustomContentFile pulumi.StringOutput `pulumi:"importCustomContentFile"`
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
IsOverwrite pulumi.BoolOutput `pulumi:"isOverwrite"`
// The Logging Analytics namespace used for the request.
Namespace pulumi.StringOutput `pulumi:"namespace"`
// The parser names.
ParserNames pulumi.StringArrayOutput `pulumi:"parserNames"`
// The source names.
SourceNames pulumi.StringArrayOutput `pulumi:"sourceNames"`
}
// NewLogAnalyticsImportCustomContent registers a new resource with the given unique name, arguments, and options.
func NewLogAnalyticsImportCustomContent(ctx *pulumi.Context,
name string, args *LogAnalyticsImportCustomContentArgs, opts ...pulumi.ResourceOption) (*LogAnalyticsImportCustomContent, error) {
if args == nil {
return nil, errors.New("missing one or more required arguments")
}
if args.ImportCustomContentFile == nil {
return nil, errors.New("invalid value for required argument 'ImportCustomContentFile'")
}
if args.Namespace == nil {
return nil, errors.New("invalid value for required argument 'Namespace'")
}
opts = internal.PkgResourceDefaultOpts(opts)
var resource LogAnalyticsImportCustomContent
err := ctx.RegisterResource("oci:LogAnalytics/logAnalyticsImportCustomContent:LogAnalyticsImportCustomContent", name, args, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// GetLogAnalyticsImportCustomContent gets an existing LogAnalyticsImportCustomContent resource's state with the given name, ID, and optional
// state properties that are used to uniquely qualify the lookup (nil if not required).
func GetLogAnalyticsImportCustomContent(ctx *pulumi.Context,
name string, id pulumi.IDInput, state *LogAnalyticsImportCustomContentState, opts ...pulumi.ResourceOption) (*LogAnalyticsImportCustomContent, error) {
var resource LogAnalyticsImportCustomContent
err := ctx.ReadResource("oci:LogAnalytics/logAnalyticsImportCustomContent:LogAnalyticsImportCustomContent", name, id, state, &resource, opts...)
if err != nil {
return nil, err
}
return &resource, nil
}
// Input properties used for looking up and filtering LogAnalyticsImportCustomContent resources.
type logAnalyticsImportCustomContentState struct {
// LogAnalyticsImportCustomChangeList
ChangeLists []LogAnalyticsImportCustomContentChangeList `pulumi:"changeLists"`
// The content name.
ContentName *string `pulumi:"contentName"`
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
Expect *string `pulumi:"expect"`
// The field names.
FieldNames []string `pulumi:"fieldNames"`
// Path to the file to upload which contains the custom content.
ImportCustomContentFile *string `pulumi:"importCustomContentFile"`
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
IsOverwrite *bool `pulumi:"isOverwrite"`
// The Logging Analytics namespace used for the request.
Namespace *string `pulumi:"namespace"`
// The parser names.
ParserNames []string `pulumi:"parserNames"`
// The source names.
SourceNames []string `pulumi:"sourceNames"`
}
type LogAnalyticsImportCustomContentState struct {
// LogAnalyticsImportCustomChangeList
ChangeLists LogAnalyticsImportCustomContentChangeListArrayInput
// The content name.
ContentName pulumi.StringPtrInput
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
Expect pulumi.StringPtrInput
// The field names.
FieldNames pulumi.StringArrayInput
// Path to the file to upload which contains the custom content.
ImportCustomContentFile pulumi.StringPtrInput
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
IsOverwrite pulumi.BoolPtrInput
// The Logging Analytics namespace used for the request.
Namespace pulumi.StringPtrInput
// The parser names.
ParserNames pulumi.StringArrayInput
// The source names.
SourceNames pulumi.StringArrayInput
}
func (LogAnalyticsImportCustomContentState) ElementType() reflect.Type {
return reflect.TypeOf((*logAnalyticsImportCustomContentState)(nil)).Elem()
}
type logAnalyticsImportCustomContentArgs struct {
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
Expect *string `pulumi:"expect"`
// Path to the file to upload which contains the custom content.
ImportCustomContentFile string `pulumi:"importCustomContentFile"`
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
IsOverwrite *bool `pulumi:"isOverwrite"`
// The Logging Analytics namespace used for the request.
Namespace string `pulumi:"namespace"`
}
// The set of arguments for constructing a LogAnalyticsImportCustomContent resource.
type LogAnalyticsImportCustomContentArgs struct {
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
Expect pulumi.StringPtrInput
// Path to the file to upload which contains the custom content.
ImportCustomContentFile pulumi.StringInput
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
IsOverwrite pulumi.BoolPtrInput
// The Logging Analytics namespace used for the request.
Namespace pulumi.StringInput
}
func (LogAnalyticsImportCustomContentArgs) ElementType() reflect.Type {
return reflect.TypeOf((*logAnalyticsImportCustomContentArgs)(nil)).Elem()
}
type LogAnalyticsImportCustomContentInput interface {
pulumi.Input
ToLogAnalyticsImportCustomContentOutput() LogAnalyticsImportCustomContentOutput
ToLogAnalyticsImportCustomContentOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentOutput
}
func (*LogAnalyticsImportCustomContent) ElementType() reflect.Type {
return reflect.TypeOf((**LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (i *LogAnalyticsImportCustomContent) ToLogAnalyticsImportCustomContentOutput() LogAnalyticsImportCustomContentOutput {
return i.ToLogAnalyticsImportCustomContentOutputWithContext(context.Background())
}
func (i *LogAnalyticsImportCustomContent) ToLogAnalyticsImportCustomContentOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentOutput {
return pulumi.ToOutputWithContext(ctx, i).(LogAnalyticsImportCustomContentOutput)
}
// LogAnalyticsImportCustomContentArrayInput is an input type that accepts LogAnalyticsImportCustomContentArray and LogAnalyticsImportCustomContentArrayOutput values.
// You can construct a concrete instance of `LogAnalyticsImportCustomContentArrayInput` via:
//
// LogAnalyticsImportCustomContentArray{ LogAnalyticsImportCustomContentArgs{...} }
type LogAnalyticsImportCustomContentArrayInput interface {
pulumi.Input
ToLogAnalyticsImportCustomContentArrayOutput() LogAnalyticsImportCustomContentArrayOutput
ToLogAnalyticsImportCustomContentArrayOutputWithContext(context.Context) LogAnalyticsImportCustomContentArrayOutput
}
type LogAnalyticsImportCustomContentArray []LogAnalyticsImportCustomContentInput
func (LogAnalyticsImportCustomContentArray) ElementType() reflect.Type {
return reflect.TypeOf((*[]*LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (i LogAnalyticsImportCustomContentArray) ToLogAnalyticsImportCustomContentArrayOutput() LogAnalyticsImportCustomContentArrayOutput {
return i.ToLogAnalyticsImportCustomContentArrayOutputWithContext(context.Background())
}
func (i LogAnalyticsImportCustomContentArray) ToLogAnalyticsImportCustomContentArrayOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentArrayOutput {
return pulumi.ToOutputWithContext(ctx, i).(LogAnalyticsImportCustomContentArrayOutput)
}
// LogAnalyticsImportCustomContentMapInput is an input type that accepts LogAnalyticsImportCustomContentMap and LogAnalyticsImportCustomContentMapOutput values.
// You can construct a concrete instance of `LogAnalyticsImportCustomContentMapInput` via:
//
// LogAnalyticsImportCustomContentMap{ "key": LogAnalyticsImportCustomContentArgs{...} }
type LogAnalyticsImportCustomContentMapInput interface {
pulumi.Input
ToLogAnalyticsImportCustomContentMapOutput() LogAnalyticsImportCustomContentMapOutput
ToLogAnalyticsImportCustomContentMapOutputWithContext(context.Context) LogAnalyticsImportCustomContentMapOutput
}
type LogAnalyticsImportCustomContentMap map[string]LogAnalyticsImportCustomContentInput
func (LogAnalyticsImportCustomContentMap) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (i LogAnalyticsImportCustomContentMap) ToLogAnalyticsImportCustomContentMapOutput() LogAnalyticsImportCustomContentMapOutput {
return i.ToLogAnalyticsImportCustomContentMapOutputWithContext(context.Background())
}
func (i LogAnalyticsImportCustomContentMap) ToLogAnalyticsImportCustomContentMapOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentMapOutput {
return pulumi.ToOutputWithContext(ctx, i).(LogAnalyticsImportCustomContentMapOutput)
}
type LogAnalyticsImportCustomContentOutput struct{ *pulumi.OutputState }
func (LogAnalyticsImportCustomContentOutput) ElementType() reflect.Type {
return reflect.TypeOf((**LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (o LogAnalyticsImportCustomContentOutput) ToLogAnalyticsImportCustomContentOutput() LogAnalyticsImportCustomContentOutput {
return o
}
func (o LogAnalyticsImportCustomContentOutput) ToLogAnalyticsImportCustomContentOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentOutput {
return o
}
// LogAnalyticsImportCustomChangeList
func (o LogAnalyticsImportCustomContentOutput) ChangeLists() LogAnalyticsImportCustomContentChangeListArrayOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) LogAnalyticsImportCustomContentChangeListArrayOutput {
return v.ChangeLists
}).(LogAnalyticsImportCustomContentChangeListArrayOutput)
}
// The content name.
func (o LogAnalyticsImportCustomContentOutput) ContentName() pulumi.StringOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringOutput { return v.ContentName }).(pulumi.StringOutput)
}
// A value of `100-continue` requests preliminary verification of the request method, path, and headers before the request body is sent. If no error results from such verification, the server will send a 100 (Continue) interim response to indicate readiness for the request body. The only allowed value for this parameter is "100-Continue" (case-insensitive).
//
// ** IMPORTANT **
// Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values
func (o LogAnalyticsImportCustomContentOutput) Expect() pulumi.StringOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringOutput { return v.Expect }).(pulumi.StringOutput)
}
// The field names.
func (o LogAnalyticsImportCustomContentOutput) FieldNames() pulumi.StringArrayOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringArrayOutput { return v.FieldNames }).(pulumi.StringArrayOutput)
}
// Path to the file to upload which contains the custom content.
func (o LogAnalyticsImportCustomContentOutput) ImportCustomContentFile() pulumi.StringOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringOutput { return v.ImportCustomContentFile }).(pulumi.StringOutput)
}
// A flag indicating whether or not to overwrite existing content if a conflict is found during import content operation.
func (o LogAnalyticsImportCustomContentOutput) IsOverwrite() pulumi.BoolOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.BoolOutput { return v.IsOverwrite }).(pulumi.BoolOutput)
}
// The Logging Analytics namespace used for the request.
func (o LogAnalyticsImportCustomContentOutput) Namespace() pulumi.StringOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringOutput { return v.Namespace }).(pulumi.StringOutput)
}
// The parser names.
func (o LogAnalyticsImportCustomContentOutput) ParserNames() pulumi.StringArrayOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringArrayOutput { return v.ParserNames }).(pulumi.StringArrayOutput)
}
// The source names.
func (o LogAnalyticsImportCustomContentOutput) SourceNames() pulumi.StringArrayOutput {
return o.ApplyT(func(v *LogAnalyticsImportCustomContent) pulumi.StringArrayOutput { return v.SourceNames }).(pulumi.StringArrayOutput)
}
type LogAnalyticsImportCustomContentArrayOutput struct{ *pulumi.OutputState }
func (LogAnalyticsImportCustomContentArrayOutput) ElementType() reflect.Type {
return reflect.TypeOf((*[]*LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (o LogAnalyticsImportCustomContentArrayOutput) ToLogAnalyticsImportCustomContentArrayOutput() LogAnalyticsImportCustomContentArrayOutput {
return o
}
func (o LogAnalyticsImportCustomContentArrayOutput) ToLogAnalyticsImportCustomContentArrayOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentArrayOutput {
return o
}
func (o LogAnalyticsImportCustomContentArrayOutput) Index(i pulumi.IntInput) LogAnalyticsImportCustomContentOutput {
return pulumi.All(o, i).ApplyT(func(vs []interface{}) *LogAnalyticsImportCustomContent {
return vs[0].([]*LogAnalyticsImportCustomContent)[vs[1].(int)]
}).(LogAnalyticsImportCustomContentOutput)
}
type LogAnalyticsImportCustomContentMapOutput struct{ *pulumi.OutputState }
func (LogAnalyticsImportCustomContentMapOutput) ElementType() reflect.Type {
return reflect.TypeOf((*map[string]*LogAnalyticsImportCustomContent)(nil)).Elem()
}
func (o LogAnalyticsImportCustomContentMapOutput) ToLogAnalyticsImportCustomContentMapOutput() LogAnalyticsImportCustomContentMapOutput {
return o
}
func (o LogAnalyticsImportCustomContentMapOutput) ToLogAnalyticsImportCustomContentMapOutputWithContext(ctx context.Context) LogAnalyticsImportCustomContentMapOutput {
return o
}
func (o LogAnalyticsImportCustomContentMapOutput) MapIndex(k pulumi.StringInput) LogAnalyticsImportCustomContentOutput {
return pulumi.All(o, k).ApplyT(func(vs []interface{}) *LogAnalyticsImportCustomContent {
return vs[0].(map[string]*LogAnalyticsImportCustomContent)[vs[1].(string)]
}).(LogAnalyticsImportCustomContentOutput)
}
func init() {
pulumi.RegisterInputType(reflect.TypeOf((*LogAnalyticsImportCustomContentInput)(nil)).Elem(), &LogAnalyticsImportCustomContent{})
pulumi.RegisterInputType(reflect.TypeOf((*LogAnalyticsImportCustomContentArrayInput)(nil)).Elem(), LogAnalyticsImportCustomContentArray{})
pulumi.RegisterInputType(reflect.TypeOf((*LogAnalyticsImportCustomContentMapInput)(nil)).Elem(), LogAnalyticsImportCustomContentMap{})
pulumi.RegisterOutputType(LogAnalyticsImportCustomContentOutput{})
pulumi.RegisterOutputType(LogAnalyticsImportCustomContentArrayOutput{})
pulumi.RegisterOutputType(LogAnalyticsImportCustomContentMapOutput{})
}