github.com/pulumi/pulumi-aws/sdk/v6@v6.32.0/go/aws/mskconnect/getCustomPlugin.go (about) 1 // Code generated by the Pulumi Terraform Bridge (tfgen) Tool DO NOT EDIT. 2 // *** WARNING: Do not edit by hand unless you're certain you know what you are doing! *** 3 4 package mskconnect 5 6 import ( 7 "context" 8 "reflect" 9 10 "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/internal" 11 "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 12 ) 13 14 // Get information on an Amazon MSK Connect custom plugin. 15 // 16 // ## Example Usage 17 // 18 // <!--Start PulumiCodeChooser --> 19 // ```go 20 // package main 21 // 22 // import ( 23 // 24 // "github.com/pulumi/pulumi-aws/sdk/v6/go/aws/mskconnect" 25 // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" 26 // 27 // ) 28 // 29 // func main() { 30 // pulumi.Run(func(ctx *pulumi.Context) error { 31 // _, err := mskconnect.LookupCustomPlugin(ctx, &mskconnect.LookupCustomPluginArgs{ 32 // Name: "example-debezium-1", 33 // }, nil) 34 // if err != nil { 35 // return err 36 // } 37 // return nil 38 // }) 39 // } 40 // 41 // ``` 42 // <!--End PulumiCodeChooser --> 43 func LookupCustomPlugin(ctx *pulumi.Context, args *LookupCustomPluginArgs, opts ...pulumi.InvokeOption) (*LookupCustomPluginResult, error) { 44 opts = internal.PkgInvokeDefaultOpts(opts) 45 var rv LookupCustomPluginResult 46 err := ctx.Invoke("aws:mskconnect/getCustomPlugin:getCustomPlugin", args, &rv, opts...) 47 if err != nil { 48 return nil, err 49 } 50 return &rv, nil 51 } 52 53 // A collection of arguments for invoking getCustomPlugin. 54 type LookupCustomPluginArgs struct { 55 // Name of the custom plugin. 56 Name string `pulumi:"name"` 57 } 58 59 // A collection of values returned by getCustomPlugin. 60 type LookupCustomPluginResult struct { 61 // the ARN of the custom plugin. 62 Arn string `pulumi:"arn"` 63 // a summary description of the custom plugin. 64 Description string `pulumi:"description"` 65 // The provider-assigned unique ID for this managed resource. 66 Id string `pulumi:"id"` 67 // an ID of the latest successfully created revision of the custom plugin. 68 LatestRevision int `pulumi:"latestRevision"` 69 Name string `pulumi:"name"` 70 // the state of the custom plugin. 71 State string `pulumi:"state"` 72 } 73 74 func LookupCustomPluginOutput(ctx *pulumi.Context, args LookupCustomPluginOutputArgs, opts ...pulumi.InvokeOption) LookupCustomPluginResultOutput { 75 return pulumi.ToOutputWithContext(context.Background(), args). 76 ApplyT(func(v interface{}) (LookupCustomPluginResult, error) { 77 args := v.(LookupCustomPluginArgs) 78 r, err := LookupCustomPlugin(ctx, &args, opts...) 79 var s LookupCustomPluginResult 80 if r != nil { 81 s = *r 82 } 83 return s, err 84 }).(LookupCustomPluginResultOutput) 85 } 86 87 // A collection of arguments for invoking getCustomPlugin. 88 type LookupCustomPluginOutputArgs struct { 89 // Name of the custom plugin. 90 Name pulumi.StringInput `pulumi:"name"` 91 } 92 93 func (LookupCustomPluginOutputArgs) ElementType() reflect.Type { 94 return reflect.TypeOf((*LookupCustomPluginArgs)(nil)).Elem() 95 } 96 97 // A collection of values returned by getCustomPlugin. 98 type LookupCustomPluginResultOutput struct{ *pulumi.OutputState } 99 100 func (LookupCustomPluginResultOutput) ElementType() reflect.Type { 101 return reflect.TypeOf((*LookupCustomPluginResult)(nil)).Elem() 102 } 103 104 func (o LookupCustomPluginResultOutput) ToLookupCustomPluginResultOutput() LookupCustomPluginResultOutput { 105 return o 106 } 107 108 func (o LookupCustomPluginResultOutput) ToLookupCustomPluginResultOutputWithContext(ctx context.Context) LookupCustomPluginResultOutput { 109 return o 110 } 111 112 // the ARN of the custom plugin. 113 func (o LookupCustomPluginResultOutput) Arn() pulumi.StringOutput { 114 return o.ApplyT(func(v LookupCustomPluginResult) string { return v.Arn }).(pulumi.StringOutput) 115 } 116 117 // a summary description of the custom plugin. 118 func (o LookupCustomPluginResultOutput) Description() pulumi.StringOutput { 119 return o.ApplyT(func(v LookupCustomPluginResult) string { return v.Description }).(pulumi.StringOutput) 120 } 121 122 // The provider-assigned unique ID for this managed resource. 123 func (o LookupCustomPluginResultOutput) Id() pulumi.StringOutput { 124 return o.ApplyT(func(v LookupCustomPluginResult) string { return v.Id }).(pulumi.StringOutput) 125 } 126 127 // an ID of the latest successfully created revision of the custom plugin. 128 func (o LookupCustomPluginResultOutput) LatestRevision() pulumi.IntOutput { 129 return o.ApplyT(func(v LookupCustomPluginResult) int { return v.LatestRevision }).(pulumi.IntOutput) 130 } 131 132 func (o LookupCustomPluginResultOutput) Name() pulumi.StringOutput { 133 return o.ApplyT(func(v LookupCustomPluginResult) string { return v.Name }).(pulumi.StringOutput) 134 } 135 136 // the state of the custom plugin. 137 func (o LookupCustomPluginResultOutput) State() pulumi.StringOutput { 138 return o.ApplyT(func(v LookupCustomPluginResult) string { return v.State }).(pulumi.StringOutput) 139 } 140 141 func init() { 142 pulumi.RegisterOutputType(LookupCustomPluginResultOutput{}) 143 }