Get started with Azure Stack Storage development tools

Applies to: Azure Stack integrated systems and Azure Stack Development Kit

Microsoft Azure Stack provides a set of storage services, including Azure Blob, Table, and Queue storage.

This article provides quick guidance on how to start using Azure Stack Storage development tools. You can find more detailed information and sample code in the corresponding Azure Storage tutorials.

There are known differences between Azure Storage and Azure Stack Storage, including some specific requirements for each platform. For example, there are specific client libraries and specific endpoint suffix requirements for Azure Stack. For more information, see Azure Stack Storage: Differences and considerations.

Azure client libraries

The supported REST API version for Azure Stack Storage is 2015-04-05. It doesn’t have full parity with the latest version of the Azure Storage REST API. So for the storage client libraries, you need to be aware of the version that is compatible with REST API 2015-04-05.

Client library Azure Stack supported version Link Endpoint specification
.NET 6.2.0 Nuget package:
https://www.nuget.org/packages/WindowsAzure.Storage/6.2.0

GitHub release:
https://github.com/Azure/azure-storage-net/releases/tag/v6.2.1
app.config file
Java 4.1.0 Maven package:
http://mvnrepository.com/artifact/com.microsoft.azure/azure-storage/4.1.0

GitHub release:
https://github.com/Azure/azure-storage-java/releases/tag/v4.1.0
Connection string setup
Node.js 1.1.0 NPM link:
https://www.npmjs.com/package/azure-storage
(run: npm install azure-storage@1.1.0)

Github release:
https://github.com/Azure/azure-storage-node/releases/tag/1.1.0
Service instance declaration
C++ 2.4.0 Nuget package:
https://www.nuget.org/packages/wastorage.v140/2.4.0

GitHub release:
https://github.com/Azure/azure-storage-cpp/releases/tag/v2.4.0
Connection string setup
PHP 0.15.0 GitHub release:
https://github.com/Azure/azure-storage-php/releases/tag/v0.15.0

Install via Composer (see details below)
Connection string setup
Python 0.30.0 PIP package:
https://pypi.python.org/pypi/azure-storage/0.30.0
(Run: pip install -v azure-storage==0.30.0)

GitHub release:
https://github.com/Azure/azure-storage-python/releases/tag/v0.30.0
Service instance declaration
Ruby 0.12.1
Preview
RubyGems package:
https://rubygems.org/gems/azure-storage/versions/0.12.1.preview

GitHub release:
https://github.com/Azure/azure-storage-ruby/releases/tag/v0.12.1
Connection string setup
Note

PHP details

To install via Composer:

  1. Create a file named composer.json in the root of the project with following code:

    {
       "require":{
           "Microsoft/azure-storage":"0.15.0"
        }
    }
    
  2. Download composer.phar into the project root.

  3. Run: php composer.phar install.

Endpoint declaration

An Azure Stack endpoint includes two parts: the name of a region and the Azure Stack domain. In the Azure Stack Development Kit, the default endpoint is local.azurestack.external. Contact your cloud administrator if you’re not sure about your endpoint.

Examples

.NET

For Azure Stack, the endpoint suffix is specified in the app.config file:

<add key="StorageConnectionString" 
value="DefaultEndpointsProtocol=https;AccountName=myaccount;AccountKey=mykey;
EndpointSuffix=local.azurestack.external;" />

Java

For Azure Stack, the endpoint suffix is specified in the setup of connection string:

public static final String storageConnectionString =
    "DefaultEndpointsProtocol=http;" +
    "AccountName=your_storage_account;" +
    "AccountKey=your_storage_account_key;" +
    "EndpointSuffix=local.azurestack.external";

Node.js

For Azure Stack, the endpoint suffix is specified in the declaration instance:

var blobSvc = azure.createBlobService('myaccount', 'mykey',
'myaccount.blob.local.azurestack.external');

C++

For Azure Stack, the endpoint suffix is specified in the setup of connection string:

const utility::string_t storage_connection_string(U("DefaultEndpointsProtocol=https;
AccountName=your_storage_account;
AccountKey=your_storage_account_key;
EndpointSuffix=local.azurestack.external"));

PHP

For Azure Stack, the endpoint suffix is specified in the setup of connection string:

$connectionString = 'BlobEndpoint=http://<storage account name>.blob.local.azurestack.external/;
QueueEndpoint=http:// <storage account name>.queue.local.azurestack.external/;
TableEndpoint=http:// <storage account name>.table.local.azurestack.external/;
AccountName=<storage account name>;AccountKey=<storage account key>'

Python

For Azure Stack, the endpoint suffix is specified in the declaration instance:

block_blob_service = BlockBlobService(account_name='myaccount',
account_key='mykey',
endpoint_suffix='local.azurestack.external')

Ruby

For Azure Stack, the endpoint suffix is specified in the setup of connection string:

set
AZURE_STORAGE_CONNECTION_STRING=DefaultEndpointsProtocol=https;
AccountName=myaccount;
AccountKey=mykey;
EndpointSuffix=local.azurestack.external

Blob storage

The following Azure Blob storage tutorials are applicable to Azure Stack. Note the specific endpoint suffix requirement for Azure Stack described in the previous Examples section.

Queue storage

The following Azure Queue storage tutorials are applicable to Azure Stack. Note the specific endpoint suffix requirement for Azure Stack described in the previous Examples section.

Table storage

The following Azure Table storage tutorials are applicable to Azure Stack. Note the specific endpoint suffix requirement for Azure Stack described in the previous Examples section.

Next steps