We recommend using Azure Native.
Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi
azure.mssql.getElasticPool
Explore with Pulumi AI
Use this data source to access information about an existing SQL elastic pool.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.mssql.getElasticPool({
name: "mssqlelasticpoolname",
resourceGroupName: "example-resources",
serverName: "example-sql-server",
});
export const elasticpoolId = example.then(example => example.id);
import pulumi
import pulumi_azure as azure
example = azure.mssql.get_elastic_pool(name="mssqlelasticpoolname",
resource_group_name="example-resources",
server_name="example-sql-server")
pulumi.export("elasticpoolId", example.id)
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/mssql"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := mssql.LookupElasticPool(ctx, &mssql.LookupElasticPoolArgs{
Name: "mssqlelasticpoolname",
ResourceGroupName: "example-resources",
ServerName: "example-sql-server",
}, nil)
if err != nil {
return err
}
ctx.Export("elasticpoolId", example.Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = Azure.MSSql.GetElasticPool.Invoke(new()
{
Name = "mssqlelasticpoolname",
ResourceGroupName = "example-resources",
ServerName = "example-sql-server",
});
return new Dictionary<string, object?>
{
["elasticpoolId"] = example.Apply(getElasticPoolResult => getElasticPoolResult.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.mssql.MssqlFunctions;
import com.pulumi.azure.mssql.inputs.GetElasticPoolArgs;
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) {
final var example = MssqlFunctions.getElasticPool(GetElasticPoolArgs.builder()
.name("mssqlelasticpoolname")
.resourceGroupName("example-resources")
.serverName("example-sql-server")
.build());
ctx.export("elasticpoolId", example.applyValue(getElasticPoolResult -> getElasticPoolResult.id()));
}
}
variables:
example:
fn::invoke:
Function: azure:mssql:getElasticPool
Arguments:
name: mssqlelasticpoolname
resourceGroupName: example-resources
serverName: example-sql-server
outputs:
elasticpoolId: ${example.id}
Using getElasticPool
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getElasticPool(args: GetElasticPoolArgs, opts?: InvokeOptions): Promise<GetElasticPoolResult>
function getElasticPoolOutput(args: GetElasticPoolOutputArgs, opts?: InvokeOptions): Output<GetElasticPoolResult>
def get_elastic_pool(name: Optional[str] = None,
resource_group_name: Optional[str] = None,
server_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetElasticPoolResult
def get_elastic_pool_output(name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
server_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetElasticPoolResult]
func LookupElasticPool(ctx *Context, args *LookupElasticPoolArgs, opts ...InvokeOption) (*LookupElasticPoolResult, error)
func LookupElasticPoolOutput(ctx *Context, args *LookupElasticPoolOutputArgs, opts ...InvokeOption) LookupElasticPoolResultOutput
> Note: This function is named LookupElasticPool
in the Go SDK.
public static class GetElasticPool
{
public static Task<GetElasticPoolResult> InvokeAsync(GetElasticPoolArgs args, InvokeOptions? opts = null)
public static Output<GetElasticPoolResult> Invoke(GetElasticPoolInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetElasticPoolResult> getElasticPool(GetElasticPoolArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: azure:mssql/getElasticPool:getElasticPool
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The name of the elastic pool.
- Resource
Group stringName - The name of the resource group which contains the elastic pool.
- Server
Name string - The name of the SQL Server which contains the elastic pool.
- Name string
- The name of the elastic pool.
- Resource
Group stringName - The name of the resource group which contains the elastic pool.
- Server
Name string - The name of the SQL Server which contains the elastic pool.
- name String
- The name of the elastic pool.
- resource
Group StringName - The name of the resource group which contains the elastic pool.
- server
Name String - The name of the SQL Server which contains the elastic pool.
- name string
- The name of the elastic pool.
- resource
Group stringName - The name of the resource group which contains the elastic pool.
- server
Name string - The name of the SQL Server which contains the elastic pool.
- name str
- The name of the elastic pool.
- resource_
group_ strname - The name of the resource group which contains the elastic pool.
- server_
name str - The name of the SQL Server which contains the elastic pool.
- name String
- The name of the elastic pool.
- resource
Group StringName - The name of the resource group which contains the elastic pool.
- server
Name String - The name of the SQL Server which contains the elastic pool.
getElasticPool Result
The following output properties are available:
- Enclave
Type string - The type of enclave being used by the elastic pool.
- Id string
- The provider-assigned unique ID for this managed resource.
- License
Type string - The license type to apply for this elastic pool.
- Location string
- Specifies the supported Azure location where the resource exists.
- Max
Size intBytes - The max data size of the elastic pool in bytes.
- Max
Size doubleGb - The max data size of the elastic pool in gigabytes.
- Name string
- Specifies the SKU Name for this Elasticpool.
- Per
Db intMax Capacity - The maximum capacity any one database can consume.
- Per
Db intMin Capacity - The minimum capacity all databases are guaranteed.
- Resource
Group stringName - Server
Name string - Skus
List<Get
Elastic Pool Skus> - A
sku
block as defined below. - Dictionary<string, string>
- A mapping of tags to assign to the resource.
- Zone
Redundant bool - Whether or not this elastic pool is zone redundant.
- Enclave
Type string - The type of enclave being used by the elastic pool.
- Id string
- The provider-assigned unique ID for this managed resource.
- License
Type string - The license type to apply for this elastic pool.
- Location string
- Specifies the supported Azure location where the resource exists.
- Max
Size intBytes - The max data size of the elastic pool in bytes.
- Max
Size float64Gb - The max data size of the elastic pool in gigabytes.
- Name string
- Specifies the SKU Name for this Elasticpool.
- Per
Db intMax Capacity - The maximum capacity any one database can consume.
- Per
Db intMin Capacity - The minimum capacity all databases are guaranteed.
- Resource
Group stringName - Server
Name string - Skus
[]Get
Elastic Pool Skus - A
sku
block as defined below. - map[string]string
- A mapping of tags to assign to the resource.
- Zone
Redundant bool - Whether or not this elastic pool is zone redundant.
- enclave
Type String - The type of enclave being used by the elastic pool.
- id String
- The provider-assigned unique ID for this managed resource.
- license
Type String - The license type to apply for this elastic pool.
- location String
- Specifies the supported Azure location where the resource exists.
- max
Size IntegerBytes - The max data size of the elastic pool in bytes.
- max
Size DoubleGb - The max data size of the elastic pool in gigabytes.
- name String
- Specifies the SKU Name for this Elasticpool.
- per
Db IntegerMax Capacity - The maximum capacity any one database can consume.
- per
Db IntegerMin Capacity - The minimum capacity all databases are guaranteed.
- resource
Group StringName - server
Name String - skus
List<Get
Elastic Pool Skus> - A
sku
block as defined below. - Map<String,String>
- A mapping of tags to assign to the resource.
- zone
Redundant Boolean - Whether or not this elastic pool is zone redundant.
- enclave
Type string - The type of enclave being used by the elastic pool.
- id string
- The provider-assigned unique ID for this managed resource.
- license
Type string - The license type to apply for this elastic pool.
- location string
- Specifies the supported Azure location where the resource exists.
- max
Size numberBytes - The max data size of the elastic pool in bytes.
- max
Size numberGb - The max data size of the elastic pool in gigabytes.
- name string
- Specifies the SKU Name for this Elasticpool.
- per
Db numberMax Capacity - The maximum capacity any one database can consume.
- per
Db numberMin Capacity - The minimum capacity all databases are guaranteed.
- resource
Group stringName - server
Name string - skus
Get
Elastic Pool Skus[] - A
sku
block as defined below. - {[key: string]: string}
- A mapping of tags to assign to the resource.
- zone
Redundant boolean - Whether or not this elastic pool is zone redundant.
- enclave_
type str - The type of enclave being used by the elastic pool.
- id str
- The provider-assigned unique ID for this managed resource.
- license_
type str - The license type to apply for this elastic pool.
- location str
- Specifies the supported Azure location where the resource exists.
- max_
size_ intbytes - The max data size of the elastic pool in bytes.
- max_
size_ floatgb - The max data size of the elastic pool in gigabytes.
- name str
- Specifies the SKU Name for this Elasticpool.
- per_
db_ intmax_ capacity - The maximum capacity any one database can consume.
- per_
db_ intmin_ capacity - The minimum capacity all databases are guaranteed.
- resource_
group_ strname - server_
name str - skus
Sequence[Get
Elastic Pool Skus] - A
sku
block as defined below. - Mapping[str, str]
- A mapping of tags to assign to the resource.
- zone_
redundant bool - Whether or not this elastic pool is zone redundant.
- enclave
Type String - The type of enclave being used by the elastic pool.
- id String
- The provider-assigned unique ID for this managed resource.
- license
Type String - The license type to apply for this elastic pool.
- location String
- Specifies the supported Azure location where the resource exists.
- max
Size NumberBytes - The max data size of the elastic pool in bytes.
- max
Size NumberGb - The max data size of the elastic pool in gigabytes.
- name String
- Specifies the SKU Name for this Elasticpool.
- per
Db NumberMax Capacity - The maximum capacity any one database can consume.
- per
Db NumberMin Capacity - The minimum capacity all databases are guaranteed.
- resource
Group StringName - server
Name String - skus List<Property Map>
- A
sku
block as defined below. - Map<String>
- A mapping of tags to assign to the resource.
- zone
Redundant Boolean - Whether or not this elastic pool is zone redundant.
Supporting Types
GetElasticPoolSkus
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurerm
Terraform Provider.