1. Packages
  2. Logdna Provider
  3. API Docs
  4. StreamConfig
logdna 1.16.0 published on Monday, Apr 14, 2025 by logdna

logdna.StreamConfig

Explore with Pulumi AI

logdna logo
logdna 1.16.0 published on Monday, Apr 14, 2025 by logdna

    # Resource: logdna.StreamConfig

    IBM Log Analysis and Cloud Activity Tracker users only

    Manages LogDNA Streaming configuration for an account.

    Example

    import * as pulumi from "@pulumi/pulumi";
    import * as logdna from "@pulumi/logdna";
    
    const config = new logdna.StreamConfig("config", {
        user: _var.stream_user,
        password: _var.stream_password,
        topic: "example",
        brokers: [
            "broker-1.example.org:9093",
            "broker-2.example.org:9093",
            "broker-3.example.org:9093",
        ],
    });
    
    import pulumi
    import pulumi_logdna as logdna
    
    config = logdna.StreamConfig("config",
        user=var["stream_user"],
        password=var["stream_password"],
        topic="example",
        brokers=[
            "broker-1.example.org:9093",
            "broker-2.example.org:9093",
            "broker-3.example.org:9093",
        ])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/logdna/logdna"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := logdna.NewStreamConfig(ctx, "config", &logdna.StreamConfigArgs{
    			User:     pulumi.Any(_var.Stream_user),
    			Password: pulumi.Any(_var.Stream_password),
    			Topic:    pulumi.String("example"),
    			Brokers: pulumi.StringArray{
    				pulumi.String("broker-1.example.org:9093"),
    				pulumi.String("broker-2.example.org:9093"),
    				pulumi.String("broker-3.example.org:9093"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Logdna = Pulumi.Logdna;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Logdna.StreamConfig("config", new()
        {
            User = @var.Stream_user,
            Password = @var.Stream_password,
            Topic = "example",
            Brokers = new[]
            {
                "broker-1.example.org:9093",
                "broker-2.example.org:9093",
                "broker-3.example.org:9093",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.logdna.StreamConfig;
    import com.pulumi.logdna.StreamConfigArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var config = new StreamConfig("config", StreamConfigArgs.builder()
                .user(var_.stream_user())
                .password(var_.stream_password())
                .topic("example")
                .brokers(            
                    "broker-1.example.org:9093",
                    "broker-2.example.org:9093",
                    "broker-3.example.org:9093")
                .build());
    
        }
    }
    
    resources:
      config:
        type: logdna:StreamConfig
        properties:
          user: ${var.stream_user}
          password: ${var.stream_password}
          topic: example
          brokers:
            - broker-1.example.org:9093
            - broker-2.example.org:9093
            - broker-3.example.org:9093
    

    Create StreamConfig Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new StreamConfig(name: string, args: StreamConfigArgs, opts?: CustomResourceOptions);
    @overload
    def StreamConfig(resource_name: str,
                     args: StreamConfigArgs,
                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def StreamConfig(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     brokers: Optional[Sequence[str]] = None,
                     password: Optional[str] = None,
                     topic: Optional[str] = None,
                     user: Optional[str] = None,
                     stream_config_id: Optional[str] = None)
    func NewStreamConfig(ctx *Context, name string, args StreamConfigArgs, opts ...ResourceOption) (*StreamConfig, error)
    public StreamConfig(string name, StreamConfigArgs args, CustomResourceOptions? opts = null)
    public StreamConfig(String name, StreamConfigArgs args)
    public StreamConfig(String name, StreamConfigArgs args, CustomResourceOptions options)
    
    type: logdna:StreamConfig
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args StreamConfigArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args StreamConfigArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args StreamConfigArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args StreamConfigArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args StreamConfigArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var streamConfigResource = new Logdna.StreamConfig("streamConfigResource", new()
    {
        Brokers = new[]
        {
            "string",
        },
        Password = "string",
        Topic = "string",
        User = "string",
        StreamConfigId = "string",
    });
    
    example, err := logdna.NewStreamConfig(ctx, "streamConfigResource", &logdna.StreamConfigArgs{
    	Brokers: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Password:       pulumi.String("string"),
    	Topic:          pulumi.String("string"),
    	User:           pulumi.String("string"),
    	StreamConfigId: pulumi.String("string"),
    })
    
    var streamConfigResource = new StreamConfig("streamConfigResource", StreamConfigArgs.builder()
        .brokers("string")
        .password("string")
        .topic("string")
        .user("string")
        .streamConfigId("string")
        .build());
    
    stream_config_resource = logdna.StreamConfig("streamConfigResource",
        brokers=["string"],
        password="string",
        topic="string",
        user="string",
        stream_config_id="string")
    
    const streamConfigResource = new logdna.StreamConfig("streamConfigResource", {
        brokers: ["string"],
        password: "string",
        topic: "string",
        user: "string",
        streamConfigId: "string",
    });
    
    type: logdna:StreamConfig
    properties:
        brokers:
            - string
        password: string
        streamConfigId: string
        topic: string
        user: string
    

    StreamConfig Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The StreamConfig resource accepts the following input properties:

    Brokers List<string>
    []string (Required) List of of broker URLs.
    Password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    Topic string
    string (Required) The topic that logs will be published on.
    User string
    string (Required) The SASL username for the connection.
    StreamConfigId string
    Brokers []string
    []string (Required) List of of broker URLs.
    Password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    Topic string
    string (Required) The topic that logs will be published on.
    User string
    string (Required) The SASL username for the connection.
    StreamConfigId string
    brokers List<String>
    []string (Required) List of of broker URLs.
    password String

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    topic String
    string (Required) The topic that logs will be published on.
    user String
    string (Required) The SASL username for the connection.
    streamConfigId String
    brokers string[]
    []string (Required) List of of broker URLs.
    password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    topic string
    string (Required) The topic that logs will be published on.
    user string
    string (Required) The SASL username for the connection.
    streamConfigId string
    brokers Sequence[str]
    []string (Required) List of of broker URLs.
    password str

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    topic str
    string (Required) The topic that logs will be published on.
    user str
    string (Required) The SASL username for the connection.
    stream_config_id str
    brokers List<String>
    []string (Required) List of of broker URLs.
    password String

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    topic String
    string (Required) The topic that logs will be published on.
    user String
    string (Required) The SASL username for the connection.
    streamConfigId String

    Outputs

    All input properties are implicitly available as output properties. Additionally, the StreamConfig resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    id String
    The provider-assigned unique ID for this managed resource.
    status String

    Look up Existing StreamConfig Resource

    Get an existing StreamConfig resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: StreamConfigState, opts?: CustomResourceOptions): StreamConfig
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            brokers: Optional[Sequence[str]] = None,
            password: Optional[str] = None,
            status: Optional[str] = None,
            stream_config_id: Optional[str] = None,
            topic: Optional[str] = None,
            user: Optional[str] = None) -> StreamConfig
    func GetStreamConfig(ctx *Context, name string, id IDInput, state *StreamConfigState, opts ...ResourceOption) (*StreamConfig, error)
    public static StreamConfig Get(string name, Input<string> id, StreamConfigState? state, CustomResourceOptions? opts = null)
    public static StreamConfig get(String name, Output<String> id, StreamConfigState state, CustomResourceOptions options)
    resources:  _:    type: logdna:StreamConfig    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Brokers List<string>
    []string (Required) List of of broker URLs.
    Password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    Status string
    StreamConfigId string
    Topic string
    string (Required) The topic that logs will be published on.
    User string
    string (Required) The SASL username for the connection.
    Brokers []string
    []string (Required) List of of broker URLs.
    Password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    Status string
    StreamConfigId string
    Topic string
    string (Required) The topic that logs will be published on.
    User string
    string (Required) The SASL username for the connection.
    brokers List<String>
    []string (Required) List of of broker URLs.
    password String

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    status String
    streamConfigId String
    topic String
    string (Required) The topic that logs will be published on.
    user String
    string (Required) The SASL username for the connection.
    brokers string[]
    []string (Required) List of of broker URLs.
    password string

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    status string
    streamConfigId string
    topic string
    string (Required) The topic that logs will be published on.
    user string
    string (Required) The SASL username for the connection.
    brokers Sequence[str]
    []string (Required) List of of broker URLs.
    password str

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    status str
    stream_config_id str
    topic str
    string (Required) The topic that logs will be published on.
    user str
    string (Required) The SASL username for the connection.
    brokers List<String>
    []string (Required) List of of broker URLs.
    password String

    string (Required) The SASL password for the connection.

    Note that the provided brokers and credentials must be valid, and the brokers must be reachable when the resource is created or updated. The connection to the broker will be validated before the configuration can be saved.

    status String
    streamConfigId String
    topic String
    string (Required) The topic that logs will be published on.
    user String
    string (Required) The SASL username for the connection.

    Import

    Importing an existing configuration is supported:

    $ pulumi import logdna:index/streamConfig:StreamConfig config stream
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    logdna logdna/terraform-provider-logdna
    License
    Notes
    This Pulumi package is based on the logdna Terraform Provider.
    logdna logo
    logdna 1.16.0 published on Monday, Apr 14, 2025 by logdna