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

com.azure.resourcemanager.avs.models.Cluster Maven / Gradle / Ivy

Go to download

This package contains Microsoft Azure SDK for Avs Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Azure VMware Solution API. Package tag package-2023-09-01.

The newest version!
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.avs.models;

import com.azure.core.http.rest.Response;
import com.azure.core.management.SystemData;
import com.azure.core.util.Context;
import com.azure.resourcemanager.avs.fluent.models.ClusterInner;
import java.util.List;

/**
 * An immutable client-side representation of Cluster.
 */
public interface Cluster {
    /**
     * Gets the id property: Fully qualified resource Id for the resource.
     * 
     * @return the id value.
     */
    String id();

    /**
     * Gets the name property: The name of the resource.
     * 
     * @return the name value.
     */
    String name();

    /**
     * Gets the type property: The type of the resource.
     * 
     * @return the type value.
     */
    String type();

    /**
     * Gets the sku property: The SKU (Stock Keeping Unit) assigned to this resource.
     * 
     * @return the sku value.
     */
    Sku sku();

    /**
     * Gets the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
     * 
     * @return the systemData value.
     */
    SystemData systemData();

    /**
     * Gets the clusterSize property: The cluster size.
     * 
     * @return the clusterSize value.
     */
    Integer clusterSize();

    /**
     * Gets the provisioningState property: The state of the cluster provisioning.
     * 
     * @return the provisioningState value.
     */
    ClusterProvisioningState provisioningState();

    /**
     * Gets the clusterId property: The identity.
     * 
     * @return the clusterId value.
     */
    Integer clusterId();

    /**
     * Gets the hosts property: The hosts.
     * 
     * @return the hosts value.
     */
    List hosts();

    /**
     * Gets the vsanDatastoreName property: Name of the vsan datastore associated with the cluster.
     * 
     * @return the vsanDatastoreName value.
     */
    String vsanDatastoreName();

    /**
     * Gets the name of the resource group.
     * 
     * @return the name of the resource group.
     */
    String resourceGroupName();

    /**
     * Gets the inner com.azure.resourcemanager.avs.fluent.models.ClusterInner object.
     * 
     * @return the inner object.
     */
    ClusterInner innerModel();

    /**
     * The entirety of the Cluster definition.
     */
    interface Definition extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithSku,
        DefinitionStages.WithCreate {
    }

    /**
     * The Cluster definition stages.
     */
    interface DefinitionStages {
        /**
         * The first stage of the Cluster definition.
         */
        interface Blank extends WithParentResource {
        }

        /**
         * The stage of the Cluster definition allowing to specify parent resource.
         */
        interface WithParentResource {
            /**
             * Specifies resourceGroupName, privateCloudName.
             * 
             * @param resourceGroupName The name of the resource group. The name is case insensitive.
             * @param privateCloudName Name of the private cloud.
             * @return the next definition stage.
             */
            WithSku withExistingPrivateCloud(String resourceGroupName, String privateCloudName);
        }

        /**
         * The stage of the Cluster definition allowing to specify sku.
         */
        interface WithSku {
            /**
             * Specifies the sku property: The SKU (Stock Keeping Unit) assigned to this resource..
             * 
             * @param sku The SKU (Stock Keeping Unit) assigned to this resource.
             * @return the next definition stage.
             */
            WithCreate withSku(Sku sku);
        }

        /**
         * The stage of the Cluster definition which contains all the minimum required properties for the resource to be
         * created, but also allows for any other optional properties to be specified.
         */
        interface WithCreate extends DefinitionStages.WithClusterSize, DefinitionStages.WithHosts,
            DefinitionStages.WithVsanDatastoreName {
            /**
             * Executes the create request.
             * 
             * @return the created resource.
             */
            Cluster create();

            /**
             * Executes the create request.
             * 
             * @param context The context to associate with this operation.
             * @return the created resource.
             */
            Cluster create(Context context);
        }

        /**
         * The stage of the Cluster definition allowing to specify clusterSize.
         */
        interface WithClusterSize {
            /**
             * Specifies the clusterSize property: The cluster size.
             * 
             * @param clusterSize The cluster size.
             * @return the next definition stage.
             */
            WithCreate withClusterSize(Integer clusterSize);
        }

        /**
         * The stage of the Cluster definition allowing to specify hosts.
         */
        interface WithHosts {
            /**
             * Specifies the hosts property: The hosts.
             * 
             * @param hosts The hosts.
             * @return the next definition stage.
             */
            WithCreate withHosts(List hosts);
        }

        /**
         * The stage of the Cluster definition allowing to specify vsanDatastoreName.
         */
        interface WithVsanDatastoreName {
            /**
             * Specifies the vsanDatastoreName property: Name of the vsan datastore associated with the cluster.
             * 
             * @param vsanDatastoreName Name of the vsan datastore associated with the cluster.
             * @return the next definition stage.
             */
            WithCreate withVsanDatastoreName(String vsanDatastoreName);
        }
    }

    /**
     * Begins update for the Cluster resource.
     * 
     * @return the stage of resource update.
     */
    Cluster.Update update();

    /**
     * The template for Cluster update.
     */
    interface Update extends UpdateStages.WithSku, UpdateStages.WithClusterSize, UpdateStages.WithHosts {
        /**
         * Executes the update request.
         * 
         * @return the updated resource.
         */
        Cluster apply();

        /**
         * Executes the update request.
         * 
         * @param context The context to associate with this operation.
         * @return the updated resource.
         */
        Cluster apply(Context context);
    }

    /**
     * The Cluster update stages.
     */
    interface UpdateStages {
        /**
         * The stage of the Cluster update allowing to specify sku.
         */
        interface WithSku {
            /**
             * Specifies the sku property: The SKU (Stock Keeping Unit) assigned to this resource..
             * 
             * @param sku The SKU (Stock Keeping Unit) assigned to this resource.
             * @return the next definition stage.
             */
            Update withSku(Sku sku);
        }

        /**
         * The stage of the Cluster update allowing to specify clusterSize.
         */
        interface WithClusterSize {
            /**
             * Specifies the clusterSize property: The cluster size.
             * 
             * @param clusterSize The cluster size.
             * @return the next definition stage.
             */
            Update withClusterSize(Integer clusterSize);
        }

        /**
         * The stage of the Cluster update allowing to specify hosts.
         */
        interface WithHosts {
            /**
             * Specifies the hosts property: The hosts.
             * 
             * @param hosts The hosts.
             * @return the next definition stage.
             */
            Update withHosts(List hosts);
        }
    }

    /**
     * Refreshes the resource to sync with Azure.
     * 
     * @return the refreshed resource.
     */
    Cluster refresh();

    /**
     * Refreshes the resource to sync with Azure.
     * 
     * @param context The context to associate with this operation.
     * @return the refreshed resource.
     */
    Cluster refresh(Context context);

    /**
     * List hosts by zone in a cluster.
     * 
     * @param context The context to associate with this operation.
     * @throws IllegalArgumentException thrown if parameters fail the validation.
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return list of all zones and associated hosts for a cluster along with {@link Response}.
     */
    Response listZonesWithResponse(Context context);

    /**
     * List hosts by zone in a cluster.
     * 
     * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
     * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
     * @return list of all zones and associated hosts for a cluster.
     */
    ClusterZoneList listZones();
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy