GetScheduledQueryRulesLog

Use this data source to access the properties of a LogToMetricAction scheduled query rule.

Example Usage

using Pulumi;
using Azure = Pulumi.Azure;

class MyStack : Stack
{
    public MyStack()
    {
        var example = Output.Create(Azure.Monitoring.GetScheduledQueryRulesLog.InvokeAsync(new Azure.Monitoring.GetScheduledQueryRulesLogArgs
        {
            Name = "tfex-queryrule",
            ResourceGroupName = "example-rg",
        }));
        this.QueryRuleId = example.Apply(example => example.Id);
    }

    [Output("queryRuleId")]
    public Output<string> QueryRuleId { get; set; }
}
package main

import (
    "github.com/pulumi/pulumi-azure/sdk/v3/go/azure/monitoring"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        example, err := monitoring.LookupScheduledQueryRulesLog(ctx, &monitoring.LookupScheduledQueryRulesLogArgs{
            Name:              "tfex-queryrule",
            ResourceGroupName: "example-rg",
        }, nil)
        if err != nil {
            return err
        }
        ctx.Export("queryRuleId", example.Id)
        return nil
    })
}
import pulumi
import pulumi_azure as azure

example = azure.monitoring.get_scheduled_query_rules_log(name="tfex-queryrule",
    resource_group_name="example-rg")
pulumi.export("queryRuleId", example.id)
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const example = pulumi.output(azure.monitoring.getScheduledQueryRulesLog({
    name: "tfex-queryrule",
    resourceGroupName: "example-rg",
}, { async: true }));

export const queryRuleId = example.id;

Using GetScheduledQueryRulesLog

function getScheduledQueryRulesLog(args: GetScheduledQueryRulesLogArgs, opts?: InvokeOptions): Promise<GetScheduledQueryRulesLogResult>
function  get_scheduled_query_rules_log(name=None, resource_group_name=None, opts=None)
func LookupScheduledQueryRulesLog(ctx *Context, args *LookupScheduledQueryRulesLogArgs, opts ...InvokeOption) (*LookupScheduledQueryRulesLogResult, error)

Note: This function is named LookupScheduledQueryRulesLog in the Go SDK.

public static class GetScheduledQueryRulesLog {
    public static Task<GetScheduledQueryRulesLogResult> InvokeAsync(GetScheduledQueryRulesLogArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Name string

Specifies the name of the scheduled query rule.

ResourceGroupName string

Specifies the name of the resource group where the scheduled query rule is located.

Name string

Specifies the name of the scheduled query rule.

ResourceGroupName string

Specifies the name of the resource group where the scheduled query rule is located.

name string

Specifies the name of the scheduled query rule.

resourceGroupName string

Specifies the name of the resource group where the scheduled query rule is located.

name str

Specifies the name of the scheduled query rule.

resource_group_name str

Specifies the name of the resource group where the scheduled query rule is located.

GetScheduledQueryRulesLog Result

The following output properties are available:

AuthorizedResourceIds List<string>
Criterias List<GetScheduledQueryRulesLogCriteria>

A criteria block as defined below.

DataSourceId string

The resource URI over which log search query is to be run.

Description string

The description of the scheduled query rule.

Enabled bool

Whether this scheduled query rule is enabled.

Id string

The provider-assigned unique ID for this managed resource.

Location string
Name string

Name of the dimension.

ResourceGroupName string
Tags Dictionary<string, string>
AuthorizedResourceIds []string
Criterias []GetScheduledQueryRulesLogCriteria

A criteria block as defined below.

DataSourceId string

The resource URI over which log search query is to be run.

Description string

The description of the scheduled query rule.

Enabled bool

Whether this scheduled query rule is enabled.

Id string

The provider-assigned unique ID for this managed resource.

Location string
Name string

Name of the dimension.

ResourceGroupName string
Tags map[string]string
authorizedResourceIds string[]
criterias GetScheduledQueryRulesLogCriteria[]

A criteria block as defined below.

dataSourceId string

The resource URI over which log search query is to be run.

description string

The description of the scheduled query rule.

enabled boolean

Whether this scheduled query rule is enabled.

id string

The provider-assigned unique ID for this managed resource.

location string
name string

Name of the dimension.

resourceGroupName string
tags {[key: string]: string}
authorized_resource_ids List[str]
criterias List[GetScheduledQueryRulesLogCriteria]

A criteria block as defined below.

data_source_id str

The resource URI over which log search query is to be run.

description str

The description of the scheduled query rule.

enabled bool

Whether this scheduled query rule is enabled.

id str

The provider-assigned unique ID for this managed resource.

location str
name str

Name of the dimension.

resource_group_name str
tags Dict[str, str]

Supporting Types

GetScheduledQueryRulesLogCriteria

See the output API doc for this type.

See the output API doc for this type.

See the output API doc for this type.

Dimensions List<GetScheduledQueryRulesLogCriteriaDimensionArgs>

A dimension block as defined below.

MetricName string

Name of the metric.

Dimensions []GetScheduledQueryRulesLogCriteriaDimension

A dimension block as defined below.

MetricName string

Name of the metric.

dimensions GetScheduledQueryRulesLogCriteriaDimension[]

A dimension block as defined below.

metricName string

Name of the metric.

dimensions List[GetScheduledQueryRulesLogCriteriaDimension]

A dimension block as defined below.

metricName str

Name of the metric.

GetScheduledQueryRulesLogCriteriaDimension

See the output API doc for this type.

See the output API doc for this type.

See the output API doc for this type.

Name string

Specifies the name of the scheduled query rule.

Operator string

Operator for dimension values.

Values List<string>

List of dimension values.

Name string

Specifies the name of the scheduled query rule.

Operator string

Operator for dimension values.

Values []string

List of dimension values.

name string

Specifies the name of the scheduled query rule.

operator string

Operator for dimension values.

values string[]

List of dimension values.

name str

Specifies the name of the scheduled query rule.

operator str

Operator for dimension values.

values List[str]

List of dimension values.

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes
This Pulumi package is based on the azurerm Terraform Provider.