Module: Azure::Storage::Default

Defined in:
lib/azure/storage/core/constants.rb

Constant Summary collapse

STG_VERSION =

Default REST service (STG) version number

'2015-02-21'
DEFAULT_PARALLEL_OPERATION_THREAD_COUNT =

The number of default concurrent requests for parallel operation.

1
KB =

Constant representing a kilobyte (Non-SI version).

1024
MB =

Constant representing a megabyte (Non-SI version).

1024 * 1024
GB =

Constant representing a gigabyte (Non-SI version).

1024 * 1024 * 1024
HTTP =

Specifies HTTP.

'http'
HTTPS =

Specifies HTTPS.

'https'
DEFAULT_HTTP_PORT =

Default HTTP port.

80
DEFAULT_HTTPS_PORT =

Default HTTPS port.

443
XML_METADATA_MARKER =

Marker for atom metadata.

'$'
XML_VALUE_MARKER =

Marker for atom value.

'_'
USER_AGENT =

Default User Agent header string

"Azure-Storage/#{Azure::Storage::Version.to_uas} (Ruby #{RUBY_VERSION}-p#{RUBY_PATCHLEVEL}; #{os})".freeze

Class Method Summary collapse

Class Method Details

.optionsObject


70
71
72
# File 'lib/azure/storage/core/constants.rb', line 70

def options
  Hash[Azure::Storage::Configurable.keys.map{|key| [key, send(key)]}]
end

.osObject


48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# File 'lib/azure/storage/core/constants.rb', line 48

def os
  host_os = RbConfig::CONFIG['host_os']
  case host_os
  when /mswin|msys|mingw|cygwin|bccwin|wince|emc/
    "Windows #{host_os}"
  when /darwin|mac os/
    "MacOS #{host_os}"
  when /linux/
    "Linux #{host_os}"
  when /solaris|bsd/
    "Unix #{host_os}"
  else
    "Unknown #{host_os}"
  end
end

.storage_access_keyString

Default storage access key


76
77
78
# File 'lib/azure/storage/core/constants.rb', line 76

def storage_access_key
  ENV['AZURE_STORAGE_ACCESS_KEY']
end

.storage_account_nameString

Default storage account name


82
83
84
# File 'lib/azure/storage/core/constants.rb', line 82

def 
  ENV['AZURE_STORAGE_ACCOUNT']
end

.storage_blob_hostString

Default storage blob host


100
101
102
# File 'lib/azure/storage/core/constants.rb', line 100

def storage_blob_host
  ENV['AZURE_STORAGE_BLOB_HOST']
end

.storage_connection_stringString

Default storage connection string


88
89
90
# File 'lib/azure/storage/core/constants.rb', line 88

def storage_connection_string
  ENV['AZURE_STORAGE_CONNECTION_STRING']
end

.storage_file_hostString

Default storage file host


112
113
114
# File 'lib/azure/storage/core/constants.rb', line 112

def storage_file_host
  ENV['AZURE_STORAGE_FILE_HOST']
end

.storage_queue_hostString

Default storage queue host


106
107
108
# File 'lib/azure/storage/core/constants.rb', line 106

def storage_queue_host
  ENV['AZURE_STORAGE_QUEUE_HOST']
end

.storage_table_hostString

Default storage table host


94
95
96
# File 'lib/azure/storage/core/constants.rb', line 94

def storage_table_host
  ENV['AZURE_STORAGE_TABLE_HOST']
end