Создает новую общую папку под указанной учетной записью, как описано текстом запроса. Ресурс общего ресурса содержит метаданные и свойства для этой общей папки. Он не содержит список файлов, содержащихся в общей папке.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/fileServices/default/shares/{shareName}?api-version=2024-01-01
С использованием необязательных параметров:
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/fileServices/default/shares/{shareName}?$expand={$expand}&api-version=2024-01-01
Параметры URI
Имя |
В |
Обязательно |
Тип |
Описание |
accountName
|
path |
True
|
string
minLength: 3 maxLength: 24 pattern: ^[a-z0-9]+$
|
Имя учетной записи хранения в указанной группе ресурсов. Имена учетных записей хранения должны быть от 3 до 24 символов длиной и использовать только цифры и строчные буквы.
|
resourceGroupName
|
path |
True
|
string
minLength: 1 maxLength: 90 pattern: ^[-\w\._\(\)]+$
|
Имя группы ресурсов в подписке пользователя. Имя не зависит от регистра.
|
shareName
|
path |
True
|
string
minLength: 3 maxLength: 63
|
Имя общей папки в указанной учетной записи хранения. Имена общих папок должны быть от 3 до 63 символов длиной и использовать цифры, строчные буквы и дефисы (-). Каждый тире (-) должен быть немедленно предшествуем и за ним следует буква или число.
|
subscriptionId
|
path |
True
|
string
minLength: 1
|
Идентификатор целевой подписки.
|
api-version
|
query |
True
|
string
minLength: 1
|
Версия API, используемая для данной операции.
|
$expand
|
query |
|
string
|
Необязательный, используемый для расширения свойств общего ресурса. Допустимые значения: моментальные снимки. Должен передаваться в виде строки с разделителем ","
|
Текст запроса
Имя |
Тип |
Описание |
properties.accessTier
|
ShareAccessTier
|
Уровень доступа для определенной общей папки. Учетная запись GpV2 может выбирать между TransactionOptimized (по умолчанию), горячей и холодной. Учетная запись FileStorage может выбрать Premium.
|
properties.enabledProtocols
|
EnabledProtocols
|
Протокол проверки подлинности, используемый для общей папки. Можно указать только при создании общей папки.
|
properties.fileSharePaidBursting
|
FileSharePaidBursting
|
Свойства платного ускорения общей папки.
|
properties.metadata
|
object
|
Пара "имя-значение", связанная с общей папкой в качестве метаданных.
|
properties.provisionedBandwidthMibps
|
integer
(int32)
|
Подготовленная пропускная способность общей папки в мбибайтах в секунду. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2. Обратитесь к ответу API GetFileServiceUsage для минимального и максимального допустимого значения подготовленной пропускной способности.
|
properties.provisionedIops
|
integer
(int32)
|
Подготовленные операции ввода-вывода в секунду общего ресурса. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2. Обратитесь к ответу API GetFileServiceUsage минимальное и максимально допустимое значение для подготовленных операций ввода-вывода в секунду.
|
properties.rootSquash
|
RootSquashType
|
Свойство предназначено только для общего ресурса NFS. Значение по умолчанию — NoRootSquash.
|
properties.shareQuota
|
integer
(int32)
|
Подготовленный размер общей папки в гибибайтах. Должно быть больше 0 и меньше или равно 5TB (5120). Для больших общих папок максимальный размер — 102400. Для общих папок, созданных в разделе "Подготовленные файлы" типа учетной записи версии 2, обратитесь к ответу API GetFileServiceUsage для минимального и максимального допустимого размера подготовленного хранилища.
|
properties.signedIdentifiers
|
SignedIdentifier[]
|
Список хранимых политик доступа, указанных в общей папке.
|
Ответы
Имя |
Тип |
Описание |
200 OK
|
FileShare
|
ОК- Общий ресурс уже создан.
|
201 Created
|
FileShare
|
Создано — операция создания общего ресурса успешно завершена.
|
Other Status Codes
|
CloudError
|
Ответ на ошибку, описывающий причину сбоя операции.
|
Безопасность
azure_auth
Поток OAuth2 Azure Active Directory
Тип:
oauth2
Flow:
implicit
URL-адрес авторизации:
https://login.microsoftonline.com/common/oauth2/authorize
Области
Имя |
Описание |
user_impersonation
|
олицетворения учетной записи пользователя
|
Примеры
Create NFS Shares
Образец запроса
PUT https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235?api-version=2024-01-01
{
"properties": {
"enabledProtocols": "NFS"
}
}
import com.azure.resourcemanager.storage.fluent.models.FileShareInner;
import com.azure.resourcemanager.storage.models.EnabledProtocols;
/**
* Samples for FileShares Create.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json
*/
/**
* Sample code: Create NFS Shares.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void createNFSShares(com.azure.resourcemanager.AzureResourceManager azure) {
azure.storageAccounts().manager().serviceClient().getFileShares().createWithResponse("res346", "sto666",
"share1235", new FileShareInner().withEnabledProtocols(EnabledProtocols.NFS), null,
com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/86c6306649b02e542117adb46c61e8019dbd78e9/specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json
func ExampleFileSharesClient_Create_createNfsShares() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewFileSharesClient().Create(ctx, "res346", "sto666", "share1235", armstorage.FileShare{
FileShareProperties: &armstorage.FileShareProperties{
EnabledProtocols: to.Ptr(armstorage.EnabledProtocolsNFS),
},
}, &armstorage.FileSharesClientCreateOptions{Expand: nil})
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.FileShare = armstorage.FileShare{
// Name: to.Ptr("share1235"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts/fileServices/shares"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235"),
// FileShareProperties: &armstorage.FileShareProperties{
// EnabledProtocols: to.Ptr(armstorage.EnabledProtocolsNFS),
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
require("dotenv/config");
/**
* This sample demonstrates how to Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
*
* @summary Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
* x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json
*/
async function createNfsShares() {
const subscriptionId = process.env["STORAGE_SUBSCRIPTION_ID"] || "{subscription-id}";
const resourceGroupName = process.env["STORAGE_RESOURCE_GROUP"] || "res346";
const accountName = "sto666";
const shareName = "share1235";
const fileShare = { enabledProtocols: "NFS" };
const credential = new DefaultAzureCredential();
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.fileShares.create(
resourceGroupName,
accountName,
shareName,
fileShare,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using Azure;
using Azure.ResourceManager;
using System;
using System.Threading.Tasks;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager.Storage.Models;
using Azure.ResourceManager.Storage;
// Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json
// this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this FileServiceResource created on azure
// for more information of creating FileServiceResource, please refer to the document of FileServiceResource
string subscriptionId = "{subscription-id}";
string resourceGroupName = "res346";
string accountName = "sto666";
ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName);
FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId);
// get the collection of this FileShareResource
FileShareCollection collection = fileService.GetFileShares();
// invoke the operation
string shareName = "share1235";
FileShareData data = new FileShareData
{
EnabledProtocol = FileShareEnabledProtocol.Nfs,
};
ArmOperation<FileShareResource> lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data);
FileShareResource result = lro.Value;
// the variable result is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
FileShareData resourceData = result.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python file_shares_put_nfs.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="{subscription-id}",
)
response = client.file_shares.create(
resource_group_name="res346",
account_name="sto666",
share_name="share1235",
file_share={"properties": {"enabledProtocols": "NFS"}},
)
print(response)
# x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_NFS.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Пример ответа
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"enabledProtocols": "NFS"
}
}
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"enabledProtocols": "NFS"
}
}
PutShares
Образец запроса
PUT https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res3376/providers/Microsoft.Storage/storageAccounts/sto328/fileServices/default/shares/share6185?api-version=2024-01-01
{}
import com.azure.resourcemanager.storage.fluent.models.FileShareInner;
/**
* Samples for FileShares Create.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut.json
*/
/**
* Sample code: PutShares.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void putShares(com.azure.resourcemanager.AzureResourceManager azure) {
azure.storageAccounts().manager().serviceClient().getFileShares().createWithResponse("res3376", "sto328",
"share6185", new FileShareInner(), null, com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/86c6306649b02e542117adb46c61e8019dbd78e9/specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut.json
func ExampleFileSharesClient_Create_putShares() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewFileSharesClient().Create(ctx, "res3376", "sto328", "share6185", armstorage.FileShare{}, &armstorage.FileSharesClientCreateOptions{Expand: nil})
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.FileShare = armstorage.FileShare{
// Name: to.Ptr("share6185"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts/fileServices/shares"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res3376/providers/Microsoft.Storage/storageAccounts/sto328/fileServices/default/shares/share6185"),
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
require("dotenv/config");
/**
* This sample demonstrates how to Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
*
* @summary Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
* x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut.json
*/
async function putShares() {
const subscriptionId = process.env["STORAGE_SUBSCRIPTION_ID"] || "{subscription-id}";
const resourceGroupName = process.env["STORAGE_RESOURCE_GROUP"] || "res3376";
const accountName = "sto328";
const shareName = "share6185";
const fileShare = {};
const credential = new DefaultAzureCredential();
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.fileShares.create(
resourceGroupName,
accountName,
shareName,
fileShare,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using Azure;
using Azure.ResourceManager;
using System;
using System.Threading.Tasks;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager.Storage.Models;
using Azure.ResourceManager.Storage;
// Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut.json
// this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this FileServiceResource created on azure
// for more information of creating FileServiceResource, please refer to the document of FileServiceResource
string subscriptionId = "{subscription-id}";
string resourceGroupName = "res3376";
string accountName = "sto328";
ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName);
FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId);
// get the collection of this FileShareResource
FileShareCollection collection = fileService.GetFileShares();
// invoke the operation
string shareName = "share6185";
FileShareData data = new FileShareData();
ArmOperation<FileShareResource> lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data);
FileShareResource result = lro.Value;
// the variable result is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
FileShareData resourceData = result.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Пример ответа
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res3376/providers/Microsoft.Storage/storageAccounts/sto328/fileServices/default/shares/share6185",
"name": "share6185",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares"
}
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res3376/providers/Microsoft.Storage/storageAccounts/sto328/fileServices/default/shares/share6185",
"name": "share6185",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares"
}
PutShares with Access Tier
Образец запроса
PUT https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235?api-version=2024-01-01
{
"properties": {
"accessTier": "Hot"
}
}
import com.azure.resourcemanager.storage.fluent.models.FileShareInner;
import com.azure.resourcemanager.storage.models.ShareAccessTier;
/**
* Samples for FileShares Create.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json
*/
/**
* Sample code: PutShares with Access Tier.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void putSharesWithAccessTier(com.azure.resourcemanager.AzureResourceManager azure) {
azure.storageAccounts().manager().serviceClient().getFileShares().createWithResponse("res346", "sto666",
"share1235", new FileShareInner().withAccessTier(ShareAccessTier.HOT), null,
com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/86c6306649b02e542117adb46c61e8019dbd78e9/specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json
func ExampleFileSharesClient_Create_putSharesWithAccessTier() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewFileSharesClient().Create(ctx, "res346", "sto666", "share1235", armstorage.FileShare{
FileShareProperties: &armstorage.FileShareProperties{
AccessTier: to.Ptr(armstorage.ShareAccessTierHot),
},
}, &armstorage.FileSharesClientCreateOptions{Expand: nil})
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.FileShare = armstorage.FileShare{
// Name: to.Ptr("share1235"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts/fileServices/shares"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235"),
// FileShareProperties: &armstorage.FileShareProperties{
// AccessTier: to.Ptr(armstorage.ShareAccessTierHot),
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
require("dotenv/config");
/**
* This sample demonstrates how to Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
*
* @summary Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
* x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json
*/
async function putSharesWithAccessTier() {
const subscriptionId = process.env["STORAGE_SUBSCRIPTION_ID"] || "{subscription-id}";
const resourceGroupName = process.env["STORAGE_RESOURCE_GROUP"] || "res346";
const accountName = "sto666";
const shareName = "share1235";
const fileShare = { accessTier: "Hot" };
const credential = new DefaultAzureCredential();
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.fileShares.create(
resourceGroupName,
accountName,
shareName,
fileShare,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using Azure;
using Azure.ResourceManager;
using System;
using System.Threading.Tasks;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager.Storage.Models;
using Azure.ResourceManager.Storage;
// Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json
// this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this FileServiceResource created on azure
// for more information of creating FileServiceResource, please refer to the document of FileServiceResource
string subscriptionId = "{subscription-id}";
string resourceGroupName = "res346";
string accountName = "sto666";
ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName);
FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId);
// get the collection of this FileShareResource
FileShareCollection collection = fileService.GetFileShares();
// invoke the operation
string shareName = "share1235";
FileShareData data = new FileShareData
{
AccessTier = FileShareAccessTier.Hot,
};
ArmOperation<FileShareResource> lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data);
FileShareResource result = lro.Value;
// the variable result is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
FileShareData resourceData = result.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python file_shares_put_access_tier.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="{subscription-id}",
)
response = client.file_shares.create(
resource_group_name="res346",
account_name="sto666",
share_name="share1235",
file_share={"properties": {"accessTier": "Hot"}},
)
print(response)
# x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_AccessTier.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Пример ответа
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"accessTier": "Hot"
}
}
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"accessTier": "Hot"
}
}
PutShares with Paid Bursting
Образец запроса
PUT https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235?api-version=2024-01-01
{
"properties": {
"fileSharePaidBursting": {
"paidBurstingEnabled": true,
"paidBurstingMaxIops": 102400,
"paidBurstingMaxBandwidthMibps": 10340
}
}
}
import com.azure.resourcemanager.storage.fluent.models.FileShareInner;
import com.azure.resourcemanager.storage.models.FileSharePropertiesFileSharePaidBursting;
/**
* Samples for FileShares Create.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.
* json
*/
/**
* Sample code: PutShares with Paid Bursting.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void putSharesWithPaidBursting(com.azure.resourcemanager.AzureResourceManager azure) {
azure.storageAccounts().manager().serviceClient().getFileShares().createWithResponse("res346", "sto666",
"share1235",
new FileShareInner()
.withFileSharePaidBursting(new FileSharePropertiesFileSharePaidBursting().withPaidBurstingEnabled(true)
.withPaidBurstingMaxIops(102400).withPaidBurstingMaxBandwidthMibps(10340)),
null, com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/86c6306649b02e542117adb46c61e8019dbd78e9/specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.json
func ExampleFileSharesClient_Create_putSharesWithPaidBursting() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewFileSharesClient().Create(ctx, "res346", "sto666", "share1235", armstorage.FileShare{
FileShareProperties: &armstorage.FileShareProperties{
FileSharePaidBursting: &armstorage.FileSharePropertiesFileSharePaidBursting{
PaidBurstingEnabled: to.Ptr(true),
PaidBurstingMaxBandwidthMibps: to.Ptr[int32](10340),
PaidBurstingMaxIops: to.Ptr[int32](102400),
},
},
}, &armstorage.FileSharesClientCreateOptions{Expand: nil})
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.FileShare = armstorage.FileShare{
// Name: to.Ptr("share1235"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts/fileServices/shares"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235"),
// FileShareProperties: &armstorage.FileShareProperties{
// FileSharePaidBursting: &armstorage.FileSharePropertiesFileSharePaidBursting{
// PaidBurstingEnabled: to.Ptr(true),
// PaidBurstingMaxBandwidthMibps: to.Ptr[int32](10340),
// PaidBurstingMaxIops: to.Ptr[int32](102400),
// },
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
require("dotenv/config");
/**
* This sample demonstrates how to Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
*
* @summary Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
* x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.json
*/
async function putSharesWithPaidBursting() {
const subscriptionId = process.env["STORAGE_SUBSCRIPTION_ID"] || "{subscription-id}";
const resourceGroupName = process.env["STORAGE_RESOURCE_GROUP"] || "res346";
const accountName = "sto666";
const shareName = "share1235";
const fileShare = {
fileSharePaidBursting: {
paidBurstingEnabled: true,
paidBurstingMaxBandwidthMibps: 10340,
paidBurstingMaxIops: 102400,
},
};
const credential = new DefaultAzureCredential();
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.fileShares.create(
resourceGroupName,
accountName,
shareName,
fileShare,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using Azure;
using Azure.ResourceManager;
using System;
using System.Threading.Tasks;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager.Storage.Models;
using Azure.ResourceManager.Storage;
// Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.json
// this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this FileServiceResource created on azure
// for more information of creating FileServiceResource, please refer to the document of FileServiceResource
string subscriptionId = "{subscription-id}";
string resourceGroupName = "res346";
string accountName = "sto666";
ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName);
FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId);
// get the collection of this FileShareResource
FileShareCollection collection = fileService.GetFileShares();
// invoke the operation
string shareName = "share1235";
FileShareData data = new FileShareData
{
FileSharePaidBursting = new FileSharePropertiesFileSharePaidBursting
{
PaidBurstingEnabled = true,
PaidBurstingMaxIops = 102400,
PaidBurstingMaxBandwidthMibps = 10340,
},
};
ArmOperation<FileShareResource> lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data);
FileShareResource result = lro.Value;
// the variable result is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
FileShareData resourceData = result.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python file_shares_put_paid_bursting.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="{subscription-id}",
)
response = client.file_shares.create(
resource_group_name="res346",
account_name="sto666",
share_name="share1235",
file_share={
"properties": {
"fileSharePaidBursting": {
"paidBurstingEnabled": True,
"paidBurstingMaxBandwidthMibps": 10340,
"paidBurstingMaxIops": 102400,
}
}
},
)
print(response)
# x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_PaidBursting.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Пример ответа
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"fileSharePaidBursting": {
"paidBurstingEnabled": true,
"paidBurstingMaxIops": 102400,
"paidBurstingMaxBandwidthMibps": 10340
}
}
}
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"fileSharePaidBursting": {
"paidBurstingEnabled": true,
"paidBurstingMaxIops": 102400,
"paidBurstingMaxBandwidthMibps": 10340
}
}
}
PutSharesProvisionedV2
Образец запроса
PUT https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235?api-version=2024-01-01
{
"properties": {
"shareQuota": 100,
"provisionedIops": 5000,
"provisionedBandwidthMibps": 200
}
}
import com.azure.resourcemanager.storage.fluent.models.FileShareInner;
/**
* Samples for FileShares Create.
*/
public final class Main {
/*
* x-ms-original-file:
* specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.
* json
*/
/**
* Sample code: PutSharesProvisionedV2.
*
* @param azure The entry point for accessing resource management APIs in Azure.
*/
public static void putSharesProvisionedV2(com.azure.resourcemanager.AzureResourceManager azure) {
azure.storageAccounts().manager().serviceClient().getFileShares().createWithResponse("res346", "sto666",
"share1235",
new FileShareInner().withShareQuota(100).withProvisionedIops(5000).withProvisionedBandwidthMibps(200), null,
com.azure.core.util.Context.NONE);
}
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
package armstorage_test
import (
"context"
"log"
"github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
"github.com/Azure/azure-sdk-for-go/sdk/azidentity"
"github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage"
)
// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/86c6306649b02e542117adb46c61e8019dbd78e9/specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.json
func ExampleFileSharesClient_Create_putSharesProvisionedV2() {
cred, err := azidentity.NewDefaultAzureCredential(nil)
if err != nil {
log.Fatalf("failed to obtain a credential: %v", err)
}
ctx := context.Background()
clientFactory, err := armstorage.NewClientFactory("<subscription-id>", cred, nil)
if err != nil {
log.Fatalf("failed to create client: %v", err)
}
res, err := clientFactory.NewFileSharesClient().Create(ctx, "res346", "sto666", "share1235", armstorage.FileShare{
FileShareProperties: &armstorage.FileShareProperties{
ProvisionedBandwidthMibps: to.Ptr[int32](200),
ProvisionedIops: to.Ptr[int32](5000),
ShareQuota: to.Ptr[int32](100),
},
}, &armstorage.FileSharesClientCreateOptions{Expand: nil})
if err != nil {
log.Fatalf("failed to finish the request: %v", err)
}
// You could use response here. We use blank identifier for just demo purposes.
_ = res
// If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes.
// res.FileShare = armstorage.FileShare{
// Name: to.Ptr("share1235"),
// Type: to.Ptr("Microsoft.Storage/storageAccounts/fileServices/shares"),
// ID: to.Ptr("/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235"),
// FileShareProperties: &armstorage.FileShareProperties{
// IncludedBurstIops: to.Ptr[int32](15000),
// MaxBurstCreditsForIops: to.Ptr[int64](36000000),
// ProvisionedBandwidthMibps: to.Ptr[int32](200),
// ProvisionedIops: to.Ptr[int32](5000),
// ShareQuota: to.Ptr[int32](100),
// },
// }
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
const { StorageManagementClient } = require("@azure/arm-storage");
const { DefaultAzureCredential } = require("@azure/identity");
require("dotenv/config");
/**
* This sample demonstrates how to Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
*
* @summary Creates a new share under the specified account as described by request body. The share resource includes metadata and properties for that share. It does not include a list of the files contained by the share.
* x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.json
*/
async function putSharesProvisionedV2() {
const subscriptionId = process.env["STORAGE_SUBSCRIPTION_ID"] || "{subscription-id}";
const resourceGroupName = process.env["STORAGE_RESOURCE_GROUP"] || "res346";
const accountName = "sto666";
const shareName = "share1235";
const fileShare = {
provisionedBandwidthMibps: 200,
provisionedIops: 5000,
shareQuota: 100,
};
const credential = new DefaultAzureCredential();
const client = new StorageManagementClient(credential, subscriptionId);
const result = await client.fileShares.create(
resourceGroupName,
accountName,
shareName,
fileShare,
);
console.log(result);
}
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
using Azure;
using Azure.ResourceManager;
using System;
using System.Threading.Tasks;
using Azure.Core;
using Azure.Identity;
using Azure.ResourceManager.Storage.Models;
using Azure.ResourceManager.Storage;
// Generated from example definition: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.json
// this example is just showing the usage of "FileShares_Create" operation, for the dependent resources, they will have to be created separately.
// get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line
TokenCredential cred = new DefaultAzureCredential();
// authenticate your client
ArmClient client = new ArmClient(cred);
// this example assumes you already have this FileServiceResource created on azure
// for more information of creating FileServiceResource, please refer to the document of FileServiceResource
string subscriptionId = "{subscription-id}";
string resourceGroupName = "res346";
string accountName = "sto666";
ResourceIdentifier fileServiceResourceId = FileServiceResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, accountName);
FileServiceResource fileService = client.GetFileServiceResource(fileServiceResourceId);
// get the collection of this FileShareResource
FileShareCollection collection = fileService.GetFileShares();
// invoke the operation
string shareName = "share1235";
FileShareData data = new FileShareData
{
ShareQuota = 100,
ProvisionedIops = 5000,
ProvisionedBandwidthMibps = 200,
};
ArmOperation<FileShareResource> lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, shareName, data);
FileShareResource result = lro.Value;
// the variable result is a resource, you could call other operations on this instance as well
// but just for demo, we get its data from this resource instance
FileShareData resourceData = result.Data;
// for demo we just print out the id
Console.WriteLine($"Succeeded on id: {resourceData.Id}");
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
from azure.identity import DefaultAzureCredential
from azure.mgmt.storage import StorageManagementClient
"""
# PREREQUISITES
pip install azure-identity
pip install azure-mgmt-storage
# USAGE
python file_shares_put_provisioned_v2.py
Before run the sample, please set the values of the client ID, tenant ID and client secret
of the AAD application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID,
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""
def main():
client = StorageManagementClient(
credential=DefaultAzureCredential(),
subscription_id="{subscription-id}",
)
response = client.file_shares.create(
resource_group_name="res346",
account_name="sto666",
share_name="share1235",
file_share={"properties": {"provisionedBandwidthMibps": 200, "provisionedIops": 5000, "shareQuota": 100}},
)
print(response)
# x-ms-original-file: specification/storage/resource-manager/Microsoft.Storage/stable/2024-01-01/examples/FileSharesPut_ProvisionedV2.json
if __name__ == "__main__":
main()
To use the Azure SDK library in your project, see this documentation. To provide feedback on this code sample, open a GitHub issue
Пример ответа
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"shareQuota": 100,
"provisionedIops": 5000,
"provisionedBandwidthMibps": 200,
"includedBurstIops": 15000,
"maxBurstCreditsForIops": 36000000
}
}
{
"id": "/subscriptions/{subscription-id}/resourceGroups/res346/providers/Microsoft.Storage/storageAccounts/sto666/fileServices/default/shares/share1235",
"name": "share1235",
"type": "Microsoft.Storage/storageAccounts/fileServices/shares",
"properties": {
"shareQuota": 100,
"provisionedIops": 5000,
"provisionedBandwidthMibps": 200,
"includedBurstIops": 15000,
"maxBurstCreditsForIops": 36000000
}
}
Определения
Имя |
Описание |
AccessPolicy
|
|
CloudError
|
Ответ об ошибке из службы хранилища.
|
CloudErrorBody
|
Ответ об ошибке из службы хранилища.
|
EnabledProtocols
|
Протокол проверки подлинности, используемый для общей папки. Можно указать только при создании общей папки.
|
FileShare
|
Свойства общей папки, включая идентификатор, имя ресурса, тип ресурса, Etag.
|
FileSharePaidBursting
|
Свойства платного ускорения общей папки.
|
LeaseDuration
|
Указывает, является ли аренда общей папки бесконечной или фиксированной длительностью, только если общая доля арендовается.
|
LeaseState
|
Состояние аренды общей папки.
|
LeaseStatus
|
Состояние аренды общей папки.
|
RootSquashType
|
Свойство предназначено только для общего ресурса NFS. Значение по умолчанию — NoRootSquash.
|
ShareAccessTier
|
Уровень доступа для определенной общей папки. Учетная запись GpV2 может выбирать между TransactionOptimized (по умолчанию), горячей и холодной. Учетная запись FileStorage может выбрать Premium.
|
SignedIdentifier
|
|
AccessPolicy
Object
Имя |
Тип |
Описание |
expiryTime
|
string
(date-time)
|
Срок действия политики доступа
|
permission
|
string
|
Список сокращенных разрешений.
|
startTime
|
string
(date-time)
|
Время начала политики доступа
|
CloudError
Object
Ответ об ошибке из службы хранилища.
Имя |
Тип |
Описание |
error
|
CloudErrorBody
|
Ответ об ошибке из службы хранилища.
|
CloudErrorBody
Object
Ответ об ошибке из службы хранилища.
Имя |
Тип |
Описание |
code
|
string
|
Идентификатор ошибки. Коды являются инвариантными и предназначены для программного использования.
|
details
|
CloudErrorBody[]
|
Список дополнительных сведений об ошибке.
|
message
|
string
|
Сообщение, описывающее ошибку, предназначенное для отображения в пользовательском интерфейсе.
|
target
|
string
|
Целевой объект конкретной ошибки. Например, имя свойства в ошибке.
|
EnabledProtocols
Перечисление
Протокол проверки подлинности, используемый для общей папки. Можно указать только при создании общей папки.
Значение |
Описание |
SMB
|
|
NFS
|
|
FileShare
Object
Свойства общей папки, включая идентификатор, имя ресурса, тип ресурса, Etag.
Имя |
Тип |
Описание |
etag
|
string
|
Etag ресурса.
|
id
|
string
|
Полный идентификатор ресурса для ресурса. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
name
|
string
|
Имя ресурса
|
properties.accessTier
|
ShareAccessTier
|
Уровень доступа для определенной общей папки. Учетная запись GpV2 может выбирать между TransactionOptimized (по умолчанию), горячей и холодной. Учетная запись FileStorage может выбрать Premium.
|
properties.accessTierChangeTime
|
string
(date-time)
|
Указывает время последнего изменения уровня доступа к общей папке.
|
properties.accessTierStatus
|
string
|
Указывает, существует ли ожидающий переход для уровня доступа.
|
properties.deleted
|
boolean
|
Указывает, была ли удалена общая папка.
|
properties.deletedTime
|
string
(date-time)
|
Время удаления, если общий ресурс был удален.
|
properties.enabledProtocols
|
EnabledProtocols
|
Протокол проверки подлинности, используемый для общей папки. Можно указать только при создании общей папки.
|
properties.fileSharePaidBursting
|
FileSharePaidBursting
|
Свойства платного ускорения общей папки.
|
properties.includedBurstIops
|
integer
(int32)
|
Вычисляемое число операций ввода-вывода в секунду для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2.
|
properties.lastModifiedTime
|
string
(date-time)
|
Возвращает дату и время последнего изменения общей папки.
|
properties.leaseDuration
|
LeaseDuration
|
Указывает, является ли аренда общей папки бесконечной или фиксированной длительностью, только если общая доля арендовается.
|
properties.leaseState
|
LeaseState
|
Состояние аренды общей папки.
|
properties.leaseStatus
|
LeaseStatus
|
Состояние аренды общей папки.
|
properties.maxBurstCreditsForIops
|
integer
(int64)
|
Вычисляемые максимальные кредиты на всплеск для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2.
|
properties.metadata
|
object
|
Пара "имя-значение", связанная с общей папкой в качестве метаданных.
|
properties.nextAllowedProvisionedBandwidthDowngradeTime
|
string
(date-time-rfc1123)
|
Возвращает следующее разрешенное время понижения пропускной способности для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2.
|
properties.nextAllowedProvisionedIopsDowngradeTime
|
string
(date-time-rfc1123)
|
Возвращает следующее разрешенное время понижения уровня операций ввода-вывода в секунду для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2.
|
properties.nextAllowedQuotaDowngradeTime
|
string
(date-time-rfc1123)
|
Возвращает следующее разрешенное время понижения размера подготовленного хранилища для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Файлы, подготовленные версии 1 SSD" и "Подготовленные файлы" версии 2.
|
properties.provisionedBandwidthMibps
|
integer
(int32)
|
Подготовленная пропускная способность общей папки в мбибайтах в секунду. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2. Обратитесь к ответу API GetFileServiceUsage для минимального и максимального допустимого значения подготовленной пропускной способности.
|
properties.provisionedIops
|
integer
(int32)
|
Подготовленные операции ввода-вывода в секунду общего ресурса. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы" версии 2. Обратитесь к ответу API GetFileServiceUsage минимальное и максимально допустимое значение для подготовленных операций ввода-вывода в секунду.
|
properties.remainingRetentionDays
|
integer
|
Оставшиеся дни хранения для общего ресурса, который был обратимо удален.
|
properties.rootSquash
|
RootSquashType
|
Свойство предназначено только для общего ресурса NFS. Значение по умолчанию — NoRootSquash.
|
properties.shareQuota
|
integer
(int32)
|
Подготовленный размер общей папки в гибибайтах. Должно быть больше 0 и меньше или равно 5TB (5120). Для больших общих папок максимальный размер — 102400. Для общих папок, созданных в разделе "Подготовленные файлы" типа учетной записи версии 2, обратитесь к ответу API GetFileServiceUsage для минимального и максимального допустимого размера подготовленного хранилища.
|
properties.shareUsageBytes
|
integer
(int64)
|
Приблизительный размер данных, хранящихся в общей папке. Обратите внимание, что это значение может не включать все недавно созданные или недавно измененные файлы.
|
properties.signedIdentifiers
|
SignedIdentifier[]
|
Список хранимых политик доступа, указанных в общей папке.
|
properties.snapshotTime
|
string
(date-time)
|
Время создания моментального снимка общего ресурса, возвращенное в ответе на общие папки списка с расширением param "snapshots".
|
properties.version
|
string
|
Версия общей папки.
|
type
|
string
|
Тип ресурса. Например, "Microsoft.Compute/virtualMachines" или "Microsoft.Storage/storageAccounts"
|
FileSharePaidBursting
Object
Свойства платного ускорения общей папки.
Имя |
Тип |
Описание |
paidBurstingEnabled
|
boolean
|
Указывает, включена ли платная вспышка для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы", тип учетной записи SSD версии 1.
|
paidBurstingMaxBandwidthMibps
|
integer
(int32)
|
Максимальная платная пропускная способность для общей папки в мебибайтах в секунду. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы", тип учетной записи SSD версии 1. Максимально допустимое значение — 10340, которое является максимально допустимой пропускной способностью для общей папки.
|
paidBurstingMaxIops
|
integer
(int32)
|
Максимальное количество платных операций ввода-вывода в секунду для общей папки. Это свойство предназначено только для общих папок, созданных в разделе "Подготовленные файлы", тип учетной записи SSD версии 1. Максимально допустимое значение — 102400, которое является максимальным допустимым числом операций ввода-вывода в секунду для общей папки.
|
LeaseDuration
Перечисление
Указывает, является ли аренда общей папки бесконечной или фиксированной длительностью, только если общая доля арендовается.
Значение |
Описание |
Infinite
|
|
Fixed
|
|
LeaseState
Перечисление
Состояние аренды общей папки.
Значение |
Описание |
Available
|
|
Leased
|
|
Expired
|
|
Breaking
|
|
Broken
|
|
LeaseStatus
Перечисление
Состояние аренды общей папки.
Значение |
Описание |
Locked
|
|
Unlocked
|
|
RootSquashType
Перечисление
Свойство предназначено только для общего ресурса NFS. Значение по умолчанию — NoRootSquash.
Значение |
Описание |
NoRootSquash
|
|
RootSquash
|
|
AllSquash
|
|
ShareAccessTier
Перечисление
Уровень доступа для определенной общей папки. Учетная запись GpV2 может выбирать между TransactionOptimized (по умолчанию), горячей и холодной. Учетная запись FileStorage может выбрать Premium.
Значение |
Описание |
TransactionOptimized
|
|
Hot
|
|
Cool
|
|
Premium
|
|
SignedIdentifier
Object
Имя |
Тип |
Описание |
accessPolicy
|
AccessPolicy
|
Политика доступа
|
id
|
string
|
Уникальный идентификатор хранимой политики доступа.
|