All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.alicloud.log.kotlin.OssShipperArgs.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 3.62.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.alicloud.log.kotlin

import com.pulumi.alicloud.log.OssShipperArgs.builder
import com.pulumi.alicloud.log.kotlin.inputs.OssShipperParquetConfigArgs
import com.pulumi.alicloud.log.kotlin.inputs.OssShipperParquetConfigArgsBuilder
import com.pulumi.core.Output
import com.pulumi.core.Output.of
import com.pulumi.kotlin.ConvertibleToJava
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.applySuspend
import kotlin.Boolean
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import kotlin.jvm.JvmName

/**
 * Log service data delivery management, this service provides the function of delivering data in logstore to oss product storage.
 * [Refer to details](https://www.alibabacloud.com/help/en/doc-detail/43724.htm).
 * > **NOTE:** Available in 1.121.0+
 * > **DEPRECATED:**  This resource has been deprecated from version `1.215.0`. Please use new resource alicloud_log_oss_export.
 * ## Example Usage
 * Basic Usage
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as alicloud from "@pulumi/alicloud";
 * import * as random from "@pulumi/random";
 * const _default = new random.index.Integer("default", {
 *     max: 99999,
 *     min: 10000,
 * });
 * const example = new alicloud.log.Project("example", {
 *     name: `terraform-example-${_default.result}`,
 *     description: "terraform-example",
 *     tags: {
 *         Created: "TF",
 *         For: "example",
 *     },
 * });
 * const exampleStore = new alicloud.log.Store("example", {
 *     project: example.name,
 *     name: "example-store",
 *     retentionPeriod: 3650,
 *     autoSplit: true,
 *     maxSplitShardCount: 60,
 *     appendMeta: true,
 * });
 * const exampleOssShipper = new alicloud.log.OssShipper("example", {
 *     projectName: example.name,
 *     logstoreName: exampleStore.name,
 *     shipperName: "terraform-example",
 *     ossBucket: "example_bucket",
 *     ossPrefix: "root",
 *     bufferInterval: 300,
 *     bufferSize: 250,
 *     compressType: "none",
 *     pathFormat: "%Y/%m/%d/%H/%M",
 *     format: "json",
 *     jsonEnableTag: true,
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_alicloud as alicloud
 * import pulumi_random as random
 * default = random.index.Integer("default",
 *     max=99999,
 *     min=10000)
 * example = alicloud.log.Project("example",
 *     name=f"terraform-example-{default['result']}",
 *     description="terraform-example",
 *     tags={
 *         "Created": "TF",
 *         "For": "example",
 *     })
 * example_store = alicloud.log.Store("example",
 *     project=example.name,
 *     name="example-store",
 *     retention_period=3650,
 *     auto_split=True,
 *     max_split_shard_count=60,
 *     append_meta=True)
 * example_oss_shipper = alicloud.log.OssShipper("example",
 *     project_name=example.name,
 *     logstore_name=example_store.name,
 *     shipper_name="terraform-example",
 *     oss_bucket="example_bucket",
 *     oss_prefix="root",
 *     buffer_interval=300,
 *     buffer_size=250,
 *     compress_type="none",
 *     path_format="%Y/%m/%d/%H/%M",
 *     format="json",
 *     json_enable_tag=True)
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using AliCloud = Pulumi.AliCloud;
 * using Random = Pulumi.Random;
 * return await Deployment.RunAsync(() =>
 * {
 *     var @default = new Random.Index.Integer("default", new()
 *     {
 *         Max = 99999,
 *         Min = 10000,
 *     });
 *     var example = new AliCloud.Log.Project("example", new()
 *     {
 *         Name = $"terraform-example-{@default.Result}",
 *         Description = "terraform-example",
 *         Tags =
 *         {
 *             { "Created", "TF" },
 *             { "For", "example" },
 *         },
 *     });
 *     var exampleStore = new AliCloud.Log.Store("example", new()
 *     {
 *         Project = example.Name,
 *         Name = "example-store",
 *         RetentionPeriod = 3650,
 *         AutoSplit = true,
 *         MaxSplitShardCount = 60,
 *         AppendMeta = true,
 *     });
 *     var exampleOssShipper = new AliCloud.Log.OssShipper("example", new()
 *     {
 *         ProjectName = example.Name,
 *         LogstoreName = exampleStore.Name,
 *         ShipperName = "terraform-example",
 *         OssBucket = "example_bucket",
 *         OssPrefix = "root",
 *         BufferInterval = 300,
 *         BufferSize = 250,
 *         CompressType = "none",
 *         PathFormat = "%Y/%m/%d/%H/%M",
 *         Format = "json",
 *         JsonEnableTag = true,
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"fmt"
 * 	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/log"
 * 	"github.com/pulumi/pulumi-random/sdk/v4/go/random"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := random.NewInteger(ctx, "default", &random.IntegerArgs{
 * 			Max: 99999,
 * 			Min: 10000,
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		example, err := log.NewProject(ctx, "example", &log.ProjectArgs{
 * 			Name:        pulumi.Sprintf("terraform-example-%v", _default.Result),
 * 			Description: pulumi.String("terraform-example"),
 * 			Tags: pulumi.StringMap{
 * 				"Created": pulumi.String("TF"),
 * 				"For":     pulumi.String("example"),
 * 			},
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		exampleStore, err := log.NewStore(ctx, "example", &log.StoreArgs{
 * 			Project:            example.Name,
 * 			Name:               pulumi.String("example-store"),
 * 			RetentionPeriod:    pulumi.Int(3650),
 * 			AutoSplit:          pulumi.Bool(true),
 * 			MaxSplitShardCount: pulumi.Int(60),
 * 			AppendMeta:         pulumi.Bool(true),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		_, err = log.NewOssShipper(ctx, "example", &log.OssShipperArgs{
 * 			ProjectName:    example.Name,
 * 			LogstoreName:   exampleStore.Name,
 * 			ShipperName:    pulumi.String("terraform-example"),
 * 			OssBucket:      pulumi.String("example_bucket"),
 * 			OssPrefix:      pulumi.String("root"),
 * 			BufferInterval: pulumi.Int(300),
 * 			BufferSize:     pulumi.Int(250),
 * 			CompressType:   pulumi.String("none"),
 * 			PathFormat:     pulumi.String("%Y/%m/%d/%H/%M"),
 * 			Format:         pulumi.String("json"),
 * 			JsonEnableTag:  pulumi.Bool(true),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.random.integer;
 * import com.pulumi.random.IntegerArgs;
 * import com.pulumi.alicloud.log.Project;
 * import com.pulumi.alicloud.log.ProjectArgs;
 * import com.pulumi.alicloud.log.Store;
 * import com.pulumi.alicloud.log.StoreArgs;
 * import com.pulumi.alicloud.log.OssShipper;
 * import com.pulumi.alicloud.log.OssShipperArgs;
 * 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 default_ = new Integer("default", IntegerArgs.builder()
 *             .max(99999)
 *             .min(10000)
 *             .build());
 *         var example = new Project("example", ProjectArgs.builder()
 *             .name(String.format("terraform-example-%s", default_.result()))
 *             .description("terraform-example")
 *             .tags(Map.ofEntries(
 *                 Map.entry("Created", "TF"),
 *                 Map.entry("For", "example")
 *             ))
 *             .build());
 *         var exampleStore = new Store("exampleStore", StoreArgs.builder()
 *             .project(example.name())
 *             .name("example-store")
 *             .retentionPeriod(3650)
 *             .autoSplit(true)
 *             .maxSplitShardCount(60)
 *             .appendMeta(true)
 *             .build());
 *         var exampleOssShipper = new OssShipper("exampleOssShipper", OssShipperArgs.builder()
 *             .projectName(example.name())
 *             .logstoreName(exampleStore.name())
 *             .shipperName("terraform-example")
 *             .ossBucket("example_bucket")
 *             .ossPrefix("root")
 *             .bufferInterval(300)
 *             .bufferSize(250)
 *             .compressType("none")
 *             .pathFormat("%Y/%m/%d/%H/%M")
 *             .format("json")
 *             .jsonEnableTag(true)
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   default:
 *     type: random:integer
 *     properties:
 *       max: 99999
 *       min: 10000
 *   example:
 *     type: alicloud:log:Project
 *     properties:
 *       name: terraform-example-${default.result}
 *       description: terraform-example
 *       tags:
 *         Created: TF
 *         For: example
 *   exampleStore:
 *     type: alicloud:log:Store
 *     name: example
 *     properties:
 *       project: ${example.name}
 *       name: example-store
 *       retentionPeriod: 3650
 *       autoSplit: true
 *       maxSplitShardCount: 60
 *       appendMeta: true
 *   exampleOssShipper:
 *     type: alicloud:log:OssShipper
 *     name: example
 *     properties:
 *       projectName: ${example.name}
 *       logstoreName: ${exampleStore.name}
 *       shipperName: terraform-example
 *       ossBucket: example_bucket
 *       ossPrefix: root
 *       bufferInterval: 300
 *       bufferSize: 250
 *       compressType: none
 *       pathFormat: '%Y/%m/%d/%H/%M'
 *       format: json
 *       jsonEnableTag: true
 * ```
 * 
 * ## Import
 * Log oss shipper can be imported using the id or name, e.g.
 * ```sh
 * $ pulumi import alicloud:log/ossShipper:OssShipper example tf-log-project:tf-log-logstore:tf-log-shipper
 * ```
 * @property bufferInterval How often is it delivered every interval.
 * @property bufferSize Automatically control the creation interval of delivery tasks and set the upper limit of an OSS object size (calculated in uncompressed), unit: `MB`.
 * @property compressType OSS data storage compression method, support: none, snappy. Among them, none means that the original data is not compressed, and snappy means that the data is compressed using the snappy algorithm, which can reduce the storage space usage of the `OSS Bucket`.
 * @property csvConfigColumns
 * @property csvConfigDelimiter
 * @property csvConfigHeader
 * @property csvConfigLinefeed
 * @property csvConfigNullidentifier
 * @property csvConfigQuote
 * @property format Storage format, only supports three types: `json`, `parquet`, `csv`.
 * **According to the different format, please select the following parameters**
 * - format = `json`
 * `json_enable_tag` - (Optional) Whether to deliver the label.
 * - format = `csv`
 * `csv_config_delimiter` - (Optional) Separator configuration in csv configuration format.
 * `csv_config_columns` - (Optional) Field configuration in csv configuration format.
 * `csv_config_nullidentifier` - (Optional) Invalid field content.
 * `csv_config_quote` - (Optional) Escape character under csv configuration.
 * `csv_config_header` - (Optional) Indicates whether to write the field name to the CSV file, the default value is `false`.
 * `csv_config_linefeed` - (Optional) lineFeed in csv configuration.
 * - format = `parquet`
 * `parquet_config` - (Optional) Configure to use parquet storage format.
 * `name` - (Required) The name of the key.
 * `type` - (Required) Type of configuration name.
 * @property jsonEnableTag
 * @property logstoreName The name of the log logstore.
 * @property ossBucket The name of the oss bucket.
 * @property ossPrefix The data synchronized from Log Service to OSS will be stored in this directory of Bucket.
 * @property parquetConfigs
 * @property pathFormat The OSS Bucket directory is dynamically generated according to the creation time of the shipper task, it cannot start with a forward slash `/`, the default value is `%Y/%m/%d/%H/%M`.
 * @property projectName The name of the log project. It is the only in one Alicloud account.
 * @property roleArn Used for access control, the OSS Bucket owner creates the role mark, such as `acs:ram::13234:role/logrole`
 * @property shipperName Delivery configuration name, it can only contain lowercase letters, numbers, dashes `-` and underscores `_`. It must start and end with lowercase letters or numbers, and the name must be 2 to 128 characters long.
 */
public data class OssShipperArgs(
    public val bufferInterval: Output? = null,
    public val bufferSize: Output? = null,
    public val compressType: Output? = null,
    public val csvConfigColumns: Output>? = null,
    public val csvConfigDelimiter: Output? = null,
    public val csvConfigHeader: Output? = null,
    public val csvConfigLinefeed: Output? = null,
    public val csvConfigNullidentifier: Output? = null,
    public val csvConfigQuote: Output? = null,
    public val format: Output? = null,
    public val jsonEnableTag: Output? = null,
    public val logstoreName: Output? = null,
    public val ossBucket: Output? = null,
    public val ossPrefix: Output? = null,
    public val parquetConfigs: Output>? = null,
    public val pathFormat: Output? = null,
    public val projectName: Output? = null,
    public val roleArn: Output? = null,
    public val shipperName: Output? = null,
) : ConvertibleToJava {
    override fun toJava(): com.pulumi.alicloud.log.OssShipperArgs =
        com.pulumi.alicloud.log.OssShipperArgs.builder()
            .bufferInterval(bufferInterval?.applyValue({ args0 -> args0 }))
            .bufferSize(bufferSize?.applyValue({ args0 -> args0 }))
            .compressType(compressType?.applyValue({ args0 -> args0 }))
            .csvConfigColumns(csvConfigColumns?.applyValue({ args0 -> args0.map({ args0 -> args0 }) }))
            .csvConfigDelimiter(csvConfigDelimiter?.applyValue({ args0 -> args0 }))
            .csvConfigHeader(csvConfigHeader?.applyValue({ args0 -> args0 }))
            .csvConfigLinefeed(csvConfigLinefeed?.applyValue({ args0 -> args0 }))
            .csvConfigNullidentifier(csvConfigNullidentifier?.applyValue({ args0 -> args0 }))
            .csvConfigQuote(csvConfigQuote?.applyValue({ args0 -> args0 }))
            .format(format?.applyValue({ args0 -> args0 }))
            .jsonEnableTag(jsonEnableTag?.applyValue({ args0 -> args0 }))
            .logstoreName(logstoreName?.applyValue({ args0 -> args0 }))
            .ossBucket(ossBucket?.applyValue({ args0 -> args0 }))
            .ossPrefix(ossPrefix?.applyValue({ args0 -> args0 }))
            .parquetConfigs(
                parquetConfigs?.applyValue({ args0 ->
                    args0.map({ args0 ->
                        args0.let({ args0 ->
                            args0.toJava()
                        })
                    })
                }),
            )
            .pathFormat(pathFormat?.applyValue({ args0 -> args0 }))
            .projectName(projectName?.applyValue({ args0 -> args0 }))
            .roleArn(roleArn?.applyValue({ args0 -> args0 }))
            .shipperName(shipperName?.applyValue({ args0 -> args0 })).build()
}

/**
 * Builder for [OssShipperArgs].
 */
@PulumiTagMarker
public class OssShipperArgsBuilder internal constructor() {
    private var bufferInterval: Output? = null

    private var bufferSize: Output? = null

    private var compressType: Output? = null

    private var csvConfigColumns: Output>? = null

    private var csvConfigDelimiter: Output? = null

    private var csvConfigHeader: Output? = null

    private var csvConfigLinefeed: Output? = null

    private var csvConfigNullidentifier: Output? = null

    private var csvConfigQuote: Output? = null

    private var format: Output? = null

    private var jsonEnableTag: Output? = null

    private var logstoreName: Output? = null

    private var ossBucket: Output? = null

    private var ossPrefix: Output? = null

    private var parquetConfigs: Output>? = null

    private var pathFormat: Output? = null

    private var projectName: Output? = null

    private var roleArn: Output? = null

    private var shipperName: Output? = null

    /**
     * @param value How often is it delivered every interval.
     */
    @JvmName("khtdobtuxcalkeoq")
    public suspend fun bufferInterval(`value`: Output) {
        this.bufferInterval = value
    }

    /**
     * @param value Automatically control the creation interval of delivery tasks and set the upper limit of an OSS object size (calculated in uncompressed), unit: `MB`.
     */
    @JvmName("nnwledmuglmkvnsc")
    public suspend fun bufferSize(`value`: Output) {
        this.bufferSize = value
    }

    /**
     * @param value OSS data storage compression method, support: none, snappy. Among them, none means that the original data is not compressed, and snappy means that the data is compressed using the snappy algorithm, which can reduce the storage space usage of the `OSS Bucket`.
     */
    @JvmName("wxsxtrhecbelxqen")
    public suspend fun compressType(`value`: Output) {
        this.compressType = value
    }

    /**
     * @param value
     */
    @JvmName("bmmykjuwxadmowad")
    public suspend fun csvConfigColumns(`value`: Output>) {
        this.csvConfigColumns = value
    }

    @JvmName("gdlarbbblgudjtig")
    public suspend fun csvConfigColumns(vararg values: Output) {
        this.csvConfigColumns = Output.all(values.asList())
    }

    /**
     * @param values
     */
    @JvmName("bpqjvbervqoqgwlv")
    public suspend fun csvConfigColumns(values: List>) {
        this.csvConfigColumns = Output.all(values)
    }

    /**
     * @param value
     */
    @JvmName("fhqroalbnmsrgmvd")
    public suspend fun csvConfigDelimiter(`value`: Output) {
        this.csvConfigDelimiter = value
    }

    /**
     * @param value
     */
    @JvmName("hidlhcvlocwdllla")
    public suspend fun csvConfigHeader(`value`: Output) {
        this.csvConfigHeader = value
    }

    /**
     * @param value
     */
    @JvmName("jaopwxskafkbwuim")
    public suspend fun csvConfigLinefeed(`value`: Output) {
        this.csvConfigLinefeed = value
    }

    /**
     * @param value
     */
    @JvmName("snwdmhptacnaghkj")
    public suspend fun csvConfigNullidentifier(`value`: Output) {
        this.csvConfigNullidentifier = value
    }

    /**
     * @param value
     */
    @JvmName("ckrffmsxhucksyjf")
    public suspend fun csvConfigQuote(`value`: Output) {
        this.csvConfigQuote = value
    }

    /**
     * @param value Storage format, only supports three types: `json`, `parquet`, `csv`.
     * **According to the different format, please select the following parameters**
     * - format = `json`
     * `json_enable_tag` - (Optional) Whether to deliver the label.
     * - format = `csv`
     * `csv_config_delimiter` - (Optional) Separator configuration in csv configuration format.
     * `csv_config_columns` - (Optional) Field configuration in csv configuration format.
     * `csv_config_nullidentifier` - (Optional) Invalid field content.
     * `csv_config_quote` - (Optional) Escape character under csv configuration.
     * `csv_config_header` - (Optional) Indicates whether to write the field name to the CSV file, the default value is `false`.
     * `csv_config_linefeed` - (Optional) lineFeed in csv configuration.
     * - format = `parquet`
     * `parquet_config` - (Optional) Configure to use parquet storage format.
     * `name` - (Required) The name of the key.
     * `type` - (Required) Type of configuration name.
     */
    @JvmName("qkqdbngjfqiguftw")
    public suspend fun format(`value`: Output) {
        this.format = value
    }

    /**
     * @param value
     */
    @JvmName("sdeopwwtijkksyvm")
    public suspend fun jsonEnableTag(`value`: Output) {
        this.jsonEnableTag = value
    }

    /**
     * @param value The name of the log logstore.
     */
    @JvmName("gdlmwsncxobolfas")
    public suspend fun logstoreName(`value`: Output) {
        this.logstoreName = value
    }

    /**
     * @param value The name of the oss bucket.
     */
    @JvmName("qwhgsjqcjfeotivv")
    public suspend fun ossBucket(`value`: Output) {
        this.ossBucket = value
    }

    /**
     * @param value The data synchronized from Log Service to OSS will be stored in this directory of Bucket.
     */
    @JvmName("ckovgjllabxdrkqh")
    public suspend fun ossPrefix(`value`: Output) {
        this.ossPrefix = value
    }

    /**
     * @param value
     */
    @JvmName("ttneqbnhetjysvsh")
    public suspend fun parquetConfigs(`value`: Output>) {
        this.parquetConfigs = value
    }

    @JvmName("ypknqcobgjdhivlh")
    public suspend fun parquetConfigs(vararg values: Output) {
        this.parquetConfigs = Output.all(values.asList())
    }

    /**
     * @param values
     */
    @JvmName("whncguyhilnbndim")
    public suspend fun parquetConfigs(values: List>) {
        this.parquetConfigs = Output.all(values)
    }

    /**
     * @param value The OSS Bucket directory is dynamically generated according to the creation time of the shipper task, it cannot start with a forward slash `/`, the default value is `%Y/%m/%d/%H/%M`.
     */
    @JvmName("efqcunkyfxglcudg")
    public suspend fun pathFormat(`value`: Output) {
        this.pathFormat = value
    }

    /**
     * @param value The name of the log project. It is the only in one Alicloud account.
     */
    @JvmName("nqanhmaloixyfgvw")
    public suspend fun projectName(`value`: Output) {
        this.projectName = value
    }

    /**
     * @param value Used for access control, the OSS Bucket owner creates the role mark, such as `acs:ram::13234:role/logrole`
     */
    @JvmName("btjltwfkicewofqg")
    public suspend fun roleArn(`value`: Output) {
        this.roleArn = value
    }

    /**
     * @param value Delivery configuration name, it can only contain lowercase letters, numbers, dashes `-` and underscores `_`. It must start and end with lowercase letters or numbers, and the name must be 2 to 128 characters long.
     */
    @JvmName("pmsigenvftnkucnr")
    public suspend fun shipperName(`value`: Output) {
        this.shipperName = value
    }

    /**
     * @param value How often is it delivered every interval.
     */
    @JvmName("rjakokryuravforc")
    public suspend fun bufferInterval(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.bufferInterval = mapped
    }

    /**
     * @param value Automatically control the creation interval of delivery tasks and set the upper limit of an OSS object size (calculated in uncompressed), unit: `MB`.
     */
    @JvmName("rbjemrcaefgtrnej")
    public suspend fun bufferSize(`value`: Int?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.bufferSize = mapped
    }

    /**
     * @param value OSS data storage compression method, support: none, snappy. Among them, none means that the original data is not compressed, and snappy means that the data is compressed using the snappy algorithm, which can reduce the storage space usage of the `OSS Bucket`.
     */
    @JvmName("tmxpprfpchqosuql")
    public suspend fun compressType(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.compressType = mapped
    }

    /**
     * @param value
     */
    @JvmName("gjencpmieaveintn")
    public suspend fun csvConfigColumns(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigColumns = mapped
    }

    /**
     * @param values
     */
    @JvmName("trnrrhjdcedbpghf")
    public suspend fun csvConfigColumns(vararg values: String) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.csvConfigColumns = mapped
    }

    /**
     * @param value
     */
    @JvmName("thwycahokbemlgnk")
    public suspend fun csvConfigDelimiter(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigDelimiter = mapped
    }

    /**
     * @param value
     */
    @JvmName("dlgnmaqnporcjupl")
    public suspend fun csvConfigHeader(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigHeader = mapped
    }

    /**
     * @param value
     */
    @JvmName("dumdaogcfcxcmnfm")
    public suspend fun csvConfigLinefeed(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigLinefeed = mapped
    }

    /**
     * @param value
     */
    @JvmName("utyirxjppioagfgl")
    public suspend fun csvConfigNullidentifier(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigNullidentifier = mapped
    }

    /**
     * @param value
     */
    @JvmName("wdkgtuxoubmomonc")
    public suspend fun csvConfigQuote(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.csvConfigQuote = mapped
    }

    /**
     * @param value Storage format, only supports three types: `json`, `parquet`, `csv`.
     * **According to the different format, please select the following parameters**
     * - format = `json`
     * `json_enable_tag` - (Optional) Whether to deliver the label.
     * - format = `csv`
     * `csv_config_delimiter` - (Optional) Separator configuration in csv configuration format.
     * `csv_config_columns` - (Optional) Field configuration in csv configuration format.
     * `csv_config_nullidentifier` - (Optional) Invalid field content.
     * `csv_config_quote` - (Optional) Escape character under csv configuration.
     * `csv_config_header` - (Optional) Indicates whether to write the field name to the CSV file, the default value is `false`.
     * `csv_config_linefeed` - (Optional) lineFeed in csv configuration.
     * - format = `parquet`
     * `parquet_config` - (Optional) Configure to use parquet storage format.
     * `name` - (Required) The name of the key.
     * `type` - (Required) Type of configuration name.
     */
    @JvmName("edecrmvjhmiamegg")
    public suspend fun format(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.format = mapped
    }

    /**
     * @param value
     */
    @JvmName("jwwpsvcijtxhnpfg")
    public suspend fun jsonEnableTag(`value`: Boolean?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.jsonEnableTag = mapped
    }

    /**
     * @param value The name of the log logstore.
     */
    @JvmName("gowjxqfdxaclojtr")
    public suspend fun logstoreName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.logstoreName = mapped
    }

    /**
     * @param value The name of the oss bucket.
     */
    @JvmName("hovpgxrtnhqcocoj")
    public suspend fun ossBucket(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.ossBucket = mapped
    }

    /**
     * @param value The data synchronized from Log Service to OSS will be stored in this directory of Bucket.
     */
    @JvmName("mhuocrdncmccshsr")
    public suspend fun ossPrefix(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.ossPrefix = mapped
    }

    /**
     * @param value
     */
    @JvmName("inpojakblbrogkqp")
    public suspend fun parquetConfigs(`value`: List?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.parquetConfigs = mapped
    }

    /**
     * @param argument
     */
    @JvmName("irignnpcisauplmb")
    public suspend fun parquetConfigs(argument: List Unit>) {
        val toBeMapped = argument.toList().map {
            OssShipperParquetConfigArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.parquetConfigs = mapped
    }

    /**
     * @param argument
     */
    @JvmName("vytobxhsuinfseck")
    public suspend fun parquetConfigs(vararg argument: suspend OssShipperParquetConfigArgsBuilder.() -> Unit) {
        val toBeMapped = argument.toList().map {
            OssShipperParquetConfigArgsBuilder().applySuspend {
                it()
            }.build()
        }
        val mapped = of(toBeMapped)
        this.parquetConfigs = mapped
    }

    /**
     * @param argument
     */
    @JvmName("wcksgenhkgieliwj")
    public suspend fun parquetConfigs(argument: suspend OssShipperParquetConfigArgsBuilder.() -> Unit) {
        val toBeMapped = listOf(
            OssShipperParquetConfigArgsBuilder().applySuspend {
                argument()
            }.build(),
        )
        val mapped = of(toBeMapped)
        this.parquetConfigs = mapped
    }

    /**
     * @param values
     */
    @JvmName("vlhtkuwaupvcphgx")
    public suspend fun parquetConfigs(vararg values: OssShipperParquetConfigArgs) {
        val toBeMapped = values.toList()
        val mapped = toBeMapped.let({ args0 -> of(args0) })
        this.parquetConfigs = mapped
    }

    /**
     * @param value The OSS Bucket directory is dynamically generated according to the creation time of the shipper task, it cannot start with a forward slash `/`, the default value is `%Y/%m/%d/%H/%M`.
     */
    @JvmName("ugfuggkecgylwjls")
    public suspend fun pathFormat(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.pathFormat = mapped
    }

    /**
     * @param value The name of the log project. It is the only in one Alicloud account.
     */
    @JvmName("rqvvwgragbptwlnf")
    public suspend fun projectName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.projectName = mapped
    }

    /**
     * @param value Used for access control, the OSS Bucket owner creates the role mark, such as `acs:ram::13234:role/logrole`
     */
    @JvmName("fndqkbepsbadcoou")
    public suspend fun roleArn(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.roleArn = mapped
    }

    /**
     * @param value Delivery configuration name, it can only contain lowercase letters, numbers, dashes `-` and underscores `_`. It must start and end with lowercase letters or numbers, and the name must be 2 to 128 characters long.
     */
    @JvmName("igdupmskhjfaungm")
    public suspend fun shipperName(`value`: String?) {
        val toBeMapped = value
        val mapped = toBeMapped?.let({ args0 -> of(args0) })
        this.shipperName = mapped
    }

    internal fun build(): OssShipperArgs = OssShipperArgs(
        bufferInterval = bufferInterval,
        bufferSize = bufferSize,
        compressType = compressType,
        csvConfigColumns = csvConfigColumns,
        csvConfigDelimiter = csvConfigDelimiter,
        csvConfigHeader = csvConfigHeader,
        csvConfigLinefeed = csvConfigLinefeed,
        csvConfigNullidentifier = csvConfigNullidentifier,
        csvConfigQuote = csvConfigQuote,
        format = format,
        jsonEnableTag = jsonEnableTag,
        logstoreName = logstoreName,
        ossBucket = ossBucket,
        ossPrefix = ossPrefix,
        parquetConfigs = parquetConfigs,
        pathFormat = pathFormat,
        projectName = projectName,
        roleArn = roleArn,
        shipperName = shipperName,
    )
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy