Application Args
The application resource. API Version: 2020-03-01.
Example Usage
Put an application with maximum parameters
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var application = new AzureNative.ServiceFabric.Application("application", new()
{
ApplicationName = "myApp",
ClusterName = "myCluster",
MaximumNodes = 3,
Metrics = new[]
{
new AzureNative.ServiceFabric.Inputs.ApplicationMetricDescriptionArgs
{
MaximumCapacity = 3,
Name = "metric1",
ReservationCapacity = 1,
TotalApplicationCapacity = 5,
},
},
MinimumNodes = 1,
Parameters =
{
{ "param1", "value1" },
},
RemoveApplicationCapacity = false,
ResourceGroupName = "resRg",
TypeName = "myAppType",
TypeVersion = "1.0",
UpgradePolicy = new AzureNative.ServiceFabric.Inputs.ApplicationUpgradePolicyArgs
{
ApplicationHealthPolicy = new AzureNative.ServiceFabric.Inputs.ArmApplicationHealthPolicyArgs
{
ConsiderWarningAsError = true,
DefaultServiceTypeHealthPolicy = new AzureNative.ServiceFabric.Inputs.ArmServiceTypeHealthPolicyArgs
{
MaxPercentUnhealthyPartitionsPerService = 0,
MaxPercentUnhealthyReplicasPerPartition = 0,
MaxPercentUnhealthyServices = 0,
},
MaxPercentUnhealthyDeployedApplications = 0,
},
ForceRestart = false,
RollingUpgradeMonitoringPolicy = new AzureNative.ServiceFabric.Inputs.ArmRollingUpgradeMonitoringPolicyArgs
{
FailureAction = "Rollback",
HealthCheckRetryTimeout = "00:10:00",
HealthCheckStableDuration = "00:05:00",
HealthCheckWaitDuration = "00:02:00",
UpgradeDomainTimeout = "1.06:00:00",
UpgradeTimeout = "01:00:00",
},
UpgradeMode = "Monitored",
UpgradeReplicaSetCheckTimeout = "01:00:00",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.servicefabric.Application;
import com.pulumi.azurenative.servicefabric.ApplicationArgs;
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 application = new Application("application", ApplicationArgs.builder()
.applicationName("myApp")
.clusterName("myCluster")
.maximumNodes(3)
.metrics(Map.ofEntries(
Map.entry("maximumCapacity", 3),
Map.entry("name", "metric1"),
Map.entry("reservationCapacity", 1),
Map.entry("totalApplicationCapacity", 5)
))
.minimumNodes(1)
.parameters(Map.of("param1", "value1"))
.removeApplicationCapacity(false)
.resourceGroupName("resRg")
.typeName("myAppType")
.typeVersion("1.0")
.upgradePolicy(Map.ofEntries(
Map.entry("applicationHealthPolicy", Map.ofEntries(
Map.entry("considerWarningAsError", true),
Map.entry("defaultServiceTypeHealthPolicy", Map.ofEntries(
Map.entry("maxPercentUnhealthyPartitionsPerService", 0),
Map.entry("maxPercentUnhealthyReplicasPerPartition", 0),
Map.entry("maxPercentUnhealthyServices", 0)
)),
Map.entry("maxPercentUnhealthyDeployedApplications", 0)
)),
Map.entry("forceRestart", false),
Map.entry("rollingUpgradeMonitoringPolicy", Map.ofEntries(
Map.entry("failureAction", "Rollback"),
Map.entry("healthCheckRetryTimeout", "00:10:00"),
Map.entry("healthCheckStableDuration", "00:05:00"),
Map.entry("healthCheckWaitDuration", "00:02:00"),
Map.entry("upgradeDomainTimeout", "1.06:00:00"),
Map.entry("upgradeTimeout", "01:00:00")
)),
Map.entry("upgradeMode", "Monitored"),
Map.entry("upgradeReplicaSetCheckTimeout", "01:00:00")
))
.build());
}
}
Put an application with minimum parameters
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var application = new AzureNative.ServiceFabric.Application("application", new()
{
ApplicationName = "myApp",
ClusterName = "myCluster",
RemoveApplicationCapacity = false,
ResourceGroupName = "resRg",
TypeName = "myAppType",
TypeVersion = "1.0",
});
});
package main
import (
servicefabric "github.com/pulumi/pulumi-azure-native-sdk/servicefabric"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := servicefabric.NewApplication(ctx, "application", &servicefabric.ApplicationArgs{
ApplicationName: pulumi.String("myApp"),
ClusterName: pulumi.String("myCluster"),
RemoveApplicationCapacity: pulumi.Bool(false),
ResourceGroupName: pulumi.String("resRg"),
TypeName: pulumi.String("myAppType"),
TypeVersion: pulumi.String("1.0"),
})
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.servicefabric.Application;
import com.pulumi.azurenative.servicefabric.ApplicationArgs;
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 application = new Application("application", ApplicationArgs.builder()
.applicationName("myApp")
.clusterName("myCluster")
.removeApplicationCapacity(false)
.resourceGroupName("resRg")
.typeName("myAppType")
.typeVersion("1.0")
.build());
}
}
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:servicefabric:Application myCluster /subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/resRg/providers/Microsoft.ServiceFabric/clusters/myCluster/applications/myApp
Constructors
Properties
The name of the application resource.
The name of the cluster resource.
Describes the managed identities for an Azure resource.
List of user assigned identities for the application, each mapped to a friendly name.
The maximum number of nodes where Service Fabric will reserve capacity for this application. Note that this does not mean that the services of this application will be placed on all of those nodes. By default, the value of this property is zero and it means that the services can be placed on any node.
List of application capacity metric description.
The minimum number of nodes where Service Fabric will reserve capacity for this application. Note that this does not mean that the services of this application will be placed on all of those nodes. If this property is set to zero, no capacity will be reserved. The value of this property cannot be more than the value of the MaximumNodes property.
List of application parameters with overridden values from their default values specified in the application manifest.
Remove the current application capacity settings.
The name of the resource group.
The version of the application type as defined in the application manifest.
Describes the policy for a monitored application upgrade.