StreamingJob

class StreamingJob : KotlinCustomResource

A streaming job object, containing all information associated with the named streaming job. Uses Azure REST API version 2020-03-01. In version 1.x of the Azure Native provider, it used API version 2016-03-01. Other available API versions: 2017-04-01-preview, 2021-10-01-preview.

Example Usage

Create a complete streaming job (a streaming job with a transformation, at least 1 input and at least 1 output)

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var streamingJob = new AzureNative.StreamAnalytics.StreamingJob("streamingJob", new()
{
CompatibilityLevel = AzureNative.StreamAnalytics.CompatibilityLevel.CompatibilityLevel_1_0,
DataLocale = "en-US",
EventsLateArrivalMaxDelayInSeconds = 5,
EventsOutOfOrderMaxDelayInSeconds = 0,
EventsOutOfOrderPolicy = AzureNative.StreamAnalytics.EventsOutOfOrderPolicy.Drop,
Functions = new[] {},
Inputs = new[]
{
new AzureNative.StreamAnalytics.Inputs.InputArgs
{
Name = "inputtest",
Properties = new AzureNative.StreamAnalytics.Inputs.StreamInputPropertiesArgs
{
Datasource = new AzureNative.StreamAnalytics.Inputs.BlobStreamInputDataSourceArgs
{
Container = "containerName",
PathPattern = "",
StorageAccounts = new[]
{
new AzureNative.StreamAnalytics.Inputs.StorageAccountArgs
{
AccountKey = "yourAccountKey==",
AccountName = "yourAccountName",
},
},
Type = "Microsoft.Storage/Blob",
},
Serialization = new AzureNative.StreamAnalytics.Inputs.JsonSerializationArgs
{
Encoding = AzureNative.StreamAnalytics.Encoding.UTF8,
Type = "Json",
},
Type = "Stream",
},
},
},
JobName = "sj7804",
Location = "West US",
OutputErrorPolicy = AzureNative.StreamAnalytics.OutputErrorPolicy.Drop,
Outputs = new[]
{
new AzureNative.StreamAnalytics.Inputs.OutputArgs
{
Datasource = new AzureNative.StreamAnalytics.Inputs.AzureSqlDatabaseOutputDataSourceArgs
{
Database = "databaseName",
Password = "userPassword",
Server = "serverName",
Table = "tableName",
Type = "Microsoft.Sql/Server/Database",
User = "<user>",
},
Name = "outputtest",
},
},
ResourceGroupName = "sjrg3276",
Sku = new AzureNative.StreamAnalytics.Inputs.SkuArgs
{
Name = AzureNative.StreamAnalytics.SkuName.Standard,
},
Tags =
{
{ "key1", "value1" },
{ "key3", "value3" },
{ "randomKey", "randomValue" },
},
Transformation = new AzureNative.StreamAnalytics.Inputs.TransformationArgs
{
Name = "transformationtest",
Query = "Select Id, Name from inputtest",
StreamingUnits = 1,
},
});
});
package main
import (
streamanalytics "github.com/pulumi/pulumi-azure-native-sdk/streamanalytics/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := streamanalytics.NewStreamingJob(ctx, "streamingJob", &streamanalytics.StreamingJobArgs{
CompatibilityLevel: pulumi.String(streamanalytics.CompatibilityLevel_1_0),
DataLocale: pulumi.String("en-US"),
EventsLateArrivalMaxDelayInSeconds: pulumi.Int(5),
EventsOutOfOrderMaxDelayInSeconds: pulumi.Int(0),
EventsOutOfOrderPolicy: pulumi.String(streamanalytics.EventsOutOfOrderPolicyDrop),
Functions: streamanalytics.FunctionTypeArray{},
Inputs: streamanalytics.InputTypeArray{
&streamanalytics.InputTypeArgs{
Name: pulumi.String("inputtest"),
Properties: streamanalytics.StreamInputProperties{
Datasource: streamanalytics.BlobStreamInputDataSource{
Container: "containerName",
PathPattern: "",
StorageAccounts: []streamanalytics.StorageAccount{
{
AccountKey: "yourAccountKey==",
AccountName: "yourAccountName",
},
},
Type: "Microsoft.Storage/Blob",
},
Serialization: streamanalytics.JsonSerialization{
Encoding: streamanalytics.EncodingUTF8,
Type: "Json",
},
Type: "Stream",
},
},
},
JobName: pulumi.String("sj7804"),
Location: pulumi.String("West US"),
OutputErrorPolicy: pulumi.String(streamanalytics.OutputErrorPolicyDrop),
Outputs: streamanalytics.OutputTypeArray{
&streamanalytics.OutputTypeArgs{
Datasource: streamanalytics.AzureSqlDatabaseOutputDataSource{
Database: "databaseName",
Password: "userPassword",
Server: "serverName",
Table: "tableName",
Type: "Microsoft.Sql/Server/Database",
User: "<user>",
},
Name: pulumi.String("outputtest"),
},
},
ResourceGroupName: pulumi.String("sjrg3276"),
Sku: &streamanalytics.SkuArgs{
Name: pulumi.String(streamanalytics.SkuNameStandard),
},
Tags: pulumi.StringMap{
"key1": pulumi.String("value1"),
"key3": pulumi.String("value3"),
"randomKey": pulumi.String("randomValue"),
},
Transformation: &streamanalytics.TransformationArgs{
Name: pulumi.String("transformationtest"),
Query: pulumi.String("Select Id, Name from inputtest"),
StreamingUnits: pulumi.Int(1),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.streamanalytics.StreamingJob;
import com.pulumi.azurenative.streamanalytics.StreamingJobArgs;
import com.pulumi.azurenative.streamanalytics.inputs.InputArgs;
import com.pulumi.azurenative.streamanalytics.inputs.OutputArgs;
import com.pulumi.azurenative.streamanalytics.inputs.SkuArgs;
import com.pulumi.azurenative.streamanalytics.inputs.TransformationArgs;
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 streamingJob = new StreamingJob("streamingJob", StreamingJobArgs.builder()
.compatibilityLevel("1.0")
.dataLocale("en-US")
.eventsLateArrivalMaxDelayInSeconds(5)
.eventsOutOfOrderMaxDelayInSeconds(0)
.eventsOutOfOrderPolicy("Drop")
.functions()
.inputs(InputArgs.builder()
.name("inputtest")
.properties(StreamInputPropertiesArgs.builder()
.datasource(BlobStreamInputDataSourceArgs.builder()
.container("containerName")
.pathPattern("")
.storageAccounts(StorageAccountArgs.builder()
.accountKey("yourAccountKey==")
.accountName("yourAccountName")
.build())
.type("Microsoft.Storage/Blob")
.build())
.serialization(JsonSerializationArgs.builder()
.encoding("UTF8")
.type("Json")
.build())
.type("Stream")
.build())
.build())
.jobName("sj7804")
.location("West US")
.outputErrorPolicy("Drop")
.outputs(OutputArgs.builder()
.datasource(AzureDataLakeStoreOutputDataSourceArgs.builder()
.database("databaseName")
.password("userPassword")
.server("serverName")
.table("tableName")
.type("Microsoft.Sql/Server/Database")
.user("<user>")
.build())
.name("outputtest")
.build())
.resourceGroupName("sjrg3276")
.sku(SkuArgs.builder()
.name("Standard")
.build())
.tags(Map.ofEntries(
Map.entry("key1", "value1"),
Map.entry("key3", "value3"),
Map.entry("randomKey", "randomValue")
))
.transformation(TransformationArgs.builder()
.name("transformationtest")
.query("Select Id, Name from inputtest")
.streamingUnits(1)
.build())
.build());
}
}

Create a streaming job shell (a streaming job with no inputs, outputs, transformation, or functions)

using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var streamingJob = new AzureNative.StreamAnalytics.StreamingJob("streamingJob", new()
{
CompatibilityLevel = AzureNative.StreamAnalytics.CompatibilityLevel.CompatibilityLevel_1_0,
DataLocale = "en-US",
EventsLateArrivalMaxDelayInSeconds = 16,
EventsOutOfOrderMaxDelayInSeconds = 5,
EventsOutOfOrderPolicy = AzureNative.StreamAnalytics.EventsOutOfOrderPolicy.Drop,
Functions = new[] {},
Inputs = new[] {},
JobName = "sj59",
Location = "West US",
OutputErrorPolicy = AzureNative.StreamAnalytics.OutputErrorPolicy.Drop,
Outputs = new[] {},
ResourceGroupName = "sjrg6936",
Sku = new AzureNative.StreamAnalytics.Inputs.SkuArgs
{
Name = AzureNative.StreamAnalytics.SkuName.Standard,
},
Tags =
{
{ "key1", "value1" },
{ "key3", "value3" },
{ "randomKey", "randomValue" },
},
});
});
package main
import (
streamanalytics "github.com/pulumi/pulumi-azure-native-sdk/streamanalytics/v2"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := streamanalytics.NewStreamingJob(ctx, "streamingJob", &streamanalytics.StreamingJobArgs{
CompatibilityLevel: pulumi.String(streamanalytics.CompatibilityLevel_1_0),
DataLocale: pulumi.String("en-US"),
EventsLateArrivalMaxDelayInSeconds: pulumi.Int(16),
EventsOutOfOrderMaxDelayInSeconds: pulumi.Int(5),
EventsOutOfOrderPolicy: pulumi.String(streamanalytics.EventsOutOfOrderPolicyDrop),
Functions: streamanalytics.FunctionTypeArray{},
Inputs: streamanalytics.InputTypeArray{},
JobName: pulumi.String("sj59"),
Location: pulumi.String("West US"),
OutputErrorPolicy: pulumi.String(streamanalytics.OutputErrorPolicyDrop),
Outputs: streamanalytics.OutputTypeArray{},
ResourceGroupName: pulumi.String("sjrg6936"),
Sku: &streamanalytics.SkuArgs{
Name: pulumi.String(streamanalytics.SkuNameStandard),
},
Tags: pulumi.StringMap{
"key1": pulumi.String("value1"),
"key3": pulumi.String("value3"),
"randomKey": pulumi.String("randomValue"),
},
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.streamanalytics.StreamingJob;
import com.pulumi.azurenative.streamanalytics.StreamingJobArgs;
import com.pulumi.azurenative.streamanalytics.inputs.SkuArgs;
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 streamingJob = new StreamingJob("streamingJob", StreamingJobArgs.builder()
.compatibilityLevel("1.0")
.dataLocale("en-US")
.eventsLateArrivalMaxDelayInSeconds(16)
.eventsOutOfOrderMaxDelayInSeconds(5)
.eventsOutOfOrderPolicy("Drop")
.functions()
.inputs()
.jobName("sj59")
.location("West US")
.outputErrorPolicy("Drop")
.outputs()
.resourceGroupName("sjrg6936")
.sku(SkuArgs.builder()
.name("Standard")
.build())
.tags(Map.ofEntries(
Map.entry("key1", "value1"),
Map.entry("key3", "value3"),
Map.entry("randomKey", "randomValue")
))
.build());
}
}

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:streamanalytics:StreamingJob sj59 /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.StreamAnalytics/streamingjobs/{jobName}

Properties

Link copied to clipboard

The cluster which streaming jobs will run on.

Link copied to clipboard

Controls certain runtime behaviors of the streaming job.

Link copied to clipboard

Valid values are JobStorageAccount and SystemAccount. If set to JobStorageAccount, this requires the user to also specify jobStorageAccount property. .

Link copied to clipboard
val createdDate: Output<String>

Value is an ISO-8601 formatted UTC timestamp indicating when the streaming job was created.

Link copied to clipboard
val dataLocale: Output<String>?

The data locale of the stream analytics job. Value should be the name of a supported .NET Culture from the set https://msdn.microsoft.com/en-us/library/system.globalization.culturetypes(v=vs.110).aspx. Defaults to 'en-US' if none specified.

Link copied to clipboard
val etag: Output<String>

The current entity tag for the streaming job. This is an opaque string. You can use it to detect whether the resource has changed between requests. You can also use it in the If-Match or If-None-Match headers for write operations for optimistic concurrency.

Link copied to clipboard

The maximum tolerable delay in seconds where events arriving late could be included. Supported range is -1 to 1814399 (20.23:59:59 days) and -1 is used to specify wait indefinitely. If the property is absent, it is interpreted to have a value of -1.

Link copied to clipboard

The maximum tolerable delay in seconds where out-of-order events can be adjusted to be back in order.

Link copied to clipboard

Indicates the policy to apply to events that arrive out of order in the input event stream.

Link copied to clipboard

A list of one or more functions for the streaming job. The name property for each function is required when specifying this property in a PUT request. This property cannot be modify via a PATCH operation. You must use the PATCH API available for the individual transformation.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard

Describes the system-assigned managed identity assigned to this job that can be used to authenticate with inputs and outputs.

Link copied to clipboard
val inputs: Output<List<InputResponse>>?

A list of one or more inputs to the streaming job. The name property for each input is required when specifying this property in a PUT request. This property cannot be modify via a PATCH operation. You must use the PATCH API available for the individual input.

Link copied to clipboard
val jobId: Output<String>

A GUID uniquely identifying the streaming job. This GUID is generated upon creation of the streaming job.

Link copied to clipboard
val jobState: Output<String>

Describes the state of the streaming job.

Link copied to clipboard

The properties that are associated with an Azure Storage account with MSI

Link copied to clipboard
val jobType: Output<String>?

Describes the type of the job. Valid modes are Cloud and 'Edge'.

Link copied to clipboard

Value is either an ISO-8601 formatted timestamp indicating the last output event time of the streaming job or null indicating that output has not yet been produced. In case of multiple outputs or multiple streams, this shows the latest value in that set.

Link copied to clipboard
val location: Output<String>?

The geo-location where the resource lives

Link copied to clipboard
val name: Output<String>

The name of the resource

Link copied to clipboard

Indicates the policy to apply to events that arrive at the output and cannot be written to the external storage due to being malformed (missing column values, column values of wrong type or size).

Link copied to clipboard
val outputs: Output<List<OutputResponse>>?

A list of one or more outputs for the streaming job. The name property for each output is required when specifying this property in a PUT request. This property cannot be modify via a PATCH operation. You must use the PATCH API available for the individual output.

Link copied to clipboard
val outputStartMode: Output<String>?

This property should only be utilized when it is desired that the job be started immediately upon creation. Value may be JobStartTime, CustomTime, or LastOutputEventTime to indicate whether the starting point of the output event stream should start whenever the job is started, start at a custom user time stamp specified via the outputStartTime property, or start from the last event output time.

Link copied to clipboard
val outputStartTime: Output<String>?

Value is either an ISO-8601 formatted time stamp that indicates the starting point of the output event stream, or null to indicate that the output event stream will start whenever the streaming job is started. This property must have a value if outputStartMode is set to CustomTime.

Link copied to clipboard

Describes the provisioning status of the streaming job.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val sku: Output<SkuResponse>?

Describes the SKU of the streaming job. Required on PUT (CreateOrReplace) requests.

Link copied to clipboard
val tags: Output<Map<String, String>>?

Resource tags.

Link copied to clipboard

Indicates the query and the number of streaming units to use for the streaming job. The name property of the transformation is required when specifying this property in a PUT request. This property cannot be modify via a PATCH operation. You must use the PATCH API available for the individual transformation.

Link copied to clipboard
val type: Output<String>

The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts.

Link copied to clipboard
val urn: Output<String>