@azure/storage-blob 12.9.0-beta.2 → 12.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +36 -5
- package/README.md +11 -10
- package/dist/index.js +1109 -469
- package/dist/index.js.map +1 -1
- package/dist-esm/storage-blob/src/BatchResponseParser.js +2 -2
- package/dist-esm/storage-blob/src/BatchResponseParser.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobBatch.js +8 -8
- package/dist-esm/storage-blob/src/BlobBatch.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobBatchClient.js +2 -2
- package/dist-esm/storage-blob/src/BlobBatchClient.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobDownloadResponse.js +1 -1
- package/dist-esm/storage-blob/src/BlobDownloadResponse.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobLeaseClient.js +5 -5
- package/dist-esm/storage-blob/src/BlobLeaseClient.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobQueryResponse.browser.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobQueryResponse.js.map +1 -1
- package/dist-esm/storage-blob/src/BlobServiceClient.js +22 -20
- package/dist-esm/storage-blob/src/BlobServiceClient.js.map +1 -1
- package/dist-esm/storage-blob/src/Clients.js +105 -100
- package/dist-esm/storage-blob/src/Clients.js.map +1 -1
- package/dist-esm/storage-blob/src/ContainerClient.js +241 -38
- package/dist-esm/storage-blob/src/ContainerClient.js.map +1 -1
- package/dist-esm/storage-blob/src/PageBlobRangeResponse.js +3 -3
- package/dist-esm/storage-blob/src/PageBlobRangeResponse.js.map +1 -1
- package/dist-esm/storage-blob/src/Pipeline.js +9 -7
- package/dist-esm/storage-blob/src/Pipeline.js.map +1 -1
- package/dist-esm/storage-blob/src/TelemetryPolicyFactory.js +1 -1
- package/dist-esm/storage-blob/src/TelemetryPolicyFactory.js.map +1 -1
- package/dist-esm/storage-blob/src/credentials/StorageSharedKeyCredential.js +1 -3
- package/dist-esm/storage-blob/src/credentials/StorageSharedKeyCredential.js.map +1 -1
- package/dist-esm/storage-blob/src/credentials/UserDelegationKeyCredential.js +1 -3
- package/dist-esm/storage-blob/src/credentials/UserDelegationKeyCredential.js.map +1 -1
- package/dist-esm/storage-blob/src/generated/src/models/index.js.map +1 -1
- package/dist-esm/storage-blob/src/generated/src/models/mappers.js +53 -0
- package/dist-esm/storage-blob/src/generated/src/models/mappers.js.map +1 -1
- package/dist-esm/storage-blob/src/generated/src/models/parameters.js +3 -4
- package/dist-esm/storage-blob/src/generated/src/models/parameters.js.map +1 -1
- package/dist-esm/storage-blob/src/generated/src/operations/container.js +41 -0
- package/dist-esm/storage-blob/src/generated/src/operations/container.js.map +1 -1
- package/dist-esm/storage-blob/src/generated/src/storageClientContext.js +2 -2
- package/dist-esm/storage-blob/src/generated/src/storageClientContext.js.map +1 -1
- package/dist-esm/storage-blob/src/generatedModels.js.map +1 -1
- package/dist-esm/storage-blob/src/index.browser.js +1 -1
- package/dist-esm/storage-blob/src/index.browser.js.map +1 -1
- package/dist-esm/storage-blob/src/index.js +1 -1
- package/dist-esm/storage-blob/src/index.js.map +1 -1
- package/dist-esm/storage-blob/src/models.js +14 -0
- package/dist-esm/storage-blob/src/models.js.map +1 -1
- package/dist-esm/storage-blob/src/policies/StorageBearerTokenChallengeAuthenticationPolicy.js +245 -0
- package/dist-esm/storage-blob/src/policies/StorageBearerTokenChallengeAuthenticationPolicy.js.map +1 -0
- package/dist-esm/storage-blob/src/policies/StorageBrowserPolicy.js +1 -1
- package/dist-esm/storage-blob/src/policies/StorageBrowserPolicy.js.map +1 -1
- package/dist-esm/storage-blob/src/policies/StorageRetryPolicy.js +5 -5
- package/dist-esm/storage-blob/src/policies/StorageRetryPolicy.js.map +1 -1
- package/dist-esm/storage-blob/src/policies/StorageSharedKeyCredentialPolicy.js +4 -2
- package/dist-esm/storage-blob/src/policies/StorageSharedKeyCredentialPolicy.js.map +1 -1
- package/dist-esm/storage-blob/src/policies/TelemetryPolicy.js +1 -1
- package/dist-esm/storage-blob/src/policies/TelemetryPolicy.js.map +1 -1
- package/dist-esm/storage-blob/src/pollers/BlobStartCopyFromUrlPoller.js +3 -3
- package/dist-esm/storage-blob/src/pollers/BlobStartCopyFromUrlPoller.js.map +1 -1
- package/dist-esm/storage-blob/src/sas/AccountSASSignatureValues.js +2 -2
- package/dist-esm/storage-blob/src/sas/AccountSASSignatureValues.js.map +1 -1
- package/dist-esm/storage-blob/src/sas/BlobSASSignatureValues.js +11 -6
- package/dist-esm/storage-blob/src/sas/BlobSASSignatureValues.js.map +1 -1
- package/dist-esm/storage-blob/src/sas/ContainerSASPermissions.js +13 -0
- package/dist-esm/storage-blob/src/sas/ContainerSASPermissions.js.map +1 -1
- package/dist-esm/storage-blob/src/sas/SASQueryParameters.js +2 -2
- package/dist-esm/storage-blob/src/sas/SASQueryParameters.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/Batch.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/BlobQuickQueryStream.js +1 -1
- package/dist-esm/storage-blob/src/utils/BlobQuickQueryStream.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/Mutex.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/RetriableReadableStream.js +1 -2
- package/dist-esm/storage-blob/src/utils/RetriableReadableStream.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/constants.js +9 -8
- package/dist-esm/storage-blob/src/utils/constants.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/tracing.js +2 -2
- package/dist-esm/storage-blob/src/utils/tracing.js.map +1 -1
- package/dist-esm/storage-blob/src/utils/utils.common.js +25 -25
- package/dist-esm/storage-blob/src/utils/utils.common.js.map +1 -1
- package/dist-esm/storage-internal-avro/src/AvroParser.js.map +1 -1
- package/dist-esm/storage-internal-avro/src/AvroReader.js +8 -8
- package/dist-esm/storage-internal-avro/src/AvroReader.js.map +1 -1
- package/package.json +40 -49
- package/{typings → types}/3.1/storage-blob.d.ts +222 -5
- package/{typings → types}/latest/storage-blob.d.ts +202 -5
package/dist/index.js
CHANGED
@@ -16,6 +16,29 @@ var events = require('events');
|
|
16
16
|
var fs = require('fs');
|
17
17
|
var util = require('util');
|
18
18
|
|
19
|
+
function _interopNamespace(e) {
|
20
|
+
if (e && e.__esModule) return e;
|
21
|
+
var n = Object.create(null);
|
22
|
+
if (e) {
|
23
|
+
Object.keys(e).forEach(function (k) {
|
24
|
+
if (k !== 'default') {
|
25
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
26
|
+
Object.defineProperty(n, k, d.get ? d : {
|
27
|
+
enumerable: true,
|
28
|
+
get: function () { return e[k]; }
|
29
|
+
});
|
30
|
+
}
|
31
|
+
});
|
32
|
+
}
|
33
|
+
n["default"] = e;
|
34
|
+
return Object.freeze(n);
|
35
|
+
}
|
36
|
+
|
37
|
+
var coreHttp__namespace = /*#__PURE__*/_interopNamespace(coreHttp);
|
38
|
+
var os__namespace = /*#__PURE__*/_interopNamespace(os);
|
39
|
+
var fs__namespace = /*#__PURE__*/_interopNamespace(fs);
|
40
|
+
var util__namespace = /*#__PURE__*/_interopNamespace(util);
|
41
|
+
|
19
42
|
/*
|
20
43
|
* Copyright (c) Microsoft Corporation.
|
21
44
|
* Licensed under the MIT License.
|
@@ -3141,6 +3164,59 @@ const ContainerSubmitBatchExceptionHeaders = {
|
|
3141
3164
|
}
|
3142
3165
|
}
|
3143
3166
|
};
|
3167
|
+
const ContainerFilterBlobsHeaders = {
|
3168
|
+
serializedName: "Container_filterBlobsHeaders",
|
3169
|
+
type: {
|
3170
|
+
name: "Composite",
|
3171
|
+
className: "ContainerFilterBlobsHeaders",
|
3172
|
+
modelProperties: {
|
3173
|
+
clientRequestId: {
|
3174
|
+
serializedName: "x-ms-client-request-id",
|
3175
|
+
xmlName: "x-ms-client-request-id",
|
3176
|
+
type: {
|
3177
|
+
name: "String"
|
3178
|
+
}
|
3179
|
+
},
|
3180
|
+
requestId: {
|
3181
|
+
serializedName: "x-ms-request-id",
|
3182
|
+
xmlName: "x-ms-request-id",
|
3183
|
+
type: {
|
3184
|
+
name: "String"
|
3185
|
+
}
|
3186
|
+
},
|
3187
|
+
version: {
|
3188
|
+
serializedName: "x-ms-version",
|
3189
|
+
xmlName: "x-ms-version",
|
3190
|
+
type: {
|
3191
|
+
name: "String"
|
3192
|
+
}
|
3193
|
+
},
|
3194
|
+
date: {
|
3195
|
+
serializedName: "date",
|
3196
|
+
xmlName: "date",
|
3197
|
+
type: {
|
3198
|
+
name: "DateTimeRfc1123"
|
3199
|
+
}
|
3200
|
+
}
|
3201
|
+
}
|
3202
|
+
}
|
3203
|
+
};
|
3204
|
+
const ContainerFilterBlobsExceptionHeaders = {
|
3205
|
+
serializedName: "Container_filterBlobsExceptionHeaders",
|
3206
|
+
type: {
|
3207
|
+
name: "Composite",
|
3208
|
+
className: "ContainerFilterBlobsExceptionHeaders",
|
3209
|
+
modelProperties: {
|
3210
|
+
errorCode: {
|
3211
|
+
serializedName: "x-ms-error-code",
|
3212
|
+
xmlName: "x-ms-error-code",
|
3213
|
+
type: {
|
3214
|
+
name: "String"
|
3215
|
+
}
|
3216
|
+
}
|
3217
|
+
}
|
3218
|
+
}
|
3219
|
+
};
|
3144
3220
|
const ContainerAcquireLeaseHeaders = {
|
3145
3221
|
serializedName: "Container_acquireLeaseHeaders",
|
3146
3222
|
type: {
|
@@ -8225,6 +8301,8 @@ var Mappers = /*#__PURE__*/Object.freeze({
|
|
8225
8301
|
ContainerRenameExceptionHeaders: ContainerRenameExceptionHeaders,
|
8226
8302
|
ContainerSubmitBatchHeaders: ContainerSubmitBatchHeaders,
|
8227
8303
|
ContainerSubmitBatchExceptionHeaders: ContainerSubmitBatchExceptionHeaders,
|
8304
|
+
ContainerFilterBlobsHeaders: ContainerFilterBlobsHeaders,
|
8305
|
+
ContainerFilterBlobsExceptionHeaders: ContainerFilterBlobsExceptionHeaders,
|
8228
8306
|
ContainerAcquireLeaseHeaders: ContainerAcquireLeaseHeaders,
|
8229
8307
|
ContainerAcquireLeaseExceptionHeaders: ContainerAcquireLeaseExceptionHeaders,
|
8230
8308
|
ContainerReleaseLeaseHeaders: ContainerReleaseLeaseHeaders,
|
@@ -8412,7 +8490,7 @@ const timeoutInSeconds = {
|
|
8412
8490
|
const version = {
|
8413
8491
|
parameterPath: "version",
|
8414
8492
|
mapper: {
|
8415
|
-
defaultValue: "2021-
|
8493
|
+
defaultValue: "2021-04-10",
|
8416
8494
|
isConstant: true,
|
8417
8495
|
serializedName: "x-ms-version",
|
8418
8496
|
type: {
|
@@ -9029,11 +9107,10 @@ const encryptionKeySha256 = {
|
|
9029
9107
|
}
|
9030
9108
|
};
|
9031
9109
|
const encryptionAlgorithm = {
|
9032
|
-
parameterPath: ["options", "encryptionAlgorithm"],
|
9110
|
+
parameterPath: ["options", "cpkInfo", "encryptionAlgorithm"],
|
9033
9111
|
mapper: {
|
9034
|
-
defaultValue: "AES256",
|
9035
|
-
isConstant: true,
|
9036
9112
|
serializedName: "x-ms-encryption-algorithm",
|
9113
|
+
xmlName: "x-ms-encryption-algorithm",
|
9037
9114
|
type: {
|
9038
9115
|
name: "String"
|
9039
9116
|
}
|
@@ -9950,7 +10027,7 @@ class Service {
|
|
9950
10027
|
setProperties(blobServiceProperties, options) {
|
9951
10028
|
const operationArguments = {
|
9952
10029
|
blobServiceProperties,
|
9953
|
-
options:
|
10030
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
9954
10031
|
};
|
9955
10032
|
return this.client.sendOperationRequest(operationArguments, setPropertiesOperationSpec);
|
9956
10033
|
}
|
@@ -9961,9 +10038,9 @@ class Service {
|
|
9961
10038
|
*/
|
9962
10039
|
getProperties(options) {
|
9963
10040
|
const operationArguments = {
|
9964
|
-
options:
|
10041
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
9965
10042
|
};
|
9966
|
-
return this.client.sendOperationRequest(operationArguments, getPropertiesOperationSpec);
|
10043
|
+
return this.client.sendOperationRequest(operationArguments, getPropertiesOperationSpec$2);
|
9967
10044
|
}
|
9968
10045
|
/**
|
9969
10046
|
* Retrieves statistics related to replication for the Blob service. It is only available on the
|
@@ -9973,7 +10050,7 @@ class Service {
|
|
9973
10050
|
*/
|
9974
10051
|
getStatistics(options) {
|
9975
10052
|
const operationArguments = {
|
9976
|
-
options:
|
10053
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
9977
10054
|
};
|
9978
10055
|
return this.client.sendOperationRequest(operationArguments, getStatisticsOperationSpec);
|
9979
10056
|
}
|
@@ -9983,7 +10060,7 @@ class Service {
|
|
9983
10060
|
*/
|
9984
10061
|
listContainersSegment(options) {
|
9985
10062
|
const operationArguments = {
|
9986
|
-
options:
|
10063
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
9987
10064
|
};
|
9988
10065
|
return this.client.sendOperationRequest(operationArguments, listContainersSegmentOperationSpec);
|
9989
10066
|
}
|
@@ -9996,7 +10073,7 @@ class Service {
|
|
9996
10073
|
getUserDelegationKey(keyInfo, options) {
|
9997
10074
|
const operationArguments = {
|
9998
10075
|
keyInfo,
|
9999
|
-
options:
|
10076
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10000
10077
|
};
|
10001
10078
|
return this.client.sendOperationRequest(operationArguments, getUserDelegationKeyOperationSpec);
|
10002
10079
|
}
|
@@ -10006,9 +10083,9 @@ class Service {
|
|
10006
10083
|
*/
|
10007
10084
|
getAccountInfo(options) {
|
10008
10085
|
const operationArguments = {
|
10009
|
-
options:
|
10086
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10010
10087
|
};
|
10011
|
-
return this.client.sendOperationRequest(operationArguments, getAccountInfoOperationSpec);
|
10088
|
+
return this.client.sendOperationRequest(operationArguments, getAccountInfoOperationSpec$2);
|
10012
10089
|
}
|
10013
10090
|
/**
|
10014
10091
|
* The Batch operation allows multiple API calls to be embedded into a single HTTP request.
|
@@ -10023,9 +10100,9 @@ class Service {
|
|
10023
10100
|
contentLength,
|
10024
10101
|
multipartContentType,
|
10025
10102
|
body,
|
10026
|
-
options:
|
10103
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10027
10104
|
};
|
10028
|
-
return this.client.sendOperationRequest(operationArguments, submitBatchOperationSpec);
|
10105
|
+
return this.client.sendOperationRequest(operationArguments, submitBatchOperationSpec$1);
|
10029
10106
|
}
|
10030
10107
|
/**
|
10031
10108
|
* The Filter Blobs operation enables callers to list blobs across all containers whose tags match a
|
@@ -10035,13 +10112,13 @@ class Service {
|
|
10035
10112
|
*/
|
10036
10113
|
filterBlobs(options) {
|
10037
10114
|
const operationArguments = {
|
10038
|
-
options:
|
10115
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10039
10116
|
};
|
10040
|
-
return this.client.sendOperationRequest(operationArguments, filterBlobsOperationSpec);
|
10117
|
+
return this.client.sendOperationRequest(operationArguments, filterBlobsOperationSpec$1);
|
10041
10118
|
}
|
10042
10119
|
}
|
10043
10120
|
// Operation Specifications
|
10044
|
-
const xmlSerializer = new
|
10121
|
+
const xmlSerializer$5 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
10045
10122
|
const setPropertiesOperationSpec = {
|
10046
10123
|
path: "/",
|
10047
10124
|
httpMethod: "PUT",
|
@@ -10070,9 +10147,9 @@ const setPropertiesOperationSpec = {
|
|
10070
10147
|
isXML: true,
|
10071
10148
|
contentType: "application/xml; charset=utf-8",
|
10072
10149
|
mediaType: "xml",
|
10073
|
-
serializer: xmlSerializer
|
10150
|
+
serializer: xmlSerializer$5
|
10074
10151
|
};
|
10075
|
-
const getPropertiesOperationSpec = {
|
10152
|
+
const getPropertiesOperationSpec$2 = {
|
10076
10153
|
path: "/",
|
10077
10154
|
httpMethod: "GET",
|
10078
10155
|
responses: {
|
@@ -10097,7 +10174,7 @@ const getPropertiesOperationSpec = {
|
|
10097
10174
|
accept1
|
10098
10175
|
],
|
10099
10176
|
isXML: true,
|
10100
|
-
serializer: xmlSerializer
|
10177
|
+
serializer: xmlSerializer$5
|
10101
10178
|
};
|
10102
10179
|
const getStatisticsOperationSpec = {
|
10103
10180
|
path: "/",
|
@@ -10124,7 +10201,7 @@ const getStatisticsOperationSpec = {
|
|
10124
10201
|
accept1
|
10125
10202
|
],
|
10126
10203
|
isXML: true,
|
10127
|
-
serializer: xmlSerializer
|
10204
|
+
serializer: xmlSerializer$5
|
10128
10205
|
};
|
10129
10206
|
const listContainersSegmentOperationSpec = {
|
10130
10207
|
path: "/",
|
@@ -10154,7 +10231,7 @@ const listContainersSegmentOperationSpec = {
|
|
10154
10231
|
accept1
|
10155
10232
|
],
|
10156
10233
|
isXML: true,
|
10157
|
-
serializer: xmlSerializer
|
10234
|
+
serializer: xmlSerializer$5
|
10158
10235
|
};
|
10159
10236
|
const getUserDelegationKeyOperationSpec = {
|
10160
10237
|
path: "/",
|
@@ -10185,9 +10262,9 @@ const getUserDelegationKeyOperationSpec = {
|
|
10185
10262
|
isXML: true,
|
10186
10263
|
contentType: "application/xml; charset=utf-8",
|
10187
10264
|
mediaType: "xml",
|
10188
|
-
serializer: xmlSerializer
|
10265
|
+
serializer: xmlSerializer$5
|
10189
10266
|
};
|
10190
|
-
const getAccountInfoOperationSpec = {
|
10267
|
+
const getAccountInfoOperationSpec$2 = {
|
10191
10268
|
path: "/",
|
10192
10269
|
httpMethod: "GET",
|
10193
10270
|
responses: {
|
@@ -10203,9 +10280,9 @@ const getAccountInfoOperationSpec = {
|
|
10203
10280
|
urlParameters: [url],
|
10204
10281
|
headerParameters: [version, accept1],
|
10205
10282
|
isXML: true,
|
10206
|
-
serializer: xmlSerializer
|
10283
|
+
serializer: xmlSerializer$5
|
10207
10284
|
};
|
10208
|
-
const submitBatchOperationSpec = {
|
10285
|
+
const submitBatchOperationSpec$1 = {
|
10209
10286
|
path: "/",
|
10210
10287
|
httpMethod: "POST",
|
10211
10288
|
responses: {
|
@@ -10235,9 +10312,9 @@ const submitBatchOperationSpec = {
|
|
10235
10312
|
isXML: true,
|
10236
10313
|
contentType: "application/xml; charset=utf-8",
|
10237
10314
|
mediaType: "xml",
|
10238
|
-
serializer: xmlSerializer
|
10315
|
+
serializer: xmlSerializer$5
|
10239
10316
|
};
|
10240
|
-
const filterBlobsOperationSpec = {
|
10317
|
+
const filterBlobsOperationSpec$1 = {
|
10241
10318
|
path: "/",
|
10242
10319
|
httpMethod: "GET",
|
10243
10320
|
responses: {
|
@@ -10264,7 +10341,7 @@ const filterBlobsOperationSpec = {
|
|
10264
10341
|
accept1
|
10265
10342
|
],
|
10266
10343
|
isXML: true,
|
10267
|
-
serializer: xmlSerializer
|
10344
|
+
serializer: xmlSerializer$5
|
10268
10345
|
};
|
10269
10346
|
|
10270
10347
|
/*
|
@@ -10290,9 +10367,9 @@ class Container {
|
|
10290
10367
|
*/
|
10291
10368
|
create(options) {
|
10292
10369
|
const operationArguments = {
|
10293
|
-
options:
|
10370
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10294
10371
|
};
|
10295
|
-
return this.client.sendOperationRequest(operationArguments, createOperationSpec);
|
10372
|
+
return this.client.sendOperationRequest(operationArguments, createOperationSpec$2);
|
10296
10373
|
}
|
10297
10374
|
/**
|
10298
10375
|
* returns all user-defined metadata and system properties for the specified container. The data
|
@@ -10301,7 +10378,7 @@ class Container {
|
|
10301
10378
|
*/
|
10302
10379
|
getProperties(options) {
|
10303
10380
|
const operationArguments = {
|
10304
|
-
options:
|
10381
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10305
10382
|
};
|
10306
10383
|
return this.client.sendOperationRequest(operationArguments, getPropertiesOperationSpec$1);
|
10307
10384
|
}
|
@@ -10312,9 +10389,9 @@ class Container {
|
|
10312
10389
|
*/
|
10313
10390
|
delete(options) {
|
10314
10391
|
const operationArguments = {
|
10315
|
-
options:
|
10392
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10316
10393
|
};
|
10317
|
-
return this.client.sendOperationRequest(operationArguments, deleteOperationSpec);
|
10394
|
+
return this.client.sendOperationRequest(operationArguments, deleteOperationSpec$1);
|
10318
10395
|
}
|
10319
10396
|
/**
|
10320
10397
|
* operation sets one or more user-defined name-value pairs for the specified container.
|
@@ -10322,9 +10399,9 @@ class Container {
|
|
10322
10399
|
*/
|
10323
10400
|
setMetadata(options) {
|
10324
10401
|
const operationArguments = {
|
10325
|
-
options:
|
10402
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10326
10403
|
};
|
10327
|
-
return this.client.sendOperationRequest(operationArguments, setMetadataOperationSpec);
|
10404
|
+
return this.client.sendOperationRequest(operationArguments, setMetadataOperationSpec$1);
|
10328
10405
|
}
|
10329
10406
|
/**
|
10330
10407
|
* gets the permissions for the specified container. The permissions indicate whether container data
|
@@ -10333,7 +10410,7 @@ class Container {
|
|
10333
10410
|
*/
|
10334
10411
|
getAccessPolicy(options) {
|
10335
10412
|
const operationArguments = {
|
10336
|
-
options:
|
10413
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10337
10414
|
};
|
10338
10415
|
return this.client.sendOperationRequest(operationArguments, getAccessPolicyOperationSpec);
|
10339
10416
|
}
|
@@ -10344,7 +10421,7 @@ class Container {
|
|
10344
10421
|
*/
|
10345
10422
|
setAccessPolicy(options) {
|
10346
10423
|
const operationArguments = {
|
10347
|
-
options:
|
10424
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10348
10425
|
};
|
10349
10426
|
return this.client.sendOperationRequest(operationArguments, setAccessPolicyOperationSpec);
|
10350
10427
|
}
|
@@ -10354,7 +10431,7 @@ class Container {
|
|
10354
10431
|
*/
|
10355
10432
|
restore(options) {
|
10356
10433
|
const operationArguments = {
|
10357
|
-
options:
|
10434
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10358
10435
|
};
|
10359
10436
|
return this.client.sendOperationRequest(operationArguments, restoreOperationSpec);
|
10360
10437
|
}
|
@@ -10366,7 +10443,7 @@ class Container {
|
|
10366
10443
|
rename(sourceContainerName, options) {
|
10367
10444
|
const operationArguments = {
|
10368
10445
|
sourceContainerName,
|
10369
|
-
options:
|
10446
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10370
10447
|
};
|
10371
10448
|
return this.client.sendOperationRequest(operationArguments, renameOperationSpec);
|
10372
10449
|
}
|
@@ -10383,9 +10460,20 @@ class Container {
|
|
10383
10460
|
contentLength,
|
10384
10461
|
multipartContentType,
|
10385
10462
|
body,
|
10386
|
-
options:
|
10463
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10387
10464
|
};
|
10388
|
-
return this.client.sendOperationRequest(operationArguments, submitBatchOperationSpec
|
10465
|
+
return this.client.sendOperationRequest(operationArguments, submitBatchOperationSpec);
|
10466
|
+
}
|
10467
|
+
/**
|
10468
|
+
* The Filter Blobs operation enables callers to list blobs in a container whose tags match a given
|
10469
|
+
* search expression. Filter blobs searches within the given container.
|
10470
|
+
* @param options The options parameters.
|
10471
|
+
*/
|
10472
|
+
filterBlobs(options) {
|
10473
|
+
const operationArguments = {
|
10474
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10475
|
+
};
|
10476
|
+
return this.client.sendOperationRequest(operationArguments, filterBlobsOperationSpec);
|
10389
10477
|
}
|
10390
10478
|
/**
|
10391
10479
|
* [Update] establishes and manages a lock on a container for delete operations. The lock duration can
|
@@ -10394,9 +10482,9 @@ class Container {
|
|
10394
10482
|
*/
|
10395
10483
|
acquireLease(options) {
|
10396
10484
|
const operationArguments = {
|
10397
|
-
options:
|
10485
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10398
10486
|
};
|
10399
|
-
return this.client.sendOperationRequest(operationArguments, acquireLeaseOperationSpec);
|
10487
|
+
return this.client.sendOperationRequest(operationArguments, acquireLeaseOperationSpec$1);
|
10400
10488
|
}
|
10401
10489
|
/**
|
10402
10490
|
* [Update] establishes and manages a lock on a container for delete operations. The lock duration can
|
@@ -10407,9 +10495,9 @@ class Container {
|
|
10407
10495
|
releaseLease(leaseId, options) {
|
10408
10496
|
const operationArguments = {
|
10409
10497
|
leaseId,
|
10410
|
-
options:
|
10498
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10411
10499
|
};
|
10412
|
-
return this.client.sendOperationRequest(operationArguments, releaseLeaseOperationSpec);
|
10500
|
+
return this.client.sendOperationRequest(operationArguments, releaseLeaseOperationSpec$1);
|
10413
10501
|
}
|
10414
10502
|
/**
|
10415
10503
|
* [Update] establishes and manages a lock on a container for delete operations. The lock duration can
|
@@ -10420,9 +10508,9 @@ class Container {
|
|
10420
10508
|
renewLease(leaseId, options) {
|
10421
10509
|
const operationArguments = {
|
10422
10510
|
leaseId,
|
10423
|
-
options:
|
10511
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10424
10512
|
};
|
10425
|
-
return this.client.sendOperationRequest(operationArguments, renewLeaseOperationSpec);
|
10513
|
+
return this.client.sendOperationRequest(operationArguments, renewLeaseOperationSpec$1);
|
10426
10514
|
}
|
10427
10515
|
/**
|
10428
10516
|
* [Update] establishes and manages a lock on a container for delete operations. The lock duration can
|
@@ -10431,9 +10519,9 @@ class Container {
|
|
10431
10519
|
*/
|
10432
10520
|
breakLease(options) {
|
10433
10521
|
const operationArguments = {
|
10434
|
-
options:
|
10522
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10435
10523
|
};
|
10436
|
-
return this.client.sendOperationRequest(operationArguments, breakLeaseOperationSpec);
|
10524
|
+
return this.client.sendOperationRequest(operationArguments, breakLeaseOperationSpec$1);
|
10437
10525
|
}
|
10438
10526
|
/**
|
10439
10527
|
* [Update] establishes and manages a lock on a container for delete operations. The lock duration can
|
@@ -10448,9 +10536,9 @@ class Container {
|
|
10448
10536
|
const operationArguments = {
|
10449
10537
|
leaseId,
|
10450
10538
|
proposedLeaseId,
|
10451
|
-
options:
|
10539
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10452
10540
|
};
|
10453
|
-
return this.client.sendOperationRequest(operationArguments, changeLeaseOperationSpec);
|
10541
|
+
return this.client.sendOperationRequest(operationArguments, changeLeaseOperationSpec$1);
|
10454
10542
|
}
|
10455
10543
|
/**
|
10456
10544
|
* [Update] The List Blobs operation returns a list of the blobs under the specified container
|
@@ -10458,7 +10546,7 @@ class Container {
|
|
10458
10546
|
*/
|
10459
10547
|
listBlobFlatSegment(options) {
|
10460
10548
|
const operationArguments = {
|
10461
|
-
options:
|
10549
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10462
10550
|
};
|
10463
10551
|
return this.client.sendOperationRequest(operationArguments, listBlobFlatSegmentOperationSpec);
|
10464
10552
|
}
|
@@ -10473,7 +10561,7 @@ class Container {
|
|
10473
10561
|
listBlobHierarchySegment(delimiter, options) {
|
10474
10562
|
const operationArguments = {
|
10475
10563
|
delimiter,
|
10476
|
-
options:
|
10564
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10477
10565
|
};
|
10478
10566
|
return this.client.sendOperationRequest(operationArguments, listBlobHierarchySegmentOperationSpec);
|
10479
10567
|
}
|
@@ -10483,14 +10571,14 @@ class Container {
|
|
10483
10571
|
*/
|
10484
10572
|
getAccountInfo(options) {
|
10485
10573
|
const operationArguments = {
|
10486
|
-
options:
|
10574
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
10487
10575
|
};
|
10488
10576
|
return this.client.sendOperationRequest(operationArguments, getAccountInfoOperationSpec$1);
|
10489
10577
|
}
|
10490
10578
|
}
|
10491
10579
|
// Operation Specifications
|
10492
|
-
const xmlSerializer$
|
10493
|
-
const createOperationSpec = {
|
10580
|
+
const xmlSerializer$4 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
10581
|
+
const createOperationSpec$2 = {
|
10494
10582
|
path: "/{containerName}",
|
10495
10583
|
httpMethod: "PUT",
|
10496
10584
|
responses: {
|
@@ -10514,7 +10602,7 @@ const createOperationSpec = {
|
|
10514
10602
|
preventEncryptionScopeOverride
|
10515
10603
|
],
|
10516
10604
|
isXML: true,
|
10517
|
-
serializer: xmlSerializer$
|
10605
|
+
serializer: xmlSerializer$4
|
10518
10606
|
};
|
10519
10607
|
const getPropertiesOperationSpec$1 = {
|
10520
10608
|
path: "/{containerName}",
|
@@ -10537,9 +10625,9 @@ const getPropertiesOperationSpec$1 = {
|
|
10537
10625
|
leaseId
|
10538
10626
|
],
|
10539
10627
|
isXML: true,
|
10540
|
-
serializer: xmlSerializer$
|
10628
|
+
serializer: xmlSerializer$4
|
10541
10629
|
};
|
10542
|
-
const deleteOperationSpec = {
|
10630
|
+
const deleteOperationSpec$1 = {
|
10543
10631
|
path: "/{containerName}",
|
10544
10632
|
httpMethod: "DELETE",
|
10545
10633
|
responses: {
|
@@ -10562,9 +10650,9 @@ const deleteOperationSpec = {
|
|
10562
10650
|
ifUnmodifiedSince
|
10563
10651
|
],
|
10564
10652
|
isXML: true,
|
10565
|
-
serializer: xmlSerializer$
|
10653
|
+
serializer: xmlSerializer$4
|
10566
10654
|
};
|
10567
|
-
const setMetadataOperationSpec = {
|
10655
|
+
const setMetadataOperationSpec$1 = {
|
10568
10656
|
path: "/{containerName}",
|
10569
10657
|
httpMethod: "PUT",
|
10570
10658
|
responses: {
|
@@ -10591,7 +10679,7 @@ const setMetadataOperationSpec = {
|
|
10591
10679
|
ifModifiedSince
|
10592
10680
|
],
|
10593
10681
|
isXML: true,
|
10594
|
-
serializer: xmlSerializer$
|
10682
|
+
serializer: xmlSerializer$4
|
10595
10683
|
};
|
10596
10684
|
const getAccessPolicyOperationSpec = {
|
10597
10685
|
path: "/{containerName}",
|
@@ -10630,7 +10718,7 @@ const getAccessPolicyOperationSpec = {
|
|
10630
10718
|
leaseId
|
10631
10719
|
],
|
10632
10720
|
isXML: true,
|
10633
|
-
serializer: xmlSerializer$
|
10721
|
+
serializer: xmlSerializer$4
|
10634
10722
|
};
|
10635
10723
|
const setAccessPolicyOperationSpec = {
|
10636
10724
|
path: "/{containerName}",
|
@@ -10664,7 +10752,7 @@ const setAccessPolicyOperationSpec = {
|
|
10664
10752
|
isXML: true,
|
10665
10753
|
contentType: "application/xml; charset=utf-8",
|
10666
10754
|
mediaType: "xml",
|
10667
|
-
serializer: xmlSerializer$
|
10755
|
+
serializer: xmlSerializer$4
|
10668
10756
|
};
|
10669
10757
|
const restoreOperationSpec = {
|
10670
10758
|
path: "/{containerName}",
|
@@ -10692,7 +10780,7 @@ const restoreOperationSpec = {
|
|
10692
10780
|
deletedContainerVersion
|
10693
10781
|
],
|
10694
10782
|
isXML: true,
|
10695
|
-
serializer: xmlSerializer$
|
10783
|
+
serializer: xmlSerializer$4
|
10696
10784
|
};
|
10697
10785
|
const renameOperationSpec = {
|
10698
10786
|
path: "/{containerName}",
|
@@ -10720,9 +10808,9 @@ const renameOperationSpec = {
|
|
10720
10808
|
sourceLeaseId
|
10721
10809
|
],
|
10722
10810
|
isXML: true,
|
10723
|
-
serializer: xmlSerializer$
|
10811
|
+
serializer: xmlSerializer$4
|
10724
10812
|
};
|
10725
|
-
const submitBatchOperationSpec
|
10813
|
+
const submitBatchOperationSpec = {
|
10726
10814
|
path: "/{containerName}",
|
10727
10815
|
httpMethod: "POST",
|
10728
10816
|
responses: {
|
@@ -10756,9 +10844,39 @@ const submitBatchOperationSpec$1 = {
|
|
10756
10844
|
isXML: true,
|
10757
10845
|
contentType: "application/xml; charset=utf-8",
|
10758
10846
|
mediaType: "xml",
|
10759
|
-
serializer: xmlSerializer$
|
10847
|
+
serializer: xmlSerializer$4
|
10760
10848
|
};
|
10761
|
-
const
|
10849
|
+
const filterBlobsOperationSpec = {
|
10850
|
+
path: "/{containerName}",
|
10851
|
+
httpMethod: "GET",
|
10852
|
+
responses: {
|
10853
|
+
200: {
|
10854
|
+
bodyMapper: FilterBlobSegment,
|
10855
|
+
headersMapper: ContainerFilterBlobsHeaders
|
10856
|
+
},
|
10857
|
+
default: {
|
10858
|
+
bodyMapper: StorageError,
|
10859
|
+
headersMapper: ContainerFilterBlobsExceptionHeaders
|
10860
|
+
}
|
10861
|
+
},
|
10862
|
+
queryParameters: [
|
10863
|
+
timeoutInSeconds,
|
10864
|
+
marker,
|
10865
|
+
maxPageSize,
|
10866
|
+
comp5,
|
10867
|
+
where,
|
10868
|
+
restype2
|
10869
|
+
],
|
10870
|
+
urlParameters: [url],
|
10871
|
+
headerParameters: [
|
10872
|
+
version,
|
10873
|
+
requestId,
|
10874
|
+
accept1
|
10875
|
+
],
|
10876
|
+
isXML: true,
|
10877
|
+
serializer: xmlSerializer$4
|
10878
|
+
};
|
10879
|
+
const acquireLeaseOperationSpec$1 = {
|
10762
10880
|
path: "/{containerName}",
|
10763
10881
|
httpMethod: "PUT",
|
10764
10882
|
responses: {
|
@@ -10787,9 +10905,9 @@ const acquireLeaseOperationSpec = {
|
|
10787
10905
|
proposedLeaseId
|
10788
10906
|
],
|
10789
10907
|
isXML: true,
|
10790
|
-
serializer: xmlSerializer$
|
10908
|
+
serializer: xmlSerializer$4
|
10791
10909
|
};
|
10792
|
-
const releaseLeaseOperationSpec = {
|
10910
|
+
const releaseLeaseOperationSpec$1 = {
|
10793
10911
|
path: "/{containerName}",
|
10794
10912
|
httpMethod: "PUT",
|
10795
10913
|
responses: {
|
@@ -10817,9 +10935,9 @@ const releaseLeaseOperationSpec = {
|
|
10817
10935
|
leaseId1
|
10818
10936
|
],
|
10819
10937
|
isXML: true,
|
10820
|
-
serializer: xmlSerializer$
|
10938
|
+
serializer: xmlSerializer$4
|
10821
10939
|
};
|
10822
|
-
const renewLeaseOperationSpec = {
|
10940
|
+
const renewLeaseOperationSpec$1 = {
|
10823
10941
|
path: "/{containerName}",
|
10824
10942
|
httpMethod: "PUT",
|
10825
10943
|
responses: {
|
@@ -10847,9 +10965,9 @@ const renewLeaseOperationSpec = {
|
|
10847
10965
|
action2
|
10848
10966
|
],
|
10849
10967
|
isXML: true,
|
10850
|
-
serializer: xmlSerializer$
|
10968
|
+
serializer: xmlSerializer$4
|
10851
10969
|
};
|
10852
|
-
const breakLeaseOperationSpec = {
|
10970
|
+
const breakLeaseOperationSpec$1 = {
|
10853
10971
|
path: "/{containerName}",
|
10854
10972
|
httpMethod: "PUT",
|
10855
10973
|
responses: {
|
@@ -10877,9 +10995,9 @@ const breakLeaseOperationSpec = {
|
|
10877
10995
|
breakPeriod
|
10878
10996
|
],
|
10879
10997
|
isXML: true,
|
10880
|
-
serializer: xmlSerializer$
|
10998
|
+
serializer: xmlSerializer$4
|
10881
10999
|
};
|
10882
|
-
const changeLeaseOperationSpec = {
|
11000
|
+
const changeLeaseOperationSpec$1 = {
|
10883
11001
|
path: "/{containerName}",
|
10884
11002
|
httpMethod: "PUT",
|
10885
11003
|
responses: {
|
@@ -10908,7 +11026,7 @@ const changeLeaseOperationSpec = {
|
|
10908
11026
|
proposedLeaseId1
|
10909
11027
|
],
|
10910
11028
|
isXML: true,
|
10911
|
-
serializer: xmlSerializer$
|
11029
|
+
serializer: xmlSerializer$4
|
10912
11030
|
};
|
10913
11031
|
const listBlobFlatSegmentOperationSpec = {
|
10914
11032
|
path: "/{containerName}",
|
@@ -10939,7 +11057,7 @@ const listBlobFlatSegmentOperationSpec = {
|
|
10939
11057
|
accept1
|
10940
11058
|
],
|
10941
11059
|
isXML: true,
|
10942
|
-
serializer: xmlSerializer$
|
11060
|
+
serializer: xmlSerializer$4
|
10943
11061
|
};
|
10944
11062
|
const listBlobHierarchySegmentOperationSpec = {
|
10945
11063
|
path: "/{containerName}",
|
@@ -10971,7 +11089,7 @@ const listBlobHierarchySegmentOperationSpec = {
|
|
10971
11089
|
accept1
|
10972
11090
|
],
|
10973
11091
|
isXML: true,
|
10974
|
-
serializer: xmlSerializer$
|
11092
|
+
serializer: xmlSerializer$4
|
10975
11093
|
};
|
10976
11094
|
const getAccountInfoOperationSpec$1 = {
|
10977
11095
|
path: "/{containerName}",
|
@@ -10989,7 +11107,7 @@ const getAccountInfoOperationSpec$1 = {
|
|
10989
11107
|
urlParameters: [url],
|
10990
11108
|
headerParameters: [version, accept1],
|
10991
11109
|
isXML: true,
|
10992
|
-
serializer: xmlSerializer$
|
11110
|
+
serializer: xmlSerializer$4
|
10993
11111
|
};
|
10994
11112
|
|
10995
11113
|
/*
|
@@ -11015,7 +11133,7 @@ class Blob$1 {
|
|
11015
11133
|
*/
|
11016
11134
|
download(options) {
|
11017
11135
|
const operationArguments = {
|
11018
|
-
options:
|
11136
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11019
11137
|
};
|
11020
11138
|
return this.client.sendOperationRequest(operationArguments, downloadOperationSpec);
|
11021
11139
|
}
|
@@ -11026,9 +11144,9 @@ class Blob$1 {
|
|
11026
11144
|
*/
|
11027
11145
|
getProperties(options) {
|
11028
11146
|
const operationArguments = {
|
11029
|
-
options:
|
11147
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11030
11148
|
};
|
11031
|
-
return this.client.sendOperationRequest(operationArguments, getPropertiesOperationSpec
|
11149
|
+
return this.client.sendOperationRequest(operationArguments, getPropertiesOperationSpec);
|
11032
11150
|
}
|
11033
11151
|
/**
|
11034
11152
|
* If the storage account's soft delete feature is disabled then, when a blob is deleted, it is
|
@@ -11047,9 +11165,9 @@ class Blob$1 {
|
|
11047
11165
|
*/
|
11048
11166
|
delete(options) {
|
11049
11167
|
const operationArguments = {
|
11050
|
-
options:
|
11168
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11051
11169
|
};
|
11052
|
-
return this.client.sendOperationRequest(operationArguments, deleteOperationSpec
|
11170
|
+
return this.client.sendOperationRequest(operationArguments, deleteOperationSpec);
|
11053
11171
|
}
|
11054
11172
|
/**
|
11055
11173
|
* Undelete a blob that was previously soft deleted
|
@@ -11057,7 +11175,7 @@ class Blob$1 {
|
|
11057
11175
|
*/
|
11058
11176
|
undelete(options) {
|
11059
11177
|
const operationArguments = {
|
11060
|
-
options:
|
11178
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11061
11179
|
};
|
11062
11180
|
return this.client.sendOperationRequest(operationArguments, undeleteOperationSpec);
|
11063
11181
|
}
|
@@ -11069,7 +11187,7 @@ class Blob$1 {
|
|
11069
11187
|
setExpiry(expiryOptions, options) {
|
11070
11188
|
const operationArguments = {
|
11071
11189
|
expiryOptions,
|
11072
|
-
options:
|
11190
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11073
11191
|
};
|
11074
11192
|
return this.client.sendOperationRequest(operationArguments, setExpiryOperationSpec);
|
11075
11193
|
}
|
@@ -11079,7 +11197,7 @@ class Blob$1 {
|
|
11079
11197
|
*/
|
11080
11198
|
setHttpHeaders(options) {
|
11081
11199
|
const operationArguments = {
|
11082
|
-
options:
|
11200
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11083
11201
|
};
|
11084
11202
|
return this.client.sendOperationRequest(operationArguments, setHttpHeadersOperationSpec);
|
11085
11203
|
}
|
@@ -11089,7 +11207,7 @@ class Blob$1 {
|
|
11089
11207
|
*/
|
11090
11208
|
setImmutabilityPolicy(options) {
|
11091
11209
|
const operationArguments = {
|
11092
|
-
options:
|
11210
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11093
11211
|
};
|
11094
11212
|
return this.client.sendOperationRequest(operationArguments, setImmutabilityPolicyOperationSpec);
|
11095
11213
|
}
|
@@ -11099,7 +11217,7 @@ class Blob$1 {
|
|
11099
11217
|
*/
|
11100
11218
|
deleteImmutabilityPolicy(options) {
|
11101
11219
|
const operationArguments = {
|
11102
|
-
options:
|
11220
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11103
11221
|
};
|
11104
11222
|
return this.client.sendOperationRequest(operationArguments, deleteImmutabilityPolicyOperationSpec);
|
11105
11223
|
}
|
@@ -11111,7 +11229,7 @@ class Blob$1 {
|
|
11111
11229
|
setLegalHold(legalHold, options) {
|
11112
11230
|
const operationArguments = {
|
11113
11231
|
legalHold,
|
11114
|
-
options:
|
11232
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11115
11233
|
};
|
11116
11234
|
return this.client.sendOperationRequest(operationArguments, setLegalHoldOperationSpec);
|
11117
11235
|
}
|
@@ -11122,9 +11240,9 @@ class Blob$1 {
|
|
11122
11240
|
*/
|
11123
11241
|
setMetadata(options) {
|
11124
11242
|
const operationArguments = {
|
11125
|
-
options:
|
11243
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11126
11244
|
};
|
11127
|
-
return this.client.sendOperationRequest(operationArguments, setMetadataOperationSpec
|
11245
|
+
return this.client.sendOperationRequest(operationArguments, setMetadataOperationSpec);
|
11128
11246
|
}
|
11129
11247
|
/**
|
11130
11248
|
* [Update] The Lease Blob operation establishes and manages a lock on a blob for write and delete
|
@@ -11133,9 +11251,9 @@ class Blob$1 {
|
|
11133
11251
|
*/
|
11134
11252
|
acquireLease(options) {
|
11135
11253
|
const operationArguments = {
|
11136
|
-
options:
|
11254
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11137
11255
|
};
|
11138
|
-
return this.client.sendOperationRequest(operationArguments, acquireLeaseOperationSpec
|
11256
|
+
return this.client.sendOperationRequest(operationArguments, acquireLeaseOperationSpec);
|
11139
11257
|
}
|
11140
11258
|
/**
|
11141
11259
|
* [Update] The Lease Blob operation establishes and manages a lock on a blob for write and delete
|
@@ -11146,9 +11264,9 @@ class Blob$1 {
|
|
11146
11264
|
releaseLease(leaseId, options) {
|
11147
11265
|
const operationArguments = {
|
11148
11266
|
leaseId,
|
11149
|
-
options:
|
11267
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11150
11268
|
};
|
11151
|
-
return this.client.sendOperationRequest(operationArguments, releaseLeaseOperationSpec
|
11269
|
+
return this.client.sendOperationRequest(operationArguments, releaseLeaseOperationSpec);
|
11152
11270
|
}
|
11153
11271
|
/**
|
11154
11272
|
* [Update] The Lease Blob operation establishes and manages a lock on a blob for write and delete
|
@@ -11159,9 +11277,9 @@ class Blob$1 {
|
|
11159
11277
|
renewLease(leaseId, options) {
|
11160
11278
|
const operationArguments = {
|
11161
11279
|
leaseId,
|
11162
|
-
options:
|
11280
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11163
11281
|
};
|
11164
|
-
return this.client.sendOperationRequest(operationArguments, renewLeaseOperationSpec
|
11282
|
+
return this.client.sendOperationRequest(operationArguments, renewLeaseOperationSpec);
|
11165
11283
|
}
|
11166
11284
|
/**
|
11167
11285
|
* [Update] The Lease Blob operation establishes and manages a lock on a blob for write and delete
|
@@ -11176,9 +11294,9 @@ class Blob$1 {
|
|
11176
11294
|
const operationArguments = {
|
11177
11295
|
leaseId,
|
11178
11296
|
proposedLeaseId,
|
11179
|
-
options:
|
11297
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11180
11298
|
};
|
11181
|
-
return this.client.sendOperationRequest(operationArguments, changeLeaseOperationSpec
|
11299
|
+
return this.client.sendOperationRequest(operationArguments, changeLeaseOperationSpec);
|
11182
11300
|
}
|
11183
11301
|
/**
|
11184
11302
|
* [Update] The Lease Blob operation establishes and manages a lock on a blob for write and delete
|
@@ -11187,9 +11305,9 @@ class Blob$1 {
|
|
11187
11305
|
*/
|
11188
11306
|
breakLease(options) {
|
11189
11307
|
const operationArguments = {
|
11190
|
-
options:
|
11308
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11191
11309
|
};
|
11192
|
-
return this.client.sendOperationRequest(operationArguments, breakLeaseOperationSpec
|
11310
|
+
return this.client.sendOperationRequest(operationArguments, breakLeaseOperationSpec);
|
11193
11311
|
}
|
11194
11312
|
/**
|
11195
11313
|
* The Create Snapshot operation creates a read-only snapshot of a blob
|
@@ -11197,7 +11315,7 @@ class Blob$1 {
|
|
11197
11315
|
*/
|
11198
11316
|
createSnapshot(options) {
|
11199
11317
|
const operationArguments = {
|
11200
|
-
options:
|
11318
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11201
11319
|
};
|
11202
11320
|
return this.client.sendOperationRequest(operationArguments, createSnapshotOperationSpec);
|
11203
11321
|
}
|
@@ -11212,7 +11330,7 @@ class Blob$1 {
|
|
11212
11330
|
startCopyFromURL(copySource, options) {
|
11213
11331
|
const operationArguments = {
|
11214
11332
|
copySource,
|
11215
|
-
options:
|
11333
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11216
11334
|
};
|
11217
11335
|
return this.client.sendOperationRequest(operationArguments, startCopyFromURLOperationSpec);
|
11218
11336
|
}
|
@@ -11228,7 +11346,7 @@ class Blob$1 {
|
|
11228
11346
|
copyFromURL(copySource, options) {
|
11229
11347
|
const operationArguments = {
|
11230
11348
|
copySource,
|
11231
|
-
options:
|
11349
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11232
11350
|
};
|
11233
11351
|
return this.client.sendOperationRequest(operationArguments, copyFromURLOperationSpec);
|
11234
11352
|
}
|
@@ -11242,7 +11360,7 @@ class Blob$1 {
|
|
11242
11360
|
abortCopyFromURL(copyId, options) {
|
11243
11361
|
const operationArguments = {
|
11244
11362
|
copyId,
|
11245
|
-
options:
|
11363
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11246
11364
|
};
|
11247
11365
|
return this.client.sendOperationRequest(operationArguments, abortCopyFromURLOperationSpec);
|
11248
11366
|
}
|
@@ -11258,7 +11376,7 @@ class Blob$1 {
|
|
11258
11376
|
setTier(tier, options) {
|
11259
11377
|
const operationArguments = {
|
11260
11378
|
tier,
|
11261
|
-
options:
|
11379
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11262
11380
|
};
|
11263
11381
|
return this.client.sendOperationRequest(operationArguments, setTierOperationSpec);
|
11264
11382
|
}
|
@@ -11268,9 +11386,9 @@ class Blob$1 {
|
|
11268
11386
|
*/
|
11269
11387
|
getAccountInfo(options) {
|
11270
11388
|
const operationArguments = {
|
11271
|
-
options:
|
11389
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11272
11390
|
};
|
11273
|
-
return this.client.sendOperationRequest(operationArguments, getAccountInfoOperationSpec
|
11391
|
+
return this.client.sendOperationRequest(operationArguments, getAccountInfoOperationSpec);
|
11274
11392
|
}
|
11275
11393
|
/**
|
11276
11394
|
* The Query operation enables users to select/project on blob data by providing simple query
|
@@ -11279,7 +11397,7 @@ class Blob$1 {
|
|
11279
11397
|
*/
|
11280
11398
|
query(options) {
|
11281
11399
|
const operationArguments = {
|
11282
|
-
options:
|
11400
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11283
11401
|
};
|
11284
11402
|
return this.client.sendOperationRequest(operationArguments, queryOperationSpec);
|
11285
11403
|
}
|
@@ -11289,7 +11407,7 @@ class Blob$1 {
|
|
11289
11407
|
*/
|
11290
11408
|
getTags(options) {
|
11291
11409
|
const operationArguments = {
|
11292
|
-
options:
|
11410
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11293
11411
|
};
|
11294
11412
|
return this.client.sendOperationRequest(operationArguments, getTagsOperationSpec);
|
11295
11413
|
}
|
@@ -11299,13 +11417,13 @@ class Blob$1 {
|
|
11299
11417
|
*/
|
11300
11418
|
setTags(options) {
|
11301
11419
|
const operationArguments = {
|
11302
|
-
options:
|
11420
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
11303
11421
|
};
|
11304
11422
|
return this.client.sendOperationRequest(operationArguments, setTagsOperationSpec);
|
11305
11423
|
}
|
11306
11424
|
}
|
11307
11425
|
// Operation Specifications
|
11308
|
-
const xmlSerializer$
|
11426
|
+
const xmlSerializer$3 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
11309
11427
|
const downloadOperationSpec = {
|
11310
11428
|
path: "/{containerName}/{blob}",
|
11311
11429
|
httpMethod: "GET",
|
@@ -11353,9 +11471,9 @@ const downloadOperationSpec = {
|
|
11353
11471
|
ifTags
|
11354
11472
|
],
|
11355
11473
|
isXML: true,
|
11356
|
-
serializer: xmlSerializer$
|
11474
|
+
serializer: xmlSerializer$3
|
11357
11475
|
};
|
11358
|
-
const getPropertiesOperationSpec
|
11476
|
+
const getPropertiesOperationSpec = {
|
11359
11477
|
path: "/{containerName}/{blob}",
|
11360
11478
|
httpMethod: "HEAD",
|
11361
11479
|
responses: {
|
@@ -11388,9 +11506,9 @@ const getPropertiesOperationSpec$2 = {
|
|
11388
11506
|
ifTags
|
11389
11507
|
],
|
11390
11508
|
isXML: true,
|
11391
|
-
serializer: xmlSerializer$
|
11509
|
+
serializer: xmlSerializer$3
|
11392
11510
|
};
|
11393
|
-
const deleteOperationSpec
|
11511
|
+
const deleteOperationSpec = {
|
11394
11512
|
path: "/{containerName}/{blob}",
|
11395
11513
|
httpMethod: "DELETE",
|
11396
11514
|
responses: {
|
@@ -11422,7 +11540,7 @@ const deleteOperationSpec$1 = {
|
|
11422
11540
|
deleteSnapshots
|
11423
11541
|
],
|
11424
11542
|
isXML: true,
|
11425
|
-
serializer: xmlSerializer$
|
11543
|
+
serializer: xmlSerializer$3
|
11426
11544
|
};
|
11427
11545
|
const undeleteOperationSpec = {
|
11428
11546
|
path: "/{containerName}/{blob}",
|
@@ -11444,7 +11562,7 @@ const undeleteOperationSpec = {
|
|
11444
11562
|
accept1
|
11445
11563
|
],
|
11446
11564
|
isXML: true,
|
11447
|
-
serializer: xmlSerializer$
|
11565
|
+
serializer: xmlSerializer$3
|
11448
11566
|
};
|
11449
11567
|
const setExpiryOperationSpec = {
|
11450
11568
|
path: "/{containerName}/{blob}",
|
@@ -11468,7 +11586,7 @@ const setExpiryOperationSpec = {
|
|
11468
11586
|
expiresOn
|
11469
11587
|
],
|
11470
11588
|
isXML: true,
|
11471
|
-
serializer: xmlSerializer$
|
11589
|
+
serializer: xmlSerializer$3
|
11472
11590
|
};
|
11473
11591
|
const setHttpHeadersOperationSpec = {
|
11474
11592
|
path: "/{containerName}/{blob}",
|
@@ -11502,7 +11620,7 @@ const setHttpHeadersOperationSpec = {
|
|
11502
11620
|
blobContentDisposition
|
11503
11621
|
],
|
11504
11622
|
isXML: true,
|
11505
|
-
serializer: xmlSerializer$
|
11623
|
+
serializer: xmlSerializer$3
|
11506
11624
|
};
|
11507
11625
|
const setImmutabilityPolicyOperationSpec = {
|
11508
11626
|
path: "/{containerName}/{blob}",
|
@@ -11527,7 +11645,7 @@ const setImmutabilityPolicyOperationSpec = {
|
|
11527
11645
|
immutabilityPolicyMode
|
11528
11646
|
],
|
11529
11647
|
isXML: true,
|
11530
|
-
serializer: xmlSerializer$
|
11648
|
+
serializer: xmlSerializer$3
|
11531
11649
|
};
|
11532
11650
|
const deleteImmutabilityPolicyOperationSpec = {
|
11533
11651
|
path: "/{containerName}/{blob}",
|
@@ -11549,7 +11667,7 @@ const deleteImmutabilityPolicyOperationSpec = {
|
|
11549
11667
|
accept1
|
11550
11668
|
],
|
11551
11669
|
isXML: true,
|
11552
|
-
serializer: xmlSerializer$
|
11670
|
+
serializer: xmlSerializer$3
|
11553
11671
|
};
|
11554
11672
|
const setLegalHoldOperationSpec = {
|
11555
11673
|
path: "/{containerName}/{blob}",
|
@@ -11572,9 +11690,9 @@ const setLegalHoldOperationSpec = {
|
|
11572
11690
|
legalHold
|
11573
11691
|
],
|
11574
11692
|
isXML: true,
|
11575
|
-
serializer: xmlSerializer$
|
11693
|
+
serializer: xmlSerializer$3
|
11576
11694
|
};
|
11577
|
-
const setMetadataOperationSpec
|
11695
|
+
const setMetadataOperationSpec = {
|
11578
11696
|
path: "/{containerName}/{blob}",
|
11579
11697
|
httpMethod: "PUT",
|
11580
11698
|
responses: {
|
@@ -11605,9 +11723,9 @@ const setMetadataOperationSpec$1 = {
|
|
11605
11723
|
encryptionScope
|
11606
11724
|
],
|
11607
11725
|
isXML: true,
|
11608
|
-
serializer: xmlSerializer$
|
11726
|
+
serializer: xmlSerializer$3
|
11609
11727
|
};
|
11610
|
-
const acquireLeaseOperationSpec
|
11728
|
+
const acquireLeaseOperationSpec = {
|
11611
11729
|
path: "/{containerName}/{blob}",
|
11612
11730
|
httpMethod: "PUT",
|
11613
11731
|
responses: {
|
@@ -11635,9 +11753,9 @@ const acquireLeaseOperationSpec$1 = {
|
|
11635
11753
|
ifTags
|
11636
11754
|
],
|
11637
11755
|
isXML: true,
|
11638
|
-
serializer: xmlSerializer$
|
11756
|
+
serializer: xmlSerializer$3
|
11639
11757
|
};
|
11640
|
-
const releaseLeaseOperationSpec
|
11758
|
+
const releaseLeaseOperationSpec = {
|
11641
11759
|
path: "/{containerName}/{blob}",
|
11642
11760
|
httpMethod: "PUT",
|
11643
11761
|
responses: {
|
@@ -11664,9 +11782,9 @@ const releaseLeaseOperationSpec$1 = {
|
|
11664
11782
|
ifTags
|
11665
11783
|
],
|
11666
11784
|
isXML: true,
|
11667
|
-
serializer: xmlSerializer$
|
11785
|
+
serializer: xmlSerializer$3
|
11668
11786
|
};
|
11669
|
-
const renewLeaseOperationSpec
|
11787
|
+
const renewLeaseOperationSpec = {
|
11670
11788
|
path: "/{containerName}/{blob}",
|
11671
11789
|
httpMethod: "PUT",
|
11672
11790
|
responses: {
|
@@ -11693,9 +11811,9 @@ const renewLeaseOperationSpec$1 = {
|
|
11693
11811
|
ifTags
|
11694
11812
|
],
|
11695
11813
|
isXML: true,
|
11696
|
-
serializer: xmlSerializer$
|
11814
|
+
serializer: xmlSerializer$3
|
11697
11815
|
};
|
11698
|
-
const changeLeaseOperationSpec
|
11816
|
+
const changeLeaseOperationSpec = {
|
11699
11817
|
path: "/{containerName}/{blob}",
|
11700
11818
|
httpMethod: "PUT",
|
11701
11819
|
responses: {
|
@@ -11723,9 +11841,9 @@ const changeLeaseOperationSpec$1 = {
|
|
11723
11841
|
ifTags
|
11724
11842
|
],
|
11725
11843
|
isXML: true,
|
11726
|
-
serializer: xmlSerializer$
|
11844
|
+
serializer: xmlSerializer$3
|
11727
11845
|
};
|
11728
|
-
const breakLeaseOperationSpec
|
11846
|
+
const breakLeaseOperationSpec = {
|
11729
11847
|
path: "/{containerName}/{blob}",
|
11730
11848
|
httpMethod: "PUT",
|
11731
11849
|
responses: {
|
@@ -11752,7 +11870,7 @@ const breakLeaseOperationSpec$1 = {
|
|
11752
11870
|
ifTags
|
11753
11871
|
],
|
11754
11872
|
isXML: true,
|
11755
|
-
serializer: xmlSerializer$
|
11873
|
+
serializer: xmlSerializer$3
|
11756
11874
|
};
|
11757
11875
|
const createSnapshotOperationSpec = {
|
11758
11876
|
path: "/{containerName}/{blob}",
|
@@ -11785,7 +11903,7 @@ const createSnapshotOperationSpec = {
|
|
11785
11903
|
encryptionScope
|
11786
11904
|
],
|
11787
11905
|
isXML: true,
|
11788
|
-
serializer: xmlSerializer$
|
11906
|
+
serializer: xmlSerializer$3
|
11789
11907
|
};
|
11790
11908
|
const startCopyFromURLOperationSpec = {
|
11791
11909
|
path: "/{containerName}/{blob}",
|
@@ -11827,7 +11945,7 @@ const startCopyFromURLOperationSpec = {
|
|
11827
11945
|
legalHold1
|
11828
11946
|
],
|
11829
11947
|
isXML: true,
|
11830
|
-
serializer: xmlSerializer$
|
11948
|
+
serializer: xmlSerializer$3
|
11831
11949
|
};
|
11832
11950
|
const copyFromURLOperationSpec = {
|
11833
11951
|
path: "/{containerName}/{blob}",
|
@@ -11870,7 +11988,7 @@ const copyFromURLOperationSpec = {
|
|
11870
11988
|
copySourceAuthorization
|
11871
11989
|
],
|
11872
11990
|
isXML: true,
|
11873
|
-
serializer: xmlSerializer$
|
11991
|
+
serializer: xmlSerializer$3
|
11874
11992
|
};
|
11875
11993
|
const abortCopyFromURLOperationSpec = {
|
11876
11994
|
path: "/{containerName}/{blob}",
|
@@ -11898,7 +12016,7 @@ const abortCopyFromURLOperationSpec = {
|
|
11898
12016
|
copyActionAbortConstant
|
11899
12017
|
],
|
11900
12018
|
isXML: true,
|
11901
|
-
serializer: xmlSerializer$
|
12019
|
+
serializer: xmlSerializer$3
|
11902
12020
|
};
|
11903
12021
|
const setTierOperationSpec = {
|
11904
12022
|
path: "/{containerName}/{blob}",
|
@@ -11932,9 +12050,9 @@ const setTierOperationSpec = {
|
|
11932
12050
|
tier1
|
11933
12051
|
],
|
11934
12052
|
isXML: true,
|
11935
|
-
serializer: xmlSerializer$
|
12053
|
+
serializer: xmlSerializer$3
|
11936
12054
|
};
|
11937
|
-
const getAccountInfoOperationSpec
|
12055
|
+
const getAccountInfoOperationSpec = {
|
11938
12056
|
path: "/{containerName}/{blob}",
|
11939
12057
|
httpMethod: "GET",
|
11940
12058
|
responses: {
|
@@ -11950,7 +12068,7 @@ const getAccountInfoOperationSpec$2 = {
|
|
11950
12068
|
urlParameters: [url],
|
11951
12069
|
headerParameters: [version, accept1],
|
11952
12070
|
isXML: true,
|
11953
|
-
serializer: xmlSerializer$
|
12071
|
+
serializer: xmlSerializer$3
|
11954
12072
|
};
|
11955
12073
|
const queryOperationSpec = {
|
11956
12074
|
path: "/{containerName}/{blob}",
|
@@ -12000,7 +12118,7 @@ const queryOperationSpec = {
|
|
12000
12118
|
isXML: true,
|
12001
12119
|
contentType: "application/xml; charset=utf-8",
|
12002
12120
|
mediaType: "xml",
|
12003
|
-
serializer: xmlSerializer$
|
12121
|
+
serializer: xmlSerializer$3
|
12004
12122
|
};
|
12005
12123
|
const getTagsOperationSpec = {
|
12006
12124
|
path: "/{containerName}/{blob}",
|
@@ -12030,7 +12148,7 @@ const getTagsOperationSpec = {
|
|
12030
12148
|
ifTags
|
12031
12149
|
],
|
12032
12150
|
isXML: true,
|
12033
|
-
serializer: xmlSerializer$
|
12151
|
+
serializer: xmlSerializer$3
|
12034
12152
|
};
|
12035
12153
|
const setTagsOperationSpec = {
|
12036
12154
|
path: "/{containerName}/{blob}",
|
@@ -12064,7 +12182,7 @@ const setTagsOperationSpec = {
|
|
12064
12182
|
isXML: true,
|
12065
12183
|
contentType: "application/xml; charset=utf-8",
|
12066
12184
|
mediaType: "xml",
|
12067
|
-
serializer: xmlSerializer$
|
12185
|
+
serializer: xmlSerializer$3
|
12068
12186
|
};
|
12069
12187
|
|
12070
12188
|
/*
|
@@ -12094,7 +12212,7 @@ class PageBlob {
|
|
12094
12212
|
const operationArguments = {
|
12095
12213
|
contentLength,
|
12096
12214
|
blobContentLength,
|
12097
|
-
options:
|
12215
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12098
12216
|
};
|
12099
12217
|
return this.client.sendOperationRequest(operationArguments, createOperationSpec$1);
|
12100
12218
|
}
|
@@ -12108,7 +12226,7 @@ class PageBlob {
|
|
12108
12226
|
const operationArguments = {
|
12109
12227
|
contentLength,
|
12110
12228
|
body,
|
12111
|
-
options:
|
12229
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12112
12230
|
};
|
12113
12231
|
return this.client.sendOperationRequest(operationArguments, uploadPagesOperationSpec);
|
12114
12232
|
}
|
@@ -12120,7 +12238,7 @@ class PageBlob {
|
|
12120
12238
|
clearPages(contentLength, options) {
|
12121
12239
|
const operationArguments = {
|
12122
12240
|
contentLength,
|
12123
|
-
options:
|
12241
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12124
12242
|
};
|
12125
12243
|
return this.client.sendOperationRequest(operationArguments, clearPagesOperationSpec);
|
12126
12244
|
}
|
@@ -12141,7 +12259,7 @@ class PageBlob {
|
|
12141
12259
|
sourceRange,
|
12142
12260
|
contentLength,
|
12143
12261
|
range,
|
12144
|
-
options:
|
12262
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12145
12263
|
};
|
12146
12264
|
return this.client.sendOperationRequest(operationArguments, uploadPagesFromURLOperationSpec);
|
12147
12265
|
}
|
@@ -12152,7 +12270,7 @@ class PageBlob {
|
|
12152
12270
|
*/
|
12153
12271
|
getPageRanges(options) {
|
12154
12272
|
const operationArguments = {
|
12155
|
-
options:
|
12273
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12156
12274
|
};
|
12157
12275
|
return this.client.sendOperationRequest(operationArguments, getPageRangesOperationSpec);
|
12158
12276
|
}
|
@@ -12163,7 +12281,7 @@ class PageBlob {
|
|
12163
12281
|
*/
|
12164
12282
|
getPageRangesDiff(options) {
|
12165
12283
|
const operationArguments = {
|
12166
|
-
options:
|
12284
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12167
12285
|
};
|
12168
12286
|
return this.client.sendOperationRequest(operationArguments, getPageRangesDiffOperationSpec);
|
12169
12287
|
}
|
@@ -12176,7 +12294,7 @@ class PageBlob {
|
|
12176
12294
|
resize(blobContentLength, options) {
|
12177
12295
|
const operationArguments = {
|
12178
12296
|
blobContentLength,
|
12179
|
-
options:
|
12297
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12180
12298
|
};
|
12181
12299
|
return this.client.sendOperationRequest(operationArguments, resizeOperationSpec);
|
12182
12300
|
}
|
@@ -12190,7 +12308,7 @@ class PageBlob {
|
|
12190
12308
|
updateSequenceNumber(sequenceNumberAction, options) {
|
12191
12309
|
const operationArguments = {
|
12192
12310
|
sequenceNumberAction,
|
12193
|
-
options:
|
12311
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12194
12312
|
};
|
12195
12313
|
return this.client.sendOperationRequest(operationArguments, updateSequenceNumberOperationSpec);
|
12196
12314
|
}
|
@@ -12209,14 +12327,14 @@ class PageBlob {
|
|
12209
12327
|
copyIncremental(copySource, options) {
|
12210
12328
|
const operationArguments = {
|
12211
12329
|
copySource,
|
12212
|
-
options:
|
12330
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12213
12331
|
};
|
12214
12332
|
return this.client.sendOperationRequest(operationArguments, copyIncrementalOperationSpec);
|
12215
12333
|
}
|
12216
12334
|
}
|
12217
12335
|
// Operation Specifications
|
12218
|
-
const xmlSerializer$
|
12219
|
-
const serializer = new
|
12336
|
+
const xmlSerializer$2 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
12337
|
+
const serializer$2 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ false);
|
12220
12338
|
const createOperationSpec$1 = {
|
12221
12339
|
path: "/{containerName}/{blob}",
|
12222
12340
|
httpMethod: "PUT",
|
@@ -12263,7 +12381,7 @@ const createOperationSpec$1 = {
|
|
12263
12381
|
blobSequenceNumber
|
12264
12382
|
],
|
12265
12383
|
isXML: true,
|
12266
|
-
serializer: xmlSerializer$
|
12384
|
+
serializer: xmlSerializer$2
|
12267
12385
|
};
|
12268
12386
|
const uploadPagesOperationSpec = {
|
12269
12387
|
path: "/{containerName}/{blob}",
|
@@ -12305,7 +12423,7 @@ const uploadPagesOperationSpec = {
|
|
12305
12423
|
ifSequenceNumberEqualTo
|
12306
12424
|
],
|
12307
12425
|
mediaType: "binary",
|
12308
|
-
serializer
|
12426
|
+
serializer: serializer$2
|
12309
12427
|
};
|
12310
12428
|
const clearPagesOperationSpec = {
|
12311
12429
|
path: "/{containerName}/{blob}",
|
@@ -12343,7 +12461,7 @@ const clearPagesOperationSpec = {
|
|
12343
12461
|
pageWrite1
|
12344
12462
|
],
|
12345
12463
|
isXML: true,
|
12346
|
-
serializer: xmlSerializer$
|
12464
|
+
serializer: xmlSerializer$2
|
12347
12465
|
};
|
12348
12466
|
const uploadPagesFromURLOperationSpec = {
|
12349
12467
|
path: "/{containerName}/{blob}",
|
@@ -12390,7 +12508,7 @@ const uploadPagesFromURLOperationSpec = {
|
|
12390
12508
|
range1
|
12391
12509
|
],
|
12392
12510
|
isXML: true,
|
12393
|
-
serializer: xmlSerializer$
|
12511
|
+
serializer: xmlSerializer$2
|
12394
12512
|
};
|
12395
12513
|
const getPageRangesOperationSpec = {
|
12396
12514
|
path: "/{containerName}/{blob}",
|
@@ -12424,7 +12542,7 @@ const getPageRangesOperationSpec = {
|
|
12424
12542
|
ifTags
|
12425
12543
|
],
|
12426
12544
|
isXML: true,
|
12427
|
-
serializer: xmlSerializer$
|
12545
|
+
serializer: xmlSerializer$2
|
12428
12546
|
};
|
12429
12547
|
const getPageRangesDiffOperationSpec = {
|
12430
12548
|
path: "/{containerName}/{blob}",
|
@@ -12460,7 +12578,7 @@ const getPageRangesDiffOperationSpec = {
|
|
12460
12578
|
prevSnapshotUrl
|
12461
12579
|
],
|
12462
12580
|
isXML: true,
|
12463
|
-
serializer: xmlSerializer$
|
12581
|
+
serializer: xmlSerializer$2
|
12464
12582
|
};
|
12465
12583
|
const resizeOperationSpec = {
|
12466
12584
|
path: "/{containerName}/{blob}",
|
@@ -12493,7 +12611,7 @@ const resizeOperationSpec = {
|
|
12493
12611
|
blobContentLength
|
12494
12612
|
],
|
12495
12613
|
isXML: true,
|
12496
|
-
serializer: xmlSerializer$
|
12614
|
+
serializer: xmlSerializer$2
|
12497
12615
|
};
|
12498
12616
|
const updateSequenceNumberOperationSpec = {
|
12499
12617
|
path: "/{containerName}/{blob}",
|
@@ -12523,7 +12641,7 @@ const updateSequenceNumberOperationSpec = {
|
|
12523
12641
|
sequenceNumberAction
|
12524
12642
|
],
|
12525
12643
|
isXML: true,
|
12526
|
-
serializer: xmlSerializer$
|
12644
|
+
serializer: xmlSerializer$2
|
12527
12645
|
};
|
12528
12646
|
const copyIncrementalOperationSpec = {
|
12529
12647
|
path: "/{containerName}/{blob}",
|
@@ -12551,7 +12669,7 @@ const copyIncrementalOperationSpec = {
|
|
12551
12669
|
copySource
|
12552
12670
|
],
|
12553
12671
|
isXML: true,
|
12554
|
-
serializer: xmlSerializer$
|
12672
|
+
serializer: xmlSerializer$2
|
12555
12673
|
};
|
12556
12674
|
|
12557
12675
|
/*
|
@@ -12578,9 +12696,9 @@ class AppendBlob {
|
|
12578
12696
|
create(contentLength, options) {
|
12579
12697
|
const operationArguments = {
|
12580
12698
|
contentLength,
|
12581
|
-
options:
|
12699
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12582
12700
|
};
|
12583
|
-
return this.client.sendOperationRequest(operationArguments, createOperationSpec
|
12701
|
+
return this.client.sendOperationRequest(operationArguments, createOperationSpec);
|
12584
12702
|
}
|
12585
12703
|
/**
|
12586
12704
|
* The Append Block operation commits a new block of data to the end of an existing append blob. The
|
@@ -12594,7 +12712,7 @@ class AppendBlob {
|
|
12594
12712
|
const operationArguments = {
|
12595
12713
|
contentLength,
|
12596
12714
|
body,
|
12597
|
-
options:
|
12715
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12598
12716
|
};
|
12599
12717
|
return this.client.sendOperationRequest(operationArguments, appendBlockOperationSpec);
|
12600
12718
|
}
|
@@ -12611,7 +12729,7 @@ class AppendBlob {
|
|
12611
12729
|
const operationArguments = {
|
12612
12730
|
sourceUrl,
|
12613
12731
|
contentLength,
|
12614
|
-
options:
|
12732
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12615
12733
|
};
|
12616
12734
|
return this.client.sendOperationRequest(operationArguments, appendBlockFromUrlOperationSpec);
|
12617
12735
|
}
|
@@ -12622,15 +12740,15 @@ class AppendBlob {
|
|
12622
12740
|
*/
|
12623
12741
|
seal(options) {
|
12624
12742
|
const operationArguments = {
|
12625
|
-
options:
|
12743
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12626
12744
|
};
|
12627
12745
|
return this.client.sendOperationRequest(operationArguments, sealOperationSpec);
|
12628
12746
|
}
|
12629
12747
|
}
|
12630
12748
|
// Operation Specifications
|
12631
|
-
const xmlSerializer$
|
12632
|
-
const serializer$1 = new
|
12633
|
-
const createOperationSpec
|
12749
|
+
const xmlSerializer$1 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
12750
|
+
const serializer$1 = new coreHttp__namespace.Serializer(Mappers, /* isXml */ false);
|
12751
|
+
const createOperationSpec = {
|
12634
12752
|
path: "/{containerName}/{blob}",
|
12635
12753
|
httpMethod: "PUT",
|
12636
12754
|
responses: {
|
@@ -12673,7 +12791,7 @@ const createOperationSpec$2 = {
|
|
12673
12791
|
blobType1
|
12674
12792
|
],
|
12675
12793
|
isXML: true,
|
12676
|
-
serializer: xmlSerializer$
|
12794
|
+
serializer: xmlSerializer$1
|
12677
12795
|
};
|
12678
12796
|
const appendBlockOperationSpec = {
|
12679
12797
|
path: "/{containerName}/{blob}",
|
@@ -12757,7 +12875,7 @@ const appendBlockFromUrlOperationSpec = {
|
|
12757
12875
|
sourceRange1
|
12758
12876
|
],
|
12759
12877
|
isXML: true,
|
12760
|
-
serializer: xmlSerializer$
|
12878
|
+
serializer: xmlSerializer$1
|
12761
12879
|
};
|
12762
12880
|
const sealOperationSpec = {
|
12763
12881
|
path: "/{containerName}/{blob}",
|
@@ -12785,7 +12903,7 @@ const sealOperationSpec = {
|
|
12785
12903
|
appendPosition
|
12786
12904
|
],
|
12787
12905
|
isXML: true,
|
12788
|
-
serializer: xmlSerializer$
|
12906
|
+
serializer: xmlSerializer$1
|
12789
12907
|
};
|
12790
12908
|
|
12791
12909
|
/*
|
@@ -12817,7 +12935,7 @@ class BlockBlob {
|
|
12817
12935
|
const operationArguments = {
|
12818
12936
|
contentLength,
|
12819
12937
|
body,
|
12820
|
-
options:
|
12938
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12821
12939
|
};
|
12822
12940
|
return this.client.sendOperationRequest(operationArguments, uploadOperationSpec);
|
12823
12941
|
}
|
@@ -12838,7 +12956,7 @@ class BlockBlob {
|
|
12838
12956
|
const operationArguments = {
|
12839
12957
|
contentLength,
|
12840
12958
|
copySource,
|
12841
|
-
options:
|
12959
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12842
12960
|
};
|
12843
12961
|
return this.client.sendOperationRequest(operationArguments, putBlobFromUrlOperationSpec);
|
12844
12962
|
}
|
@@ -12856,7 +12974,7 @@ class BlockBlob {
|
|
12856
12974
|
blockId,
|
12857
12975
|
contentLength,
|
12858
12976
|
body,
|
12859
|
-
options:
|
12977
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12860
12978
|
};
|
12861
12979
|
return this.client.sendOperationRequest(operationArguments, stageBlockOperationSpec);
|
12862
12980
|
}
|
@@ -12875,7 +12993,7 @@ class BlockBlob {
|
|
12875
12993
|
blockId,
|
12876
12994
|
contentLength,
|
12877
12995
|
sourceUrl,
|
12878
|
-
options:
|
12996
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12879
12997
|
};
|
12880
12998
|
return this.client.sendOperationRequest(operationArguments, stageBlockFromURLOperationSpec);
|
12881
12999
|
}
|
@@ -12893,7 +13011,7 @@ class BlockBlob {
|
|
12893
13011
|
commitBlockList(blocks, options) {
|
12894
13012
|
const operationArguments = {
|
12895
13013
|
blocks,
|
12896
|
-
options:
|
13014
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12897
13015
|
};
|
12898
13016
|
return this.client.sendOperationRequest(operationArguments, commitBlockListOperationSpec);
|
12899
13017
|
}
|
@@ -12907,14 +13025,14 @@ class BlockBlob {
|
|
12907
13025
|
getBlockList(listType, options) {
|
12908
13026
|
const operationArguments = {
|
12909
13027
|
listType,
|
12910
|
-
options:
|
13028
|
+
options: coreHttp__namespace.operationOptionsToRequestOptionsBase(options || {})
|
12911
13029
|
};
|
12912
13030
|
return this.client.sendOperationRequest(operationArguments, getBlockListOperationSpec);
|
12913
13031
|
}
|
12914
13032
|
}
|
12915
13033
|
// Operation Specifications
|
12916
|
-
const xmlSerializer
|
12917
|
-
const serializer
|
13034
|
+
const xmlSerializer = new coreHttp__namespace.Serializer(Mappers, /* isXml */ true);
|
13035
|
+
const serializer = new coreHttp__namespace.Serializer(Mappers, /* isXml */ false);
|
12918
13036
|
const uploadOperationSpec = {
|
12919
13037
|
path: "/{containerName}/{blob}",
|
12920
13038
|
httpMethod: "PUT",
|
@@ -12962,7 +13080,7 @@ const uploadOperationSpec = {
|
|
12962
13080
|
blobType2
|
12963
13081
|
],
|
12964
13082
|
mediaType: "binary",
|
12965
|
-
serializer
|
13083
|
+
serializer
|
12966
13084
|
};
|
12967
13085
|
const putBlobFromUrlOperationSpec = {
|
12968
13086
|
path: "/{containerName}/{blob}",
|
@@ -13015,7 +13133,7 @@ const putBlobFromUrlOperationSpec = {
|
|
13015
13133
|
copySourceBlobProperties
|
13016
13134
|
],
|
13017
13135
|
isXML: true,
|
13018
|
-
serializer: xmlSerializer
|
13136
|
+
serializer: xmlSerializer
|
13019
13137
|
};
|
13020
13138
|
const stageBlockOperationSpec = {
|
13021
13139
|
path: "/{containerName}/{blob}",
|
@@ -13051,7 +13169,7 @@ const stageBlockOperationSpec = {
|
|
13051
13169
|
accept2
|
13052
13170
|
],
|
13053
13171
|
mediaType: "binary",
|
13054
|
-
serializer
|
13172
|
+
serializer
|
13055
13173
|
};
|
13056
13174
|
const stageBlockFromURLOperationSpec = {
|
13057
13175
|
path: "/{containerName}/{blob}",
|
@@ -13092,7 +13210,7 @@ const stageBlockFromURLOperationSpec = {
|
|
13092
13210
|
sourceRange1
|
13093
13211
|
],
|
13094
13212
|
isXML: true,
|
13095
|
-
serializer: xmlSerializer
|
13213
|
+
serializer: xmlSerializer
|
13096
13214
|
};
|
13097
13215
|
const commitBlockListOperationSpec = {
|
13098
13216
|
path: "/{containerName}/{blob}",
|
@@ -13142,7 +13260,7 @@ const commitBlockListOperationSpec = {
|
|
13142
13260
|
isXML: true,
|
13143
13261
|
contentType: "application/xml; charset=utf-8",
|
13144
13262
|
mediaType: "xml",
|
13145
|
-
serializer: xmlSerializer
|
13263
|
+
serializer: xmlSerializer
|
13146
13264
|
};
|
13147
13265
|
const getBlockListOperationSpec = {
|
13148
13266
|
path: "/{containerName}/{blob}",
|
@@ -13172,7 +13290,7 @@ const getBlockListOperationSpec = {
|
|
13172
13290
|
ifTags
|
13173
13291
|
],
|
13174
13292
|
isXML: true,
|
13175
|
-
serializer: xmlSerializer
|
13293
|
+
serializer: xmlSerializer
|
13176
13294
|
};
|
13177
13295
|
|
13178
13296
|
// Copyright (c) Microsoft Corporation.
|
@@ -13183,8 +13301,8 @@ const logger = logger$1.createClientLogger("storage-blob");
|
|
13183
13301
|
|
13184
13302
|
// Copyright (c) Microsoft Corporation.
|
13185
13303
|
// Licensed under the MIT license.
|
13186
|
-
const SDK_VERSION = "12.9.0
|
13187
|
-
const SERVICE_VERSION = "2021-
|
13304
|
+
const SDK_VERSION = "12.9.0";
|
13305
|
+
const SERVICE_VERSION = "2021-04-10";
|
13188
13306
|
const BLOCK_BLOB_MAX_UPLOAD_BLOB_BYTES = 256 * 1024 * 1024; // 256MB
|
13189
13307
|
const BLOCK_BLOB_MAX_STAGE_BLOCK_BYTES = 4000 * 1024 * 1024; // 4000MB
|
13190
13308
|
const BLOCK_BLOB_MAX_BLOCKS = 50000;
|
@@ -13201,15 +13319,15 @@ const URLConstants = {
|
|
13201
13319
|
SIGNATURE: "sig",
|
13202
13320
|
SNAPSHOT: "snapshot",
|
13203
13321
|
VERSIONID: "versionid",
|
13204
|
-
TIMEOUT: "timeout"
|
13205
|
-
}
|
13322
|
+
TIMEOUT: "timeout",
|
13323
|
+
},
|
13206
13324
|
};
|
13207
13325
|
const HTTPURLConnection = {
|
13208
13326
|
HTTP_ACCEPTED: 202,
|
13209
13327
|
HTTP_CONFLICT: 409,
|
13210
13328
|
HTTP_NOT_FOUND: 404,
|
13211
13329
|
HTTP_PRECON_FAILED: 412,
|
13212
|
-
HTTP_RANGE_NOT_SATISFIABLE: 416
|
13330
|
+
HTTP_RANGE_NOT_SATISFIABLE: 416,
|
13213
13331
|
};
|
13214
13332
|
const HeaderConstants = {
|
13215
13333
|
AUTHORIZATION: "Authorization",
|
@@ -13234,7 +13352,7 @@ const HeaderConstants = {
|
|
13234
13352
|
X_MS_COPY_SOURCE: "x-ms-copy-source",
|
13235
13353
|
X_MS_DATE: "x-ms-date",
|
13236
13354
|
X_MS_ERROR_CODE: "x-ms-error-code",
|
13237
|
-
X_MS_VERSION: "x-ms-version"
|
13355
|
+
X_MS_VERSION: "x-ms-version",
|
13238
13356
|
};
|
13239
13357
|
const ETagNone = "";
|
13240
13358
|
const ETagAny = "*";
|
@@ -13339,7 +13457,7 @@ const StorageBlobLoggingAllowedHeaderNames = [
|
|
13339
13457
|
"x-ms-tag-count",
|
13340
13458
|
"x-ms-encryption-key-sha256",
|
13341
13459
|
"x-ms-if-tags",
|
13342
|
-
"x-ms-source-if-tags"
|
13460
|
+
"x-ms-source-if-tags",
|
13343
13461
|
];
|
13344
13462
|
const StorageBlobLoggingAllowedQueryParameters = [
|
13345
13463
|
"comp",
|
@@ -13374,8 +13492,9 @@ const StorageBlobLoggingAllowedQueryParameters = [
|
|
13374
13492
|
"skt",
|
13375
13493
|
"sktid",
|
13376
13494
|
"skv",
|
13377
|
-
"snapshot"
|
13495
|
+
"snapshot",
|
13378
13496
|
];
|
13497
|
+
const BlobUsesCustomerSpecifiedEncryptionMsg = "BlobUsesCustomerSpecifiedEncryption";
|
13379
13498
|
|
13380
13499
|
// Copyright (c) Microsoft Corporation.
|
13381
13500
|
/**
|
@@ -13515,7 +13634,7 @@ function extractConnectionStringParts(connectionString) {
|
|
13515
13634
|
url: blobEndpoint,
|
13516
13635
|
accountName,
|
13517
13636
|
accountKey,
|
13518
|
-
proxyUri
|
13637
|
+
proxyUri,
|
13519
13638
|
};
|
13520
13639
|
}
|
13521
13640
|
else {
|
@@ -13847,14 +13966,14 @@ function toBlobTags(tags) {
|
|
13847
13966
|
return undefined;
|
13848
13967
|
}
|
13849
13968
|
const res = {
|
13850
|
-
blobTagSet: []
|
13969
|
+
blobTagSet: [],
|
13851
13970
|
};
|
13852
13971
|
for (const key in tags) {
|
13853
13972
|
if (Object.prototype.hasOwnProperty.call(tags, key)) {
|
13854
13973
|
const value = tags[key];
|
13855
13974
|
res.blobTagSet.push({
|
13856
13975
|
key,
|
13857
|
-
value
|
13976
|
+
value,
|
13858
13977
|
});
|
13859
13978
|
}
|
13860
13979
|
}
|
@@ -13894,33 +14013,33 @@ function toQuerySerialization(textConfiguration) {
|
|
13894
14013
|
fieldQuote: textConfiguration.fieldQuote || "",
|
13895
14014
|
recordSeparator: textConfiguration.recordSeparator,
|
13896
14015
|
escapeChar: textConfiguration.escapeCharacter || "",
|
13897
|
-
headersPresent: textConfiguration.hasHeaders || false
|
13898
|
-
}
|
13899
|
-
}
|
14016
|
+
headersPresent: textConfiguration.hasHeaders || false,
|
14017
|
+
},
|
14018
|
+
},
|
13900
14019
|
};
|
13901
14020
|
case "json":
|
13902
14021
|
return {
|
13903
14022
|
format: {
|
13904
14023
|
type: "json",
|
13905
14024
|
jsonTextConfiguration: {
|
13906
|
-
recordSeparator: textConfiguration.recordSeparator
|
13907
|
-
}
|
13908
|
-
}
|
14025
|
+
recordSeparator: textConfiguration.recordSeparator,
|
14026
|
+
},
|
14027
|
+
},
|
13909
14028
|
};
|
13910
14029
|
case "arrow":
|
13911
14030
|
return {
|
13912
14031
|
format: {
|
13913
14032
|
type: "arrow",
|
13914
14033
|
arrowConfiguration: {
|
13915
|
-
schema: textConfiguration.schema
|
13916
|
-
}
|
13917
|
-
}
|
14034
|
+
schema: textConfiguration.schema,
|
14035
|
+
},
|
14036
|
+
},
|
13918
14037
|
};
|
13919
14038
|
case "parquet":
|
13920
14039
|
return {
|
13921
14040
|
format: {
|
13922
|
-
type: "parquet"
|
13923
|
-
}
|
14041
|
+
type: "parquet",
|
14042
|
+
},
|
13924
14043
|
};
|
13925
14044
|
default:
|
13926
14045
|
throw Error("Invalid BlobQueryTextConfiguration.");
|
@@ -13944,7 +14063,7 @@ function parseObjectReplicationRecord(objectReplicationRecord) {
|
|
13944
14063
|
}
|
13945
14064
|
const rule = {
|
13946
14065
|
ruleId: ids[1],
|
13947
|
-
replicationStatus: objectReplicationRecord[key]
|
14066
|
+
replicationStatus: objectReplicationRecord[key],
|
13948
14067
|
};
|
13949
14068
|
const policyIndex = orProperties.findIndex((policy) => policy.policyId === ids[0]);
|
13950
14069
|
if (policyIndex > -1) {
|
@@ -13953,7 +14072,7 @@ function parseObjectReplicationRecord(objectReplicationRecord) {
|
|
13953
14072
|
else {
|
13954
14073
|
orProperties.push({
|
13955
14074
|
policyId: ids[0],
|
13956
|
-
rules: [rule]
|
14075
|
+
rules: [rule],
|
13957
14076
|
});
|
13958
14077
|
}
|
13959
14078
|
}
|
@@ -13985,7 +14104,7 @@ function ConvertInternalResponseOfListBlobFlat(internalResponse) {
|
|
13985
14104
|
blobItems: internalResponse.segment.blobItems.map((blobItemInteral) => {
|
13986
14105
|
const blobItem = Object.assign(Object.assign({}, blobItemInteral), { name: BlobNameToString(blobItemInteral.name) });
|
13987
14106
|
return blobItem;
|
13988
|
-
})
|
14107
|
+
}),
|
13989
14108
|
} });
|
13990
14109
|
}
|
13991
14110
|
function ConvertInternalResponseOfListBlobHierarchy(internalResponse) {
|
@@ -13993,20 +14112,28 @@ function ConvertInternalResponseOfListBlobHierarchy(internalResponse) {
|
|
13993
14112
|
return Object.assign(Object.assign({}, internalResponse), { segment: {
|
13994
14113
|
blobPrefixes: (_a = internalResponse.segment.blobPrefixes) === null || _a === void 0 ? void 0 : _a.map((blobPrefixInternal) => {
|
13995
14114
|
const blobPrefix = {
|
13996
|
-
name: BlobNameToString(blobPrefixInternal.name)
|
14115
|
+
name: BlobNameToString(blobPrefixInternal.name),
|
13997
14116
|
};
|
13998
14117
|
return blobPrefix;
|
13999
14118
|
}),
|
14000
14119
|
blobItems: internalResponse.segment.blobItems.map((blobItemInteral) => {
|
14001
14120
|
const blobItem = Object.assign(Object.assign({}, blobItemInteral), { name: BlobNameToString(blobItemInteral.name) });
|
14002
14121
|
return blobItem;
|
14003
|
-
})
|
14122
|
+
}),
|
14004
14123
|
} });
|
14005
14124
|
}
|
14006
14125
|
function decodeBase64String(value) {
|
14007
|
-
{
|
14126
|
+
if (coreHttp.isNode) {
|
14008
14127
|
return Buffer.from(value, "base64");
|
14009
14128
|
}
|
14129
|
+
else {
|
14130
|
+
const byteString = atob(value);
|
14131
|
+
const arr = new Uint8Array(byteString.length);
|
14132
|
+
for (let i = 0; i < byteString.length; i++) {
|
14133
|
+
arr[i] = byteString.charCodeAt(i);
|
14134
|
+
}
|
14135
|
+
return arr;
|
14136
|
+
}
|
14010
14137
|
}
|
14011
14138
|
function ParseBoolean(content) {
|
14012
14139
|
if (content === undefined)
|
@@ -14021,13 +14148,13 @@ function ParseBlobName(blobNameInXML) {
|
|
14021
14148
|
if (blobNameInXML["$"] !== undefined && blobNameInXML["#"] !== undefined) {
|
14022
14149
|
return {
|
14023
14150
|
encoded: ParseBoolean(blobNameInXML["$"]["Encoded"]),
|
14024
|
-
content: blobNameInXML["#"]
|
14151
|
+
content: blobNameInXML["#"],
|
14025
14152
|
};
|
14026
14153
|
}
|
14027
14154
|
else {
|
14028
14155
|
return {
|
14029
14156
|
encoded: false,
|
14030
|
-
content: blobNameInXML
|
14157
|
+
content: blobNameInXML,
|
14031
14158
|
};
|
14032
14159
|
}
|
14033
14160
|
}
|
@@ -14093,7 +14220,7 @@ function ParseBlobItem(blobInXML) {
|
|
14093
14220
|
? undefined
|
14094
14221
|
: new Date(blobPropertiesInXML["ImmutabilityPolicyUntilDate"]),
|
14095
14222
|
immutabilityPolicyMode: blobPropertiesInXML["ImmutabilityPolicyMode"],
|
14096
|
-
legalHold: ParseBoolean(blobPropertiesInXML["LegalHold"])
|
14223
|
+
legalHold: ParseBoolean(blobPropertiesInXML["LegalHold"]),
|
14097
14224
|
};
|
14098
14225
|
return {
|
14099
14226
|
name: ParseBlobName(blobInXML["Name"]),
|
@@ -14105,18 +14232,18 @@ function ParseBlobItem(blobInXML) {
|
|
14105
14232
|
metadata: blobInXML["Metadata"],
|
14106
14233
|
blobTags: ParseBlobTags(blobInXML["Tags"]),
|
14107
14234
|
objectReplicationMetadata: blobInXML["OrMetadata"],
|
14108
|
-
hasVersionsOnly: ParseBoolean(blobInXML["HasVersionsOnly"])
|
14235
|
+
hasVersionsOnly: ParseBoolean(blobInXML["HasVersionsOnly"]),
|
14109
14236
|
};
|
14110
14237
|
}
|
14111
14238
|
function ParseBlobPrefix(blobPrefixInXML) {
|
14112
14239
|
return {
|
14113
|
-
name: ParseBlobName(blobPrefixInXML["Name"])
|
14240
|
+
name: ParseBlobName(blobPrefixInXML["Name"]),
|
14114
14241
|
};
|
14115
14242
|
}
|
14116
14243
|
function ParseBlobTag(blobTagInXML) {
|
14117
14244
|
return {
|
14118
14245
|
key: blobTagInXML["Key"],
|
14119
|
-
value: blobTagInXML["Value"]
|
14246
|
+
value: blobTagInXML["Value"],
|
14120
14247
|
};
|
14121
14248
|
}
|
14122
14249
|
function ParseBlobTags(blobTagsInXML) {
|
@@ -14190,9 +14317,16 @@ class StorageBrowserPolicy extends coreHttp.BaseRequestPolicy {
|
|
14190
14317
|
* @param request -
|
14191
14318
|
*/
|
14192
14319
|
async sendRequest(request) {
|
14193
|
-
{
|
14320
|
+
if (coreHttp.isNode) {
|
14194
14321
|
return this._nextPolicy.sendRequest(request);
|
14195
14322
|
}
|
14323
|
+
if (request.method.toUpperCase() === "GET" || request.method.toUpperCase() === "HEAD") {
|
14324
|
+
request.url = setURLParameter(request.url, URLConstants.Parameters.FORCE_BROWSER_NO_CACHE, new Date().getTime().toString());
|
14325
|
+
}
|
14326
|
+
request.headers.remove(HeaderConstants.COOKIE);
|
14327
|
+
// According to XHR standards, content-length should be fully controlled by browsers
|
14328
|
+
request.headers.remove(HeaderConstants.CONTENT_LENGTH);
|
14329
|
+
return this._nextPolicy.sendRequest(request);
|
14196
14330
|
}
|
14197
14331
|
}
|
14198
14332
|
|
@@ -14213,6 +14347,10 @@ class StorageBrowserPolicyFactory {
|
|
14213
14347
|
}
|
14214
14348
|
|
14215
14349
|
// Copyright (c) Microsoft Corporation.
|
14350
|
+
/**
|
14351
|
+
* RetryPolicy types.
|
14352
|
+
*/
|
14353
|
+
exports.StorageRetryPolicyType = void 0;
|
14216
14354
|
(function (StorageRetryPolicyType) {
|
14217
14355
|
/**
|
14218
14356
|
* Exponential retry. Retry time delay grows exponentially.
|
@@ -14230,7 +14368,7 @@ const DEFAULT_RETRY_OPTIONS = {
|
|
14230
14368
|
retryDelayInMs: 4 * 1000,
|
14231
14369
|
retryPolicyType: exports.StorageRetryPolicyType.EXPONENTIAL,
|
14232
14370
|
secondaryHost: "",
|
14233
|
-
tryTimeoutInMs: undefined // Use server side default timeout strategy
|
14371
|
+
tryTimeoutInMs: undefined, // Use server side default timeout strategy
|
14234
14372
|
};
|
14235
14373
|
const RETRY_ABORT_ERROR = new abortController.AbortError("The operation was aborted.");
|
14236
14374
|
/**
|
@@ -14267,7 +14405,7 @@ class StorageRetryPolicy extends coreHttp.BaseRequestPolicy {
|
|
14267
14405
|
: DEFAULT_RETRY_OPTIONS.maxRetryDelayInMs,
|
14268
14406
|
secondaryHost: retryOptions.secondaryHost
|
14269
14407
|
? retryOptions.secondaryHost
|
14270
|
-
: DEFAULT_RETRY_OPTIONS.secondaryHost
|
14408
|
+
: DEFAULT_RETRY_OPTIONS.secondaryHost,
|
14271
14409
|
};
|
14272
14410
|
}
|
14273
14411
|
/**
|
@@ -14344,7 +14482,7 @@ class StorageRetryPolicy extends coreHttp.BaseRequestPolicy {
|
|
14344
14482
|
"ENOTFOUND",
|
14345
14483
|
"TIMEOUT",
|
14346
14484
|
"EPIPE",
|
14347
|
-
"REQUEST_SEND_ERROR" // For default xhr based http client provided in ms-rest-js
|
14485
|
+
"REQUEST_SEND_ERROR", // For default xhr based http client provided in ms-rest-js
|
14348
14486
|
];
|
14349
14487
|
if (err) {
|
14350
14488
|
for (const retriableError of retriableErrors) {
|
@@ -14530,7 +14668,7 @@ class TelemetryPolicy extends coreHttp.BaseRequestPolicy {
|
|
14530
14668
|
* @param request -
|
14531
14669
|
*/
|
14532
14670
|
async sendRequest(request) {
|
14533
|
-
{
|
14671
|
+
if (coreHttp.isNode) {
|
14534
14672
|
if (!request.headers) {
|
14535
14673
|
request.headers = new coreHttp.HttpHeaders();
|
14536
14674
|
}
|
@@ -14553,7 +14691,7 @@ class TelemetryPolicyFactory {
|
|
14553
14691
|
*/
|
14554
14692
|
constructor(telemetry) {
|
14555
14693
|
const userAgentInfo = [];
|
14556
|
-
{
|
14694
|
+
if (coreHttp.isNode) {
|
14557
14695
|
if (telemetry) {
|
14558
14696
|
const telemetryString = telemetry.userAgentPrefix || "";
|
14559
14697
|
if (telemetryString.length > 0 && userAgentInfo.indexOf(telemetryString) === -1) {
|
@@ -14566,7 +14704,7 @@ class TelemetryPolicyFactory {
|
|
14566
14704
|
userAgentInfo.push(libInfo);
|
14567
14705
|
}
|
14568
14706
|
// e.g. (NODE-VERSION 4.9.1; Windows_NT 10.0.16299)
|
14569
|
-
const runtimeInfo = `(NODE-VERSION ${process.version}; ${
|
14707
|
+
const runtimeInfo = `(NODE-VERSION ${process.version}; ${os__namespace.type()} ${os__namespace.release()})`;
|
14570
14708
|
if (userAgentInfo.indexOf(runtimeInfo) === -1) {
|
14571
14709
|
userAgentInfo.push(runtimeInfo);
|
14572
14710
|
}
|
@@ -14590,6 +14728,247 @@ function getCachedDefaultHttpClient() {
|
|
14590
14728
|
return _defaultHttpClient;
|
14591
14729
|
}
|
14592
14730
|
|
14731
|
+
// Copyright (c) Microsoft Corporation.
|
14732
|
+
/**
|
14733
|
+
* A set of constants used internally when processing requests.
|
14734
|
+
*/
|
14735
|
+
const Constants = {
|
14736
|
+
DefaultScope: "/.default",
|
14737
|
+
/**
|
14738
|
+
* Defines constants for use with HTTP headers.
|
14739
|
+
*/
|
14740
|
+
HeaderConstants: {
|
14741
|
+
/**
|
14742
|
+
* The Authorization header.
|
14743
|
+
*/
|
14744
|
+
AUTHORIZATION: "authorization",
|
14745
|
+
},
|
14746
|
+
};
|
14747
|
+
// Default options for the cycler if none are provided
|
14748
|
+
const DEFAULT_CYCLER_OPTIONS = {
|
14749
|
+
forcedRefreshWindowInMs: 1000,
|
14750
|
+
retryIntervalInMs: 3000,
|
14751
|
+
refreshWindowInMs: 1000 * 60 * 2, // Start refreshing 2m before expiry
|
14752
|
+
};
|
14753
|
+
/**
|
14754
|
+
* Converts an an unreliable access token getter (which may resolve with null)
|
14755
|
+
* into an AccessTokenGetter by retrying the unreliable getter in a regular
|
14756
|
+
* interval.
|
14757
|
+
*
|
14758
|
+
* @param getAccessToken - a function that produces a promise of an access
|
14759
|
+
* token that may fail by returning null
|
14760
|
+
* @param retryIntervalInMs - the time (in milliseconds) to wait between retry
|
14761
|
+
* attempts
|
14762
|
+
* @param timeoutInMs - the timestamp after which the refresh attempt will fail,
|
14763
|
+
* throwing an exception
|
14764
|
+
* @returns - a promise that, if it resolves, will resolve with an access token
|
14765
|
+
*/
|
14766
|
+
async function beginRefresh(getAccessToken, retryIntervalInMs, timeoutInMs) {
|
14767
|
+
// This wrapper handles exceptions gracefully as long as we haven't exceeded
|
14768
|
+
// the timeout.
|
14769
|
+
async function tryGetAccessToken() {
|
14770
|
+
if (Date.now() < timeoutInMs) {
|
14771
|
+
try {
|
14772
|
+
return await getAccessToken();
|
14773
|
+
}
|
14774
|
+
catch (_a) {
|
14775
|
+
return null;
|
14776
|
+
}
|
14777
|
+
}
|
14778
|
+
else {
|
14779
|
+
const finalToken = await getAccessToken();
|
14780
|
+
// Timeout is up, so throw if it's still null
|
14781
|
+
if (finalToken === null) {
|
14782
|
+
throw new Error("Failed to refresh access token.");
|
14783
|
+
}
|
14784
|
+
return finalToken;
|
14785
|
+
}
|
14786
|
+
}
|
14787
|
+
let token = await tryGetAccessToken();
|
14788
|
+
while (token === null) {
|
14789
|
+
await coreHttp.delay(retryIntervalInMs);
|
14790
|
+
token = await tryGetAccessToken();
|
14791
|
+
}
|
14792
|
+
return token;
|
14793
|
+
}
|
14794
|
+
/**
|
14795
|
+
* Creates a token cycler from a credential, scopes, and optional settings.
|
14796
|
+
*
|
14797
|
+
* A token cycler represents a way to reliably retrieve a valid access token
|
14798
|
+
* from a TokenCredential. It will handle initializing the token, refreshing it
|
14799
|
+
* when it nears expiration, and synchronizes refresh attempts to avoid
|
14800
|
+
* concurrency hazards.
|
14801
|
+
*
|
14802
|
+
* @param credential - the underlying TokenCredential that provides the access
|
14803
|
+
* token
|
14804
|
+
* @param scopes - the scopes to request authorization for
|
14805
|
+
* @param tokenCyclerOptions - optionally override default settings for the cycler
|
14806
|
+
*
|
14807
|
+
* @returns - a function that reliably produces a valid access token
|
14808
|
+
*/
|
14809
|
+
function createTokenCycler(credential, scopes, tokenCyclerOptions) {
|
14810
|
+
let refreshWorker = null;
|
14811
|
+
let token = null;
|
14812
|
+
const options = Object.assign(Object.assign({}, DEFAULT_CYCLER_OPTIONS), tokenCyclerOptions);
|
14813
|
+
/**
|
14814
|
+
* This little holder defines several predicates that we use to construct
|
14815
|
+
* the rules of refreshing the token.
|
14816
|
+
*/
|
14817
|
+
const cycler = {
|
14818
|
+
/**
|
14819
|
+
* Produces true if a refresh job is currently in progress.
|
14820
|
+
*/
|
14821
|
+
get isRefreshing() {
|
14822
|
+
return refreshWorker !== null;
|
14823
|
+
},
|
14824
|
+
/**
|
14825
|
+
* Produces true if the cycler SHOULD refresh (we are within the refresh
|
14826
|
+
* window and not already refreshing)
|
14827
|
+
*/
|
14828
|
+
get shouldRefresh() {
|
14829
|
+
var _a;
|
14830
|
+
return (!cycler.isRefreshing &&
|
14831
|
+
((_a = token === null || token === void 0 ? void 0 : token.expiresOnTimestamp) !== null && _a !== void 0 ? _a : 0) - options.refreshWindowInMs < Date.now());
|
14832
|
+
},
|
14833
|
+
/**
|
14834
|
+
* Produces true if the cycler MUST refresh (null or nearly-expired
|
14835
|
+
* token).
|
14836
|
+
*/
|
14837
|
+
get mustRefresh() {
|
14838
|
+
return (token === null || token.expiresOnTimestamp - options.forcedRefreshWindowInMs < Date.now());
|
14839
|
+
},
|
14840
|
+
};
|
14841
|
+
/**
|
14842
|
+
* Starts a refresh job or returns the existing job if one is already
|
14843
|
+
* running.
|
14844
|
+
*/
|
14845
|
+
function refresh(getTokenOptions) {
|
14846
|
+
var _a;
|
14847
|
+
if (!cycler.isRefreshing) {
|
14848
|
+
// We bind `scopes` here to avoid passing it around a lot
|
14849
|
+
const tryGetAccessToken = () => credential.getToken(scopes, getTokenOptions);
|
14850
|
+
// Take advantage of promise chaining to insert an assignment to `token`
|
14851
|
+
// before the refresh can be considered done.
|
14852
|
+
refreshWorker = beginRefresh(tryGetAccessToken, options.retryIntervalInMs,
|
14853
|
+
// If we don't have a token, then we should timeout immediately
|
14854
|
+
(_a = token === null || token === void 0 ? void 0 : token.expiresOnTimestamp) !== null && _a !== void 0 ? _a : Date.now())
|
14855
|
+
.then((_token) => {
|
14856
|
+
refreshWorker = null;
|
14857
|
+
token = _token;
|
14858
|
+
return token;
|
14859
|
+
})
|
14860
|
+
.catch((reason) => {
|
14861
|
+
// We also should reset the refresher if we enter a failed state. All
|
14862
|
+
// existing awaiters will throw, but subsequent requests will start a
|
14863
|
+
// new retry chain.
|
14864
|
+
refreshWorker = null;
|
14865
|
+
token = null;
|
14866
|
+
throw reason;
|
14867
|
+
});
|
14868
|
+
}
|
14869
|
+
return refreshWorker;
|
14870
|
+
}
|
14871
|
+
return async (tokenOptions) => {
|
14872
|
+
//
|
14873
|
+
// Simple rules:
|
14874
|
+
// - If we MUST refresh, then return the refresh task, blocking
|
14875
|
+
// the pipeline until a token is available.
|
14876
|
+
// - If we SHOULD refresh, then run refresh but don't return it
|
14877
|
+
// (we can still use the cached token).
|
14878
|
+
// - Return the token, since it's fine if we didn't return in
|
14879
|
+
// step 1.
|
14880
|
+
//
|
14881
|
+
if (cycler.mustRefresh)
|
14882
|
+
return refresh(tokenOptions);
|
14883
|
+
if (cycler.shouldRefresh) {
|
14884
|
+
refresh(tokenOptions);
|
14885
|
+
}
|
14886
|
+
return token;
|
14887
|
+
};
|
14888
|
+
}
|
14889
|
+
/**
|
14890
|
+
* We will retrieve the challenge only if the response status code was 401,
|
14891
|
+
* and if the response contained the header "WWW-Authenticate" with a non-empty value.
|
14892
|
+
*/
|
14893
|
+
function getChallenge(response) {
|
14894
|
+
const challenge = response.headers.get("WWW-Authenticate");
|
14895
|
+
if (response.status === 401 && challenge) {
|
14896
|
+
return challenge;
|
14897
|
+
}
|
14898
|
+
return;
|
14899
|
+
}
|
14900
|
+
/**
|
14901
|
+
* Converts: `Bearer a="b" c="d"`.
|
14902
|
+
* Into: `[ { a: 'b', c: 'd' }]`.
|
14903
|
+
*
|
14904
|
+
* @internal
|
14905
|
+
*/
|
14906
|
+
function parseChallenge(challenge) {
|
14907
|
+
const bearerChallenge = challenge.slice("Bearer ".length);
|
14908
|
+
const challengeParts = `${bearerChallenge.trim()} `.split(" ").filter((x) => x);
|
14909
|
+
const keyValuePairs = challengeParts.map((keyValue) => (([key, value]) => ({ [key]: value }))(keyValue.trim().split("=")));
|
14910
|
+
// Key-value pairs to plain object:
|
14911
|
+
return keyValuePairs.reduce((a, b) => (Object.assign(Object.assign({}, a), b)), {});
|
14912
|
+
}
|
14913
|
+
// #endregion
|
14914
|
+
/**
|
14915
|
+
* Creates a new factory for a RequestPolicy that applies a bearer token to
|
14916
|
+
* the requests' `Authorization` headers.
|
14917
|
+
*
|
14918
|
+
* @param credential - The TokenCredential implementation that can supply the bearer token.
|
14919
|
+
* @param scopes - The scopes for which the bearer token applies.
|
14920
|
+
*/
|
14921
|
+
function storageBearerTokenChallengeAuthenticationPolicy(credential, scopes) {
|
14922
|
+
// This simple function encapsulates the entire process of reliably retrieving the token
|
14923
|
+
let getToken = createTokenCycler(credential, scopes);
|
14924
|
+
class StorageBearerTokenChallengeAuthenticationPolicy extends coreHttp.BaseRequestPolicy {
|
14925
|
+
constructor(nextPolicy, options) {
|
14926
|
+
super(nextPolicy, options);
|
14927
|
+
}
|
14928
|
+
async sendRequest(webResource) {
|
14929
|
+
if (!webResource.url.toLowerCase().startsWith("https://")) {
|
14930
|
+
throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.");
|
14931
|
+
}
|
14932
|
+
const getTokenInternal = getToken;
|
14933
|
+
const token = (await getTokenInternal({
|
14934
|
+
abortSignal: webResource.abortSignal,
|
14935
|
+
tracingOptions: {
|
14936
|
+
tracingContext: webResource.tracingContext,
|
14937
|
+
},
|
14938
|
+
})).token;
|
14939
|
+
webResource.headers.set(Constants.HeaderConstants.AUTHORIZATION, `Bearer ${token}`);
|
14940
|
+
const response = await this._nextPolicy.sendRequest(webResource);
|
14941
|
+
if ((response === null || response === void 0 ? void 0 : response.status) === 401) {
|
14942
|
+
const challenge = getChallenge(response);
|
14943
|
+
if (challenge) {
|
14944
|
+
const challengeInfo = parseChallenge(challenge);
|
14945
|
+
const challengeScopes = challengeInfo.resource_id + Constants.DefaultScope;
|
14946
|
+
const parsedAuthUri = coreHttp.URLBuilder.parse(challengeInfo.authorization_uri);
|
14947
|
+
const pathSegments = parsedAuthUri.getPath().split("/");
|
14948
|
+
const tenantId = pathSegments[1];
|
14949
|
+
const getTokenForChallenge = createTokenCycler(credential, challengeScopes);
|
14950
|
+
const tokenForChallenge = (await getTokenForChallenge({
|
14951
|
+
abortSignal: webResource.abortSignal,
|
14952
|
+
tracingOptions: {
|
14953
|
+
tracingContext: webResource.tracingContext,
|
14954
|
+
},
|
14955
|
+
tenantId: tenantId,
|
14956
|
+
})).token;
|
14957
|
+
getToken = getTokenForChallenge;
|
14958
|
+
webResource.headers.set(Constants.HeaderConstants.AUTHORIZATION, `Bearer ${tokenForChallenge}`);
|
14959
|
+
return this._nextPolicy.sendRequest(webResource);
|
14960
|
+
}
|
14961
|
+
}
|
14962
|
+
return response;
|
14963
|
+
}
|
14964
|
+
}
|
14965
|
+
return {
|
14966
|
+
create: (nextPolicy, options) => {
|
14967
|
+
return new StorageBearerTokenChallengeAuthenticationPolicy(nextPolicy, options);
|
14968
|
+
},
|
14969
|
+
};
|
14970
|
+
}
|
14971
|
+
|
14593
14972
|
// Copyright (c) Microsoft Corporation.
|
14594
14973
|
/**
|
14595
14974
|
* A helper to decide if a given argument satisfies the Pipeline contract
|
@@ -14635,7 +15014,7 @@ class Pipeline {
|
|
14635
15014
|
toServiceClientOptions() {
|
14636
15015
|
return {
|
14637
15016
|
httpClient: this.options.httpClient,
|
14638
|
-
requestPolicyFactories: this.factories
|
15017
|
+
requestPolicyFactories: this.factories,
|
14639
15018
|
};
|
14640
15019
|
}
|
14641
15020
|
}
|
@@ -14647,6 +15026,7 @@ class Pipeline {
|
|
14647
15026
|
* @returns A new Pipeline object.
|
14648
15027
|
*/
|
14649
15028
|
function newPipeline(credential, pipelineOptions = {}) {
|
15029
|
+
var _a;
|
14650
15030
|
if (credential === undefined) {
|
14651
15031
|
credential = new AnonymousCredential();
|
14652
15032
|
}
|
@@ -14668,16 +15048,16 @@ function newPipeline(credential, pipelineOptions = {}) {
|
|
14668
15048
|
coreHttp.logPolicy({
|
14669
15049
|
logger: logger.info,
|
14670
15050
|
allowedHeaderNames: StorageBlobLoggingAllowedHeaderNames,
|
14671
|
-
allowedQueryParameters: StorageBlobLoggingAllowedQueryParameters
|
14672
|
-
})
|
15051
|
+
allowedQueryParameters: StorageBlobLoggingAllowedQueryParameters,
|
15052
|
+
}),
|
14673
15053
|
];
|
14674
|
-
{
|
15054
|
+
if (coreHttp.isNode) {
|
14675
15055
|
// policies only available in Node.js runtime, not in browsers
|
14676
15056
|
factories.push(coreHttp.proxyPolicy(pipelineOptions.proxyOptions));
|
14677
15057
|
factories.push(coreHttp.disableResponseDecompressionPolicy());
|
14678
15058
|
}
|
14679
15059
|
factories.push(coreHttp.isTokenCredential(credential)
|
14680
|
-
? attachCredential(
|
15060
|
+
? attachCredential(storageBearerTokenChallengeAuthenticationPolicy(credential, (_a = pipelineOptions.audience) !== null && _a !== void 0 ? _a : StorageOAuthScopes), credential)
|
14681
15061
|
: credential);
|
14682
15062
|
return new Pipeline(factories, pipelineOptions);
|
14683
15063
|
}
|
@@ -14704,7 +15084,9 @@ class StorageSharedKeyCredentialPolicy extends CredentialPolicy {
|
|
14704
15084
|
*/
|
14705
15085
|
signRequest(request) {
|
14706
15086
|
request.headers.set(HeaderConstants.X_MS_DATE, new Date().toUTCString());
|
14707
|
-
if (request.body &&
|
15087
|
+
if (request.body &&
|
15088
|
+
(typeof request.body === "string" || request.body !== undefined) &&
|
15089
|
+
request.body.length > 0) {
|
14708
15090
|
request.headers.set(HeaderConstants.CONTENT_LENGTH, Buffer.byteLength(request.body));
|
14709
15091
|
}
|
14710
15092
|
const stringToSign = [
|
@@ -14719,7 +15101,7 @@ class StorageSharedKeyCredentialPolicy extends CredentialPolicy {
|
|
14719
15101
|
this.getHeaderValueToSign(request, HeaderConstants.IF_MATCH),
|
14720
15102
|
this.getHeaderValueToSign(request, HeaderConstants.IF_NONE_MATCH),
|
14721
15103
|
this.getHeaderValueToSign(request, HeaderConstants.IF_UNMODIFIED_SINCE),
|
14722
|
-
this.getHeaderValueToSign(request, HeaderConstants.RANGE)
|
15104
|
+
this.getHeaderValueToSign(request, HeaderConstants.RANGE),
|
14723
15105
|
].join("\n") +
|
14724
15106
|
"\n" +
|
14725
15107
|
this.getCanonicalizedHeadersString(request) +
|
@@ -14848,9 +15230,7 @@ class StorageSharedKeyCredential extends Credential {
|
|
14848
15230
|
* @param stringToSign -
|
14849
15231
|
*/
|
14850
15232
|
computeHMACSHA256(stringToSign) {
|
14851
|
-
return crypto.createHmac("sha256", this.accountKey)
|
14852
|
-
.update(stringToSign, "utf8")
|
14853
|
-
.digest("base64");
|
15233
|
+
return crypto.createHmac("sha256", this.accountKey).update(stringToSign, "utf8").digest("base64");
|
14854
15234
|
}
|
14855
15235
|
}
|
14856
15236
|
|
@@ -14862,8 +15242,8 @@ class StorageSharedKeyCredential extends Credential {
|
|
14862
15242
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
14863
15243
|
*/
|
14864
15244
|
const packageName = "azure-storage-blob";
|
14865
|
-
const packageVersion = "12.9.0
|
14866
|
-
class StorageClientContext extends
|
15245
|
+
const packageVersion = "12.9.0";
|
15246
|
+
class StorageClientContext extends coreHttp__namespace.ServiceClient {
|
14867
15247
|
/**
|
14868
15248
|
* Initializes a new instance of the StorageClientContext class.
|
14869
15249
|
* @param url The URL of the service account, container, or blob that is the target of the desired
|
@@ -14879,7 +15259,7 @@ class StorageClientContext extends coreHttp.ServiceClient {
|
|
14879
15259
|
options = {};
|
14880
15260
|
}
|
14881
15261
|
if (!options.userAgent) {
|
14882
|
-
const defaultUserAgent =
|
15262
|
+
const defaultUserAgent = coreHttp__namespace.getDefaultUserAgentValue();
|
14883
15263
|
options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`;
|
14884
15264
|
}
|
14885
15265
|
super(undefined, options);
|
@@ -14888,7 +15268,7 @@ class StorageClientContext extends coreHttp.ServiceClient {
|
|
14888
15268
|
// Parameter assignments
|
14889
15269
|
this.url = url;
|
14890
15270
|
// Assigning values to Constant parameters
|
14891
|
-
this.version = options.version || "2021-
|
15271
|
+
this.version = options.version || "2021-04-10";
|
14892
15272
|
}
|
14893
15273
|
}
|
14894
15274
|
|
@@ -14935,7 +15315,7 @@ class StorageClient {
|
|
14935
15315
|
*/
|
14936
15316
|
const createSpan = coreTracing.createSpanFunction({
|
14937
15317
|
packagePrefix: "Azure.Storage.Blob",
|
14938
|
-
namespace: "Microsoft.Storage"
|
15318
|
+
namespace: "Microsoft.Storage",
|
14939
15319
|
});
|
14940
15320
|
/**
|
14941
15321
|
* @internal
|
@@ -14949,7 +15329,7 @@ function convertTracingToRequestOptionsBase(options) {
|
|
14949
15329
|
return {
|
14950
15330
|
// By passing spanOptions if they exist at runtime, we're backwards compatible with @azure/core-tracing@preview.13 and earlier.
|
14951
15331
|
spanOptions: (_a = options === null || options === void 0 ? void 0 : options.tracingOptions) === null || _a === void 0 ? void 0 : _a.spanOptions,
|
14952
|
-
tracingContext: (_b = options === null || options === void 0 ? void 0 : options.tracingOptions) === null || _b === void 0 ? void 0 : _b.tracingContext
|
15332
|
+
tracingContext: (_b = options === null || options === void 0 ? void 0 : options.tracingOptions) === null || _b === void 0 ? void 0 : _b.tracingContext,
|
14953
15333
|
};
|
14954
15334
|
}
|
14955
15335
|
|
@@ -15207,6 +15587,10 @@ class ContainerSASPermissions {
|
|
15207
15587
|
* Specifies that Permanent Delete is permitted.
|
15208
15588
|
*/
|
15209
15589
|
this.permanentDelete = false;
|
15590
|
+
/**
|
15591
|
+
* Specifies that Filter Blobs by Tags is permitted.
|
15592
|
+
*/
|
15593
|
+
this.filterByTags = false;
|
15210
15594
|
}
|
15211
15595
|
/**
|
15212
15596
|
* Creates an {@link ContainerSASPermissions} from the specified permissions string. This method will throw an
|
@@ -15254,6 +15638,9 @@ class ContainerSASPermissions {
|
|
15254
15638
|
case "y":
|
15255
15639
|
containerSASPermissions.permanentDelete = true;
|
15256
15640
|
break;
|
15641
|
+
case "f":
|
15642
|
+
containerSASPermissions.filterByTags = true;
|
15643
|
+
break;
|
15257
15644
|
default:
|
15258
15645
|
throw new RangeError(`Invalid permission ${char}`);
|
15259
15646
|
}
|
@@ -15304,6 +15691,9 @@ class ContainerSASPermissions {
|
|
15304
15691
|
if (permissionLike.permanentDelete) {
|
15305
15692
|
containerSASPermissions.permanentDelete = true;
|
15306
15693
|
}
|
15694
|
+
if (permissionLike.filterByTags) {
|
15695
|
+
containerSASPermissions.filterByTags = true;
|
15696
|
+
}
|
15307
15697
|
return containerSASPermissions;
|
15308
15698
|
}
|
15309
15699
|
/**
|
@@ -15352,6 +15742,9 @@ class ContainerSASPermissions {
|
|
15352
15742
|
if (this.permanentDelete) {
|
15353
15743
|
permissions.push("y");
|
15354
15744
|
}
|
15745
|
+
if (this.filterByTags) {
|
15746
|
+
permissions.push("f");
|
15747
|
+
}
|
15355
15748
|
return permissions.join("");
|
15356
15749
|
}
|
15357
15750
|
}
|
@@ -15381,9 +15774,7 @@ class UserDelegationKeyCredential {
|
|
15381
15774
|
*/
|
15382
15775
|
computeHMACSHA256(stringToSign) {
|
15383
15776
|
// console.log(`stringToSign: ${JSON.stringify(stringToSign)}`);
|
15384
|
-
return crypto.createHmac("sha256", this.key)
|
15385
|
-
.update(stringToSign, "utf8")
|
15386
|
-
.digest("base64");
|
15777
|
+
return crypto.createHmac("sha256", this.key).update(stringToSign, "utf8").digest("base64");
|
15387
15778
|
}
|
15388
15779
|
}
|
15389
15780
|
|
@@ -15401,6 +15792,10 @@ function ipRangeToString(ipRange) {
|
|
15401
15792
|
}
|
15402
15793
|
|
15403
15794
|
// Copyright (c) Microsoft Corporation.
|
15795
|
+
/**
|
15796
|
+
* Protocols for generated SAS.
|
15797
|
+
*/
|
15798
|
+
exports.SASProtocol = void 0;
|
15404
15799
|
(function (SASProtocol) {
|
15405
15800
|
/**
|
15406
15801
|
* Protocol that allows HTTPS only
|
@@ -15489,7 +15884,7 @@ class SASQueryParameters {
|
|
15489
15884
|
if (this.ipRangeInner) {
|
15490
15885
|
return {
|
15491
15886
|
end: this.ipRangeInner.end,
|
15492
|
-
start: this.ipRangeInner.start
|
15887
|
+
start: this.ipRangeInner.start,
|
15493
15888
|
};
|
15494
15889
|
}
|
15495
15890
|
return undefined;
|
@@ -15524,7 +15919,7 @@ class SASQueryParameters {
|
|
15524
15919
|
"rscl",
|
15525
15920
|
"rsct",
|
15526
15921
|
"saoid",
|
15527
|
-
"scid"
|
15922
|
+
"scid",
|
15528
15923
|
];
|
15529
15924
|
const queries = [];
|
15530
15925
|
for (const param of params) {
|
@@ -15730,7 +16125,7 @@ function generateBlobSASQueryParameters20150405(blobSASSignatureValues, sharedKe
|
|
15730
16125
|
blobSASSignatureValues.contentDisposition ? blobSASSignatureValues.contentDisposition : "",
|
15731
16126
|
blobSASSignatureValues.contentEncoding ? blobSASSignatureValues.contentEncoding : "",
|
15732
16127
|
blobSASSignatureValues.contentLanguage ? blobSASSignatureValues.contentLanguage : "",
|
15733
|
-
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : ""
|
16128
|
+
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : "",
|
15734
16129
|
].join("\n");
|
15735
16130
|
const signature = sharedKeyCredential.computeHMACSHA256(stringToSign);
|
15736
16131
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType);
|
@@ -15799,7 +16194,7 @@ function generateBlobSASQueryParameters20181109(blobSASSignatureValues, sharedKe
|
|
15799
16194
|
blobSASSignatureValues.contentDisposition ? blobSASSignatureValues.contentDisposition : "",
|
15800
16195
|
blobSASSignatureValues.contentEncoding ? blobSASSignatureValues.contentEncoding : "",
|
15801
16196
|
blobSASSignatureValues.contentLanguage ? blobSASSignatureValues.contentLanguage : "",
|
15802
|
-
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : ""
|
16197
|
+
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : "",
|
15803
16198
|
].join("\n");
|
15804
16199
|
const signature = sharedKeyCredential.computeHMACSHA256(stringToSign);
|
15805
16200
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType);
|
@@ -15869,7 +16264,7 @@ function generateBlobSASQueryParameters20201206(blobSASSignatureValues, sharedKe
|
|
15869
16264
|
blobSASSignatureValues.contentDisposition ? blobSASSignatureValues.contentDisposition : "",
|
15870
16265
|
blobSASSignatureValues.contentEncoding ? blobSASSignatureValues.contentEncoding : "",
|
15871
16266
|
blobSASSignatureValues.contentLanguage ? blobSASSignatureValues.contentLanguage : "",
|
15872
|
-
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : ""
|
16267
|
+
blobSASSignatureValues.contentType ? blobSASSignatureValues.contentType : "",
|
15873
16268
|
].join("\n");
|
15874
16269
|
const signature = sharedKeyCredential.computeHMACSHA256(stringToSign);
|
15875
16270
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, undefined, undefined, undefined, blobSASSignatureValues.encryptionScope);
|
@@ -15945,7 +16340,7 @@ function generateBlobSASQueryParametersUDK20181109(blobSASSignatureValues, userD
|
|
15945
16340
|
blobSASSignatureValues.contentDisposition,
|
15946
16341
|
blobSASSignatureValues.contentEncoding,
|
15947
16342
|
blobSASSignatureValues.contentLanguage,
|
15948
|
-
blobSASSignatureValues.contentType
|
16343
|
+
blobSASSignatureValues.contentType,
|
15949
16344
|
].join("\n");
|
15950
16345
|
const signature = userDelegationKeyCredential.computeHMACSHA256(stringToSign);
|
15951
16346
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, userDelegationKeyCredential.userDelegationKey);
|
@@ -16024,7 +16419,7 @@ function generateBlobSASQueryParametersUDK20200210(blobSASSignatureValues, userD
|
|
16024
16419
|
blobSASSignatureValues.contentDisposition,
|
16025
16420
|
blobSASSignatureValues.contentEncoding,
|
16026
16421
|
blobSASSignatureValues.contentLanguage,
|
16027
|
-
blobSASSignatureValues.contentType
|
16422
|
+
blobSASSignatureValues.contentType,
|
16028
16423
|
].join("\n");
|
16029
16424
|
const signature = userDelegationKeyCredential.computeHMACSHA256(stringToSign);
|
16030
16425
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, userDelegationKeyCredential.userDelegationKey, blobSASSignatureValues.preauthorizedAgentObjectId, blobSASSignatureValues.correlationId);
|
@@ -16104,7 +16499,7 @@ function generateBlobSASQueryParametersUDK20201206(blobSASSignatureValues, userD
|
|
16104
16499
|
blobSASSignatureValues.contentDisposition,
|
16105
16500
|
blobSASSignatureValues.contentEncoding,
|
16106
16501
|
blobSASSignatureValues.contentLanguage,
|
16107
|
-
blobSASSignatureValues.contentType
|
16502
|
+
blobSASSignatureValues.contentType,
|
16108
16503
|
].join("\n");
|
16109
16504
|
const signature = userDelegationKeyCredential.computeHMACSHA256(stringToSign);
|
16110
16505
|
return new SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, userDelegationKeyCredential.userDelegationKey, blobSASSignatureValues.preauthorizedAgentObjectId, blobSASSignatureValues.correlationId, blobSASSignatureValues.encryptionScope);
|
@@ -16157,6 +16552,11 @@ function SASSignatureValuesSanityCheckAndAutofill(blobSASSignatureValues) {
|
|
16157
16552
|
(blobSASSignatureValues.permissions.move || blobSASSignatureValues.permissions.execute)) {
|
16158
16553
|
throw RangeError("'version' must be >= '2020-02-10' when providing the 'm' or 'e' permission.");
|
16159
16554
|
}
|
16555
|
+
if (version < "2021-04-10" &&
|
16556
|
+
blobSASSignatureValues.permissions &&
|
16557
|
+
blobSASSignatureValues.permissions.filterByTags) {
|
16558
|
+
throw RangeError("'version' must be >= '2021-04-10' when providing the 'f' permission.");
|
16559
|
+
}
|
16160
16560
|
if (version < "2020-02-10" &&
|
16161
16561
|
(blobSASSignatureValues.preauthorizedAgentObjectId || blobSASSignatureValues.correlationId)) {
|
16162
16562
|
throw RangeError("'version' must be >= '2020-02-10' when providing 'preauthorizedAgentObjectId' or 'correlationId'.");
|
@@ -16237,7 +16637,7 @@ class BlobLeaseClient {
|
|
16237
16637
|
catch (e) {
|
16238
16638
|
span.setStatus({
|
16239
16639
|
code: coreTracing.SpanStatusCode.ERROR,
|
16240
|
-
message: e.message
|
16640
|
+
message: e.message,
|
16241
16641
|
});
|
16242
16642
|
throw e;
|
16243
16643
|
}
|
@@ -16272,7 +16672,7 @@ class BlobLeaseClient {
|
|
16272
16672
|
catch (e) {
|
16273
16673
|
span.setStatus({
|
16274
16674
|
code: coreTracing.SpanStatusCode.ERROR,
|
16275
|
-
message: e.message
|
16675
|
+
message: e.message,
|
16276
16676
|
});
|
16277
16677
|
throw e;
|
16278
16678
|
}
|
@@ -16305,7 +16705,7 @@ class BlobLeaseClient {
|
|
16305
16705
|
catch (e) {
|
16306
16706
|
span.setStatus({
|
16307
16707
|
code: coreTracing.SpanStatusCode.ERROR,
|
16308
|
-
message: e.message
|
16708
|
+
message: e.message,
|
16309
16709
|
});
|
16310
16710
|
throw e;
|
16311
16711
|
}
|
@@ -16337,7 +16737,7 @@ class BlobLeaseClient {
|
|
16337
16737
|
catch (e) {
|
16338
16738
|
span.setStatus({
|
16339
16739
|
code: coreTracing.SpanStatusCode.ERROR,
|
16340
|
-
message: e.message
|
16740
|
+
message: e.message,
|
16341
16741
|
});
|
16342
16742
|
throw e;
|
16343
16743
|
}
|
@@ -16372,7 +16772,7 @@ class BlobLeaseClient {
|
|
16372
16772
|
catch (e) {
|
16373
16773
|
span.setStatus({
|
16374
16774
|
code: coreTracing.SpanStatusCode.ERROR,
|
16375
|
-
message: e.message
|
16775
|
+
message: e.message,
|
16376
16776
|
});
|
16377
16777
|
throw e;
|
16378
16778
|
}
|
@@ -16452,8 +16852,7 @@ class RetriableReadableStream extends stream.Readable {
|
|
16452
16852
|
});
|
16453
16853
|
}
|
16454
16854
|
else {
|
16455
|
-
this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this
|
16456
|
-
.offset - 1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`));
|
16855
|
+
this.destroy(new Error(`Data corruption failure: received less data than required and reached maxRetires limitation. Received data offset: ${this.offset - 1}, data needed offset: ${this.end}, retries: ${this.retries}, max retries: ${this.maxRetryRequests}`));
|
16457
16856
|
}
|
16458
16857
|
}
|
16459
16858
|
else {
|
@@ -17298,7 +17697,7 @@ class AvroReader {
|
|
17298
17697
|
}
|
17299
17698
|
async initialize(options = {}) {
|
17300
17699
|
const header = await AvroParser.readFixedBytes(this._headerStream, AVRO_INIT_BYTES.length, {
|
17301
|
-
abortSignal: options.abortSignal
|
17700
|
+
abortSignal: options.abortSignal,
|
17302
17701
|
});
|
17303
17702
|
if (!arraysEqual(header, AVRO_INIT_BYTES)) {
|
17304
17703
|
throw new Error("Stream is not an Avro file.");
|
@@ -17306,7 +17705,7 @@ class AvroReader {
|
|
17306
17705
|
// File metadata is written as if defined by the following map schema:
|
17307
17706
|
// { "type": "map", "values": "bytes"}
|
17308
17707
|
this._metadata = await AvroParser.readMap(this._headerStream, AvroParser.readString, {
|
17309
|
-
abortSignal: options.abortSignal
|
17708
|
+
abortSignal: options.abortSignal,
|
17310
17709
|
});
|
17311
17710
|
// Validate codec
|
17312
17711
|
const codec = this._metadata[AVRO_CODEC_KEY];
|
@@ -17315,7 +17714,7 @@ class AvroReader {
|
|
17315
17714
|
}
|
17316
17715
|
// The 16-byte, randomly-generated sync marker for this file.
|
17317
17716
|
this._syncMarker = await AvroParser.readFixedBytes(this._headerStream, AVRO_SYNC_MARKER_SIZE, {
|
17318
|
-
abortSignal: options.abortSignal
|
17717
|
+
abortSignal: options.abortSignal,
|
17319
17718
|
});
|
17320
17719
|
// Parse the schema
|
17321
17720
|
const schema = JSON.parse(this._metadata[AVRO_SCHEMA_KEY]);
|
@@ -17324,7 +17723,7 @@ class AvroReader {
|
|
17324
17723
|
this._blockOffset = this._initialBlockOffset + this._dataStream.position;
|
17325
17724
|
}
|
17326
17725
|
this._itemsRemainingInBlock = await AvroParser.readLong(this._dataStream, {
|
17327
|
-
abortSignal: options.abortSignal
|
17726
|
+
abortSignal: options.abortSignal,
|
17328
17727
|
});
|
17329
17728
|
// skip block length
|
17330
17729
|
await AvroParser.readLong(this._dataStream, { abortSignal: options.abortSignal });
|
@@ -17346,13 +17745,13 @@ class AvroReader {
|
|
17346
17745
|
}
|
17347
17746
|
while (this.hasNext()) {
|
17348
17747
|
const result = yield tslib.__await(this._itemType.read(this._dataStream, {
|
17349
|
-
abortSignal: options.abortSignal
|
17748
|
+
abortSignal: options.abortSignal,
|
17350
17749
|
}));
|
17351
17750
|
this._itemsRemainingInBlock--;
|
17352
17751
|
this._objectIndex++;
|
17353
17752
|
if (this._itemsRemainingInBlock == 0) {
|
17354
17753
|
const marker = yield tslib.__await(AvroParser.readFixedBytes(this._dataStream, AVRO_SYNC_MARKER_SIZE, {
|
17355
|
-
abortSignal: options.abortSignal
|
17754
|
+
abortSignal: options.abortSignal,
|
17356
17755
|
}));
|
17357
17756
|
this._blockOffset = this._initialBlockOffset + this._dataStream.position;
|
17358
17757
|
this._objectIndex = 0;
|
@@ -17361,7 +17760,7 @@ class AvroReader {
|
|
17361
17760
|
}
|
17362
17761
|
try {
|
17363
17762
|
this._itemsRemainingInBlock = yield tslib.__await(AvroParser.readLong(this._dataStream, {
|
17364
|
-
abortSignal: options.abortSignal
|
17763
|
+
abortSignal: options.abortSignal,
|
17365
17764
|
}));
|
17366
17765
|
}
|
17367
17766
|
catch (err) {
|
@@ -17560,7 +17959,7 @@ class BlobQuickQueryStream extends stream.Readable {
|
|
17560
17959
|
position,
|
17561
17960
|
name,
|
17562
17961
|
isFatal: fatal,
|
17563
|
-
description
|
17962
|
+
description,
|
17564
17963
|
});
|
17565
17964
|
}
|
17566
17965
|
break;
|
@@ -17936,6 +18335,11 @@ class BlobQueryResponse {
|
|
17936
18335
|
}
|
17937
18336
|
|
17938
18337
|
// Copyright (c) Microsoft Corporation.
|
18338
|
+
/**
|
18339
|
+
* Represents the access tier on a blob.
|
18340
|
+
* For detailed information about block blob level tiering see {@link https://docs.microsoft.com/azure/storage/blobs/storage-blob-storage-tiers|Hot, cool and archive storage tiers.}
|
18341
|
+
*/
|
18342
|
+
exports.BlockBlobTier = void 0;
|
17939
18343
|
(function (BlockBlobTier) {
|
17940
18344
|
/**
|
17941
18345
|
* Optimized for storing data that is accessed frequently.
|
@@ -17951,6 +18355,12 @@ class BlobQueryResponse {
|
|
17951
18355
|
*/
|
17952
18356
|
BlockBlobTier["Archive"] = "Archive";
|
17953
18357
|
})(exports.BlockBlobTier || (exports.BlockBlobTier = {}));
|
18358
|
+
/**
|
18359
|
+
* Specifies the page blob tier to set the blob to. This is only applicable to page blobs on premium storage accounts.
|
18360
|
+
* Please see {@link https://docs.microsoft.com/azure/storage/storage-premium-storage#scalability-and-performance-targets|here}
|
18361
|
+
* for detailed information on the corresponding IOPS and throughput per PageBlobTier.
|
18362
|
+
*/
|
18363
|
+
exports.PremiumPageBlobTier = void 0;
|
17954
18364
|
(function (PremiumPageBlobTier) {
|
17955
18365
|
/**
|
17956
18366
|
* P4 Tier.
|
@@ -18011,6 +18421,20 @@ function ensureCpkIfSpecified(cpk, isHttps) {
|
|
18011
18421
|
cpk.encryptionAlgorithm = EncryptionAlgorithmAES25;
|
18012
18422
|
}
|
18013
18423
|
}
|
18424
|
+
/**
|
18425
|
+
* Defines the known cloud audiences for Storage.
|
18426
|
+
*/
|
18427
|
+
exports.StorageBlobAudience = void 0;
|
18428
|
+
(function (StorageBlobAudience) {
|
18429
|
+
/**
|
18430
|
+
* The OAuth scope to use to retrieve an AAD token for Azure Storage.
|
18431
|
+
*/
|
18432
|
+
StorageBlobAudience["StorageOAuthScopes"] = "https://storage.azure.com/.default";
|
18433
|
+
/**
|
18434
|
+
* The OAuth scope to use to retrieve an AAD token for Azure Disk.
|
18435
|
+
*/
|
18436
|
+
StorageBlobAudience["DiskComputeOAuthScopes"] = "https://disk.compute.azure.com/.default";
|
18437
|
+
})(exports.StorageBlobAudience || (exports.StorageBlobAudience = {}));
|
18014
18438
|
|
18015
18439
|
// Copyright (c) Microsoft Corporation.
|
18016
18440
|
// Licensed under the MIT license.
|
@@ -18023,16 +18447,16 @@ function ensureCpkIfSpecified(cpk, isHttps) {
|
|
18023
18447
|
function rangeResponseFromModel(response) {
|
18024
18448
|
const pageRange = (response._response.parsedBody.pageRange || []).map((x) => ({
|
18025
18449
|
offset: x.start,
|
18026
|
-
count: x.end - x.start
|
18450
|
+
count: x.end - x.start,
|
18027
18451
|
}));
|
18028
18452
|
const clearRange = (response._response.parsedBody.clearRange || []).map((x) => ({
|
18029
18453
|
offset: x.start,
|
18030
|
-
count: x.end - x.start
|
18454
|
+
count: x.end - x.start,
|
18031
18455
|
}));
|
18032
18456
|
return Object.assign(Object.assign({}, response), { pageRange,
|
18033
18457
|
clearRange, _response: Object.assign(Object.assign({}, response._response), { parsedBody: {
|
18034
18458
|
pageRange,
|
18035
|
-
clearRange
|
18459
|
+
clearRange,
|
18036
18460
|
} }) });
|
18037
18461
|
}
|
18038
18462
|
|
@@ -18045,7 +18469,7 @@ function rangeResponseFromModel(response) {
|
|
18045
18469
|
*/
|
18046
18470
|
class BlobBeginCopyFromUrlPoller extends coreLro.Poller {
|
18047
18471
|
constructor(options) {
|
18048
|
-
const { blobClient, copySource, intervalInMs = 15000, onProgress, resumeFrom, startCopyFromURLOptions } = options;
|
18472
|
+
const { blobClient, copySource, intervalInMs = 15000, onProgress, resumeFrom, startCopyFromURLOptions, } = options;
|
18049
18473
|
let state;
|
18050
18474
|
if (resumeFrom) {
|
18051
18475
|
state = JSON.parse(resumeFrom).state;
|
@@ -18081,7 +18505,7 @@ const cancel = async function cancel(options = {}) {
|
|
18081
18505
|
}
|
18082
18506
|
// if abortCopyFromURL throws, it will bubble up to user's poller.cancelOperation call
|
18083
18507
|
await state.blobClient.abortCopyFromURL(copyId, {
|
18084
|
-
abortSignal: options.abortSignal
|
18508
|
+
abortSignal: options.abortSignal,
|
18085
18509
|
});
|
18086
18510
|
state.isCancelled = true;
|
18087
18511
|
return makeBlobBeginCopyFromURLPollOperation(state);
|
@@ -18159,7 +18583,7 @@ function makeBlobBeginCopyFromURLPollOperation(state) {
|
|
18159
18583
|
state: Object.assign({}, state),
|
18160
18584
|
cancel,
|
18161
18585
|
toString,
|
18162
|
-
update
|
18586
|
+
update,
|
18163
18587
|
};
|
18164
18588
|
}
|
18165
18589
|
|
@@ -18801,7 +19225,7 @@ async function streamToBuffer2(stream, buffer, encoding) {
|
|
18801
19225
|
*/
|
18802
19226
|
async function readStreamToLocalFile(rs, file) {
|
18803
19227
|
return new Promise((resolve, reject) => {
|
18804
|
-
const ws =
|
19228
|
+
const ws = fs__namespace.createWriteStream(file);
|
18805
19229
|
rs.on("error", (err) => {
|
18806
19230
|
reject(err);
|
18807
19231
|
});
|
@@ -18817,8 +19241,8 @@ async function readStreamToLocalFile(rs, file) {
|
|
18817
19241
|
*
|
18818
19242
|
* Promisified version of fs.stat().
|
18819
19243
|
*/
|
18820
|
-
const fsStat =
|
18821
|
-
const fsCreateReadStream =
|
19244
|
+
const fsStat = util__namespace.promisify(fs__namespace.stat);
|
19245
|
+
const fsCreateReadStream = fs__namespace.createReadStream;
|
18822
19246
|
|
18823
19247
|
/**
|
18824
19248
|
* A BlobClient represents a URL to an Azure Storage blob; the blob may be a block blob,
|
@@ -18861,12 +19285,17 @@ class BlobClient extends StorageClient {
|
|
18861
19285
|
const blobName = blobNameOrOptions;
|
18862
19286
|
const extractedCreds = extractConnectionStringParts(urlOrConnectionString);
|
18863
19287
|
if (extractedCreds.kind === "AccountConnString") {
|
18864
|
-
{
|
19288
|
+
if (coreHttp.isNode) {
|
18865
19289
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
18866
19290
|
url = appendToURLPath(appendToURLPath(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
18867
|
-
options.proxyOptions
|
19291
|
+
if (!options.proxyOptions) {
|
19292
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
19293
|
+
}
|
18868
19294
|
pipeline = newPipeline(sharedKeyCredential, options);
|
18869
19295
|
}
|
19296
|
+
else {
|
19297
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
19298
|
+
}
|
18870
19299
|
}
|
18871
19300
|
else if (extractedCreds.kind === "SASConnString") {
|
18872
19301
|
url =
|
@@ -18883,10 +19312,8 @@ class BlobClient extends StorageClient {
|
|
18883
19312
|
throw new Error("Expecting non-empty strings for containerName and blobName parameters");
|
18884
19313
|
}
|
18885
19314
|
super(url, pipeline);
|
18886
|
-
({
|
18887
|
-
|
18888
|
-
containerName: this._containerName
|
18889
|
-
} = this.getBlobAndContainerNamesFromUrl());
|
19315
|
+
({ blobName: this._name, containerName: this._containerName } =
|
19316
|
+
this.getBlobAndContainerNamesFromUrl());
|
18890
19317
|
this.blobContext = new Blob$1(this.storageClientContext);
|
18891
19318
|
this._snapshot = getURLParameter(this.url, URLConstants.Parameters.SNAPSHOT);
|
18892
19319
|
this._versionId = getURLParameter(this.url, URLConstants.Parameters.VERSIONID);
|
@@ -19011,11 +19438,11 @@ class BlobClient extends StorageClient {
|
|
19011
19438
|
const { span, updatedOptions } = createSpan("BlobClient-download", options);
|
19012
19439
|
try {
|
19013
19440
|
const res = await this.blobContext.download(Object.assign({ abortSignal: options.abortSignal, leaseAccessConditions: options.conditions, modifiedAccessConditions: Object.assign(Object.assign({}, options.conditions), { ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions }), requestOptions: {
|
19014
|
-
onDownloadProgress: coreHttp.isNode ? undefined : options.onProgress // for Node.js, progress is reported by RetriableReadableStream
|
19441
|
+
onDownloadProgress: coreHttp.isNode ? undefined : options.onProgress, // for Node.js, progress is reported by RetriableReadableStream
|
19015
19442
|
}, range: offset === 0 && !count ? undefined : rangeToString({ offset, count }), rangeGetContentMD5: options.rangeGetContentMD5, rangeGetContentCRC64: options.rangeGetContentCrc64, snapshot: options.snapshot, cpkInfo: options.customerProvidedKey }, convertTracingToRequestOptionsBase(updatedOptions)));
|
19016
19443
|
const wrappedRes = Object.assign(Object.assign({}, res), { _response: res._response, objectReplicationDestinationPolicyId: res.objectReplicationPolicyId, objectReplicationSourceProperties: parseObjectReplicationRecord(res.objectReplicationRules) });
|
19017
19444
|
// Return browser response immediately
|
19018
|
-
if (
|
19445
|
+
if (!coreHttp.isNode) {
|
19019
19446
|
return wrappedRes;
|
19020
19447
|
}
|
19021
19448
|
// We support retrying when download stream unexpected ends in Node.js runtime
|
@@ -19042,16 +19469,16 @@ class BlobClient extends StorageClient {
|
|
19042
19469
|
ifModifiedSince: options.conditions.ifModifiedSince,
|
19043
19470
|
ifNoneMatch: options.conditions.ifNoneMatch,
|
19044
19471
|
ifUnmodifiedSince: options.conditions.ifUnmodifiedSince,
|
19045
|
-
ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions
|
19472
|
+
ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions,
|
19046
19473
|
},
|
19047
19474
|
range: rangeToString({
|
19048
19475
|
count: offset + res.contentLength - start,
|
19049
|
-
offset: start
|
19476
|
+
offset: start,
|
19050
19477
|
}),
|
19051
19478
|
rangeGetContentMD5: options.rangeGetContentMD5,
|
19052
19479
|
rangeGetContentCRC64: options.rangeGetContentCrc64,
|
19053
19480
|
snapshot: options.snapshot,
|
19054
|
-
cpkInfo: options.customerProvidedKey
|
19481
|
+
cpkInfo: options.customerProvidedKey,
|
19055
19482
|
};
|
19056
19483
|
// Debug purpose only
|
19057
19484
|
// console.log(
|
@@ -19062,13 +19489,13 @@ class BlobClient extends StorageClient {
|
|
19062
19489
|
return (await this.blobContext.download(Object.assign({ abortSignal: options.abortSignal }, updatedDownloadOptions))).readableStreamBody;
|
19063
19490
|
}, offset, res.contentLength, {
|
19064
19491
|
maxRetryRequests: options.maxRetryRequests,
|
19065
|
-
onProgress: options.onProgress
|
19492
|
+
onProgress: options.onProgress,
|
19066
19493
|
});
|
19067
19494
|
}
|
19068
19495
|
catch (e) {
|
19069
19496
|
span.setStatus({
|
19070
19497
|
code: coreTracing.SpanStatusCode.ERROR,
|
19071
|
-
message: e.message
|
19498
|
+
message: e.message,
|
19072
19499
|
});
|
19073
19500
|
throw e;
|
19074
19501
|
}
|
@@ -19093,21 +19520,23 @@ class BlobClient extends StorageClient {
|
|
19093
19520
|
abortSignal: options.abortSignal,
|
19094
19521
|
customerProvidedKey: options.customerProvidedKey,
|
19095
19522
|
conditions: options.conditions,
|
19096
|
-
tracingOptions: updatedOptions.tracingOptions
|
19523
|
+
tracingOptions: updatedOptions.tracingOptions,
|
19097
19524
|
});
|
19098
19525
|
return true;
|
19099
19526
|
}
|
19100
19527
|
catch (e) {
|
19101
19528
|
if (e.statusCode === 404) {
|
19102
|
-
|
19103
|
-
code: coreTracing.SpanStatusCode.ERROR,
|
19104
|
-
message: "Expected exception when checking blob existence"
|
19105
|
-
});
|
19529
|
+
// Expected exception when checking blob existence
|
19106
19530
|
return false;
|
19107
19531
|
}
|
19532
|
+
else if (e.statusCode === 409 &&
|
19533
|
+
e.details.errorCode === BlobUsesCustomerSpecifiedEncryptionMsg) {
|
19534
|
+
// Expected exception when checking blob existence
|
19535
|
+
return true;
|
19536
|
+
}
|
19108
19537
|
span.setStatus({
|
19109
19538
|
code: coreTracing.SpanStatusCode.ERROR,
|
19110
|
-
message: e.message
|
19539
|
+
message: e.message,
|
19111
19540
|
});
|
19112
19541
|
throw e;
|
19113
19542
|
}
|
@@ -19139,7 +19568,7 @@ class BlobClient extends StorageClient {
|
|
19139
19568
|
catch (e) {
|
19140
19569
|
span.setStatus({
|
19141
19570
|
code: coreTracing.SpanStatusCode.ERROR,
|
19142
|
-
message: e.message
|
19571
|
+
message: e.message,
|
19143
19572
|
});
|
19144
19573
|
throw e;
|
19145
19574
|
}
|
@@ -19166,7 +19595,7 @@ class BlobClient extends StorageClient {
|
|
19166
19595
|
catch (e) {
|
19167
19596
|
span.setStatus({
|
19168
19597
|
code: coreTracing.SpanStatusCode.ERROR,
|
19169
|
-
message: e.message
|
19598
|
+
message: e.message,
|
19170
19599
|
});
|
19171
19600
|
throw e;
|
19172
19601
|
}
|
@@ -19188,20 +19617,19 @@ class BlobClient extends StorageClient {
|
|
19188
19617
|
const { span, updatedOptions } = createSpan("BlobClient-deleteIfExists", options);
|
19189
19618
|
try {
|
19190
19619
|
const res = await this.delete(updatedOptions);
|
19191
|
-
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response
|
19192
|
-
});
|
19620
|
+
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response });
|
19193
19621
|
}
|
19194
19622
|
catch (e) {
|
19195
19623
|
if (((_a = e.details) === null || _a === void 0 ? void 0 : _a.errorCode) === "BlobNotFound") {
|
19196
19624
|
span.setStatus({
|
19197
19625
|
code: coreTracing.SpanStatusCode.ERROR,
|
19198
|
-
message: "Expected exception when deleting a blob or snapshot only if it exists."
|
19626
|
+
message: "Expected exception when deleting a blob or snapshot only if it exists.",
|
19199
19627
|
});
|
19200
19628
|
return Object.assign(Object.assign({ succeeded: false }, (_b = e.response) === null || _b === void 0 ? void 0 : _b.parsedHeaders), { _response: e.response });
|
19201
19629
|
}
|
19202
19630
|
span.setStatus({
|
19203
19631
|
code: coreTracing.SpanStatusCode.ERROR,
|
19204
|
-
message: e.message
|
19632
|
+
message: e.message,
|
19205
19633
|
});
|
19206
19634
|
throw e;
|
19207
19635
|
}
|
@@ -19225,7 +19653,7 @@ class BlobClient extends StorageClient {
|
|
19225
19653
|
catch (e) {
|
19226
19654
|
span.setStatus({
|
19227
19655
|
code: coreTracing.SpanStatusCode.ERROR,
|
19228
|
-
message: e.message
|
19656
|
+
message: e.message,
|
19229
19657
|
});
|
19230
19658
|
throw e;
|
19231
19659
|
}
|
@@ -19259,7 +19687,7 @@ class BlobClient extends StorageClient {
|
|
19259
19687
|
catch (e) {
|
19260
19688
|
span.setStatus({
|
19261
19689
|
code: coreTracing.SpanStatusCode.ERROR,
|
19262
|
-
message: e.message
|
19690
|
+
message: e.message,
|
19263
19691
|
});
|
19264
19692
|
throw e;
|
19265
19693
|
}
|
@@ -19289,7 +19717,7 @@ class BlobClient extends StorageClient {
|
|
19289
19717
|
catch (e) {
|
19290
19718
|
span.setStatus({
|
19291
19719
|
code: coreTracing.SpanStatusCode.ERROR,
|
19292
|
-
message: e.message
|
19720
|
+
message: e.message,
|
19293
19721
|
});
|
19294
19722
|
throw e;
|
19295
19723
|
}
|
@@ -19315,7 +19743,7 @@ class BlobClient extends StorageClient {
|
|
19315
19743
|
catch (e) {
|
19316
19744
|
span.setStatus({
|
19317
19745
|
code: coreTracing.SpanStatusCode.ERROR,
|
19318
|
-
message: e.message
|
19746
|
+
message: e.message,
|
19319
19747
|
});
|
19320
19748
|
throw e;
|
19321
19749
|
}
|
@@ -19339,7 +19767,7 @@ class BlobClient extends StorageClient {
|
|
19339
19767
|
catch (e) {
|
19340
19768
|
span.setStatus({
|
19341
19769
|
code: coreTracing.SpanStatusCode.ERROR,
|
19342
|
-
message: e.message
|
19770
|
+
message: e.message,
|
19343
19771
|
});
|
19344
19772
|
throw e;
|
19345
19773
|
}
|
@@ -19373,7 +19801,7 @@ class BlobClient extends StorageClient {
|
|
19373
19801
|
catch (e) {
|
19374
19802
|
span.setStatus({
|
19375
19803
|
code: coreTracing.SpanStatusCode.ERROR,
|
19376
|
-
message: e.message
|
19804
|
+
message: e.message,
|
19377
19805
|
});
|
19378
19806
|
throw e;
|
19379
19807
|
}
|
@@ -19457,7 +19885,7 @@ class BlobClient extends StorageClient {
|
|
19457
19885
|
const client = {
|
19458
19886
|
abortCopyFromURL: (...args) => this.abortCopyFromURL(...args),
|
19459
19887
|
getProperties: (...args) => this.getProperties(...args),
|
19460
|
-
startCopyFromURL: (...args) => this.startCopyFromURL(...args)
|
19888
|
+
startCopyFromURL: (...args) => this.startCopyFromURL(...args),
|
19461
19889
|
};
|
19462
19890
|
const poller = new BlobBeginCopyFromUrlPoller({
|
19463
19891
|
blobClient: client,
|
@@ -19465,7 +19893,7 @@ class BlobClient extends StorageClient {
|
|
19465
19893
|
intervalInMs: options.intervalInMs,
|
19466
19894
|
onProgress: options.onProgress,
|
19467
19895
|
resumeFrom: options.resumeFrom,
|
19468
|
-
startCopyFromURLOptions: options
|
19896
|
+
startCopyFromURLOptions: options,
|
19469
19897
|
});
|
19470
19898
|
// Trigger the startCopyFromURL call by calling poll.
|
19471
19899
|
// Any errors from this method should be surfaced to the user.
|
@@ -19488,7 +19916,7 @@ class BlobClient extends StorageClient {
|
|
19488
19916
|
catch (e) {
|
19489
19917
|
span.setStatus({
|
19490
19918
|
code: coreTracing.SpanStatusCode.ERROR,
|
19491
|
-
message: e.message
|
19919
|
+
message: e.message,
|
19492
19920
|
});
|
19493
19921
|
throw e;
|
19494
19922
|
}
|
@@ -19514,13 +19942,13 @@ class BlobClient extends StorageClient {
|
|
19514
19942
|
sourceIfMatch: options.sourceConditions.ifMatch,
|
19515
19943
|
sourceIfModifiedSince: options.sourceConditions.ifModifiedSince,
|
19516
19944
|
sourceIfNoneMatch: options.sourceConditions.ifNoneMatch,
|
19517
|
-
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince
|
19945
|
+
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince,
|
19518
19946
|
}, sourceContentMD5: options.sourceContentMD5, copySourceAuthorization: httpAuthorizationToString(options.sourceAuthorization), blobTagsString: toBlobTagsString(options.tags), immutabilityPolicyExpiry: (_b = options.immutabilityPolicy) === null || _b === void 0 ? void 0 : _b.expiriesOn, immutabilityPolicyMode: (_c = options.immutabilityPolicy) === null || _c === void 0 ? void 0 : _c.policyMode, legalHold: options.legalHold, encryptionScope: options.encryptionScope }, convertTracingToRequestOptionsBase(updatedOptions)));
|
19519
19947
|
}
|
19520
19948
|
catch (e) {
|
19521
19949
|
span.setStatus({
|
19522
19950
|
code: coreTracing.SpanStatusCode.ERROR,
|
19523
|
-
message: e.message
|
19951
|
+
message: e.message,
|
19524
19952
|
});
|
19525
19953
|
throw e;
|
19526
19954
|
}
|
@@ -19548,7 +19976,7 @@ class BlobClient extends StorageClient {
|
|
19548
19976
|
catch (e) {
|
19549
19977
|
span.setStatus({
|
19550
19978
|
code: coreTracing.SpanStatusCode.ERROR,
|
19551
|
-
message: e.message
|
19979
|
+
message: e.message,
|
19552
19980
|
});
|
19553
19981
|
throw e;
|
19554
19982
|
}
|
@@ -19625,7 +20053,7 @@ class BlobClient extends StorageClient {
|
|
19625
20053
|
conditions: options.conditions,
|
19626
20054
|
maxRetryRequests: options.maxRetryRequestsPerBlock,
|
19627
20055
|
customerProvidedKey: options.customerProvidedKey,
|
19628
|
-
tracingOptions: Object.assign(Object.assign({}, options.tracingOptions), convertTracingToRequestOptionsBase(updatedOptions))
|
20056
|
+
tracingOptions: Object.assign(Object.assign({}, options.tracingOptions), convertTracingToRequestOptionsBase(updatedOptions)),
|
19629
20057
|
});
|
19630
20058
|
const stream = response.readableStreamBody;
|
19631
20059
|
await streamToBuffer(stream, buffer, off - offset, chunkEnd - offset);
|
@@ -19644,7 +20072,7 @@ class BlobClient extends StorageClient {
|
|
19644
20072
|
catch (e) {
|
19645
20073
|
span.setStatus({
|
19646
20074
|
code: coreTracing.SpanStatusCode.ERROR,
|
19647
|
-
message: e.message
|
20075
|
+
message: e.message,
|
19648
20076
|
});
|
19649
20077
|
throw e;
|
19650
20078
|
}
|
@@ -19682,7 +20110,7 @@ class BlobClient extends StorageClient {
|
|
19682
20110
|
catch (e) {
|
19683
20111
|
span.setStatus({
|
19684
20112
|
code: coreTracing.SpanStatusCode.ERROR,
|
19685
|
-
message: e.message
|
20113
|
+
message: e.message,
|
19686
20114
|
});
|
19687
20115
|
throw e;
|
19688
20116
|
}
|
@@ -19763,13 +20191,13 @@ class BlobClient extends StorageClient {
|
|
19763
20191
|
sourceIfModifiedSince: options.sourceConditions.ifModifiedSince,
|
19764
20192
|
sourceIfNoneMatch: options.sourceConditions.ifNoneMatch,
|
19765
20193
|
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince,
|
19766
|
-
sourceIfTags: options.sourceConditions.tagConditions
|
20194
|
+
sourceIfTags: options.sourceConditions.tagConditions,
|
19767
20195
|
}, immutabilityPolicyExpiry: (_b = options.immutabilityPolicy) === null || _b === void 0 ? void 0 : _b.expiriesOn, immutabilityPolicyMode: (_c = options.immutabilityPolicy) === null || _c === void 0 ? void 0 : _c.policyMode, legalHold: options.legalHold, rehydratePriority: options.rehydratePriority, tier: toAccessTier(options.tier), blobTagsString: toBlobTagsString(options.tags), sealBlob: options.sealBlob }, convertTracingToRequestOptionsBase(updatedOptions)));
|
19768
20196
|
}
|
19769
20197
|
catch (e) {
|
19770
20198
|
span.setStatus({
|
19771
20199
|
code: coreTracing.SpanStatusCode.ERROR,
|
19772
|
-
message: e.message
|
20200
|
+
message: e.message,
|
19773
20201
|
});
|
19774
20202
|
throw e;
|
19775
20203
|
}
|
@@ -19810,7 +20238,7 @@ class BlobClient extends StorageClient {
|
|
19810
20238
|
catch (e) {
|
19811
20239
|
span.setStatus({
|
19812
20240
|
code: coreTracing.SpanStatusCode.ERROR,
|
19813
|
-
message: e.message
|
20241
|
+
message: e.message,
|
19814
20242
|
});
|
19815
20243
|
throw e;
|
19816
20244
|
}
|
@@ -19831,7 +20259,7 @@ class BlobClient extends StorageClient {
|
|
19831
20259
|
catch (e) {
|
19832
20260
|
span.setStatus({
|
19833
20261
|
code: coreTracing.SpanStatusCode.ERROR,
|
19834
|
-
message: e.message
|
20262
|
+
message: e.message,
|
19835
20263
|
});
|
19836
20264
|
throw e;
|
19837
20265
|
}
|
@@ -19852,7 +20280,7 @@ class BlobClient extends StorageClient {
|
|
19852
20280
|
catch (e) {
|
19853
20281
|
span.setStatus({
|
19854
20282
|
code: coreTracing.SpanStatusCode.ERROR,
|
19855
|
-
message: e.message
|
20283
|
+
message: e.message,
|
19856
20284
|
});
|
19857
20285
|
throw e;
|
19858
20286
|
}
|
@@ -19903,12 +20331,17 @@ class AppendBlobClient extends BlobClient {
|
|
19903
20331
|
const blobName = blobNameOrOptions;
|
19904
20332
|
const extractedCreds = extractConnectionStringParts(urlOrConnectionString);
|
19905
20333
|
if (extractedCreds.kind === "AccountConnString") {
|
19906
|
-
{
|
20334
|
+
if (coreHttp.isNode) {
|
19907
20335
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
19908
20336
|
url = appendToURLPath(appendToURLPath(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
19909
|
-
options.proxyOptions
|
20337
|
+
if (!options.proxyOptions) {
|
20338
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
20339
|
+
}
|
19910
20340
|
pipeline = newPipeline(sharedKeyCredential, options);
|
19911
20341
|
}
|
20342
|
+
else {
|
20343
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
20344
|
+
}
|
19912
20345
|
}
|
19913
20346
|
else if (extractedCreds.kind === "SASConnString") {
|
19914
20347
|
url =
|
@@ -19963,7 +20396,7 @@ class AppendBlobClient extends BlobClient {
|
|
19963
20396
|
catch (e) {
|
19964
20397
|
span.setStatus({
|
19965
20398
|
code: coreTracing.SpanStatusCode.ERROR,
|
19966
|
-
message: e.message
|
20399
|
+
message: e.message,
|
19967
20400
|
});
|
19968
20401
|
throw e;
|
19969
20402
|
}
|
@@ -19984,20 +20417,19 @@ class AppendBlobClient extends BlobClient {
|
|
19984
20417
|
const conditions = { ifNoneMatch: ETagAny };
|
19985
20418
|
try {
|
19986
20419
|
const res = await this.create(Object.assign(Object.assign({}, updatedOptions), { conditions }));
|
19987
|
-
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response
|
19988
|
-
});
|
20420
|
+
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response });
|
19989
20421
|
}
|
19990
20422
|
catch (e) {
|
19991
20423
|
if (((_a = e.details) === null || _a === void 0 ? void 0 : _a.errorCode) === "BlobAlreadyExists") {
|
19992
20424
|
span.setStatus({
|
19993
20425
|
code: coreTracing.SpanStatusCode.ERROR,
|
19994
|
-
message: "Expected exception when creating a blob only if it does not already exist."
|
20426
|
+
message: "Expected exception when creating a blob only if it does not already exist.",
|
19995
20427
|
});
|
19996
20428
|
return Object.assign(Object.assign({ succeeded: false }, (_b = e.response) === null || _b === void 0 ? void 0 : _b.parsedHeaders), { _response: e.response });
|
19997
20429
|
}
|
19998
20430
|
span.setStatus({
|
19999
20431
|
code: coreTracing.SpanStatusCode.ERROR,
|
20000
|
-
message: e.message
|
20432
|
+
message: e.message,
|
20001
20433
|
});
|
20002
20434
|
throw e;
|
20003
20435
|
}
|
@@ -20020,7 +20452,7 @@ class AppendBlobClient extends BlobClient {
|
|
20020
20452
|
catch (e) {
|
20021
20453
|
span.setStatus({
|
20022
20454
|
code: coreTracing.SpanStatusCode.ERROR,
|
20023
|
-
message: e.message
|
20455
|
+
message: e.message,
|
20024
20456
|
});
|
20025
20457
|
throw e;
|
20026
20458
|
}
|
@@ -20059,13 +20491,13 @@ class AppendBlobClient extends BlobClient {
|
|
20059
20491
|
try {
|
20060
20492
|
ensureCpkIfSpecified(options.customerProvidedKey, this.isHttps);
|
20061
20493
|
return await this.appendBlobContext.appendBlock(contentLength, body, Object.assign({ abortSignal: options.abortSignal, appendPositionAccessConditions: options.conditions, leaseAccessConditions: options.conditions, modifiedAccessConditions: Object.assign(Object.assign({}, options.conditions), { ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions }), requestOptions: {
|
20062
|
-
onUploadProgress: options.onProgress
|
20494
|
+
onUploadProgress: options.onProgress,
|
20063
20495
|
}, transactionalContentMD5: options.transactionalContentMD5, transactionalContentCrc64: options.transactionalContentCrc64, cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20064
20496
|
}
|
20065
20497
|
catch (e) {
|
20066
20498
|
span.setStatus({
|
20067
20499
|
code: coreTracing.SpanStatusCode.ERROR,
|
20068
|
-
message: e.message
|
20500
|
+
message: e.message,
|
20069
20501
|
});
|
20070
20502
|
throw e;
|
20071
20503
|
}
|
@@ -20098,13 +20530,13 @@ class AppendBlobClient extends BlobClient {
|
|
20098
20530
|
sourceIfMatch: options.sourceConditions.ifMatch,
|
20099
20531
|
sourceIfModifiedSince: options.sourceConditions.ifModifiedSince,
|
20100
20532
|
sourceIfNoneMatch: options.sourceConditions.ifNoneMatch,
|
20101
|
-
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince
|
20533
|
+
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince,
|
20102
20534
|
}, copySourceAuthorization: httpAuthorizationToString(options.sourceAuthorization), cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20103
20535
|
}
|
20104
20536
|
catch (e) {
|
20105
20537
|
span.setStatus({
|
20106
20538
|
code: coreTracing.SpanStatusCode.ERROR,
|
20107
|
-
message: e.message
|
20539
|
+
message: e.message,
|
20108
20540
|
});
|
20109
20541
|
throw e;
|
20110
20542
|
}
|
@@ -20155,12 +20587,17 @@ class BlockBlobClient extends BlobClient {
|
|
20155
20587
|
const blobName = blobNameOrOptions;
|
20156
20588
|
const extractedCreds = extractConnectionStringParts(urlOrConnectionString);
|
20157
20589
|
if (extractedCreds.kind === "AccountConnString") {
|
20158
|
-
{
|
20590
|
+
if (coreHttp.isNode) {
|
20159
20591
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
20160
20592
|
url = appendToURLPath(appendToURLPath(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
20161
|
-
options.proxyOptions
|
20593
|
+
if (!options.proxyOptions) {
|
20594
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
20595
|
+
}
|
20162
20596
|
pipeline = newPipeline(sharedKeyCredential, options);
|
20163
20597
|
}
|
20598
|
+
else {
|
20599
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
20600
|
+
}
|
20164
20601
|
}
|
20165
20602
|
else if (extractedCreds.kind === "SASConnString") {
|
20166
20603
|
url =
|
@@ -20226,25 +20663,25 @@ class BlockBlobClient extends BlobClient {
|
|
20226
20663
|
ensureCpkIfSpecified(options.customerProvidedKey, this.isHttps);
|
20227
20664
|
const { span, updatedOptions } = createSpan("BlockBlobClient-query", options);
|
20228
20665
|
try {
|
20229
|
-
if (
|
20666
|
+
if (!coreHttp.isNode) {
|
20230
20667
|
throw new Error("This operation currently is only supported in Node.js.");
|
20231
20668
|
}
|
20232
20669
|
const response = await this._blobContext.query(Object.assign({ abortSignal: options.abortSignal, queryRequest: {
|
20233
20670
|
queryType: "SQL",
|
20234
20671
|
expression: query,
|
20235
20672
|
inputSerialization: toQuerySerialization(options.inputTextConfiguration),
|
20236
|
-
outputSerialization: toQuerySerialization(options.outputTextConfiguration)
|
20673
|
+
outputSerialization: toQuerySerialization(options.outputTextConfiguration),
|
20237
20674
|
}, leaseAccessConditions: options.conditions, modifiedAccessConditions: Object.assign(Object.assign({}, options.conditions), { ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions }) }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20238
20675
|
return new BlobQueryResponse(response, {
|
20239
20676
|
abortSignal: options.abortSignal,
|
20240
20677
|
onProgress: options.onProgress,
|
20241
|
-
onError: options.onError
|
20678
|
+
onError: options.onError,
|
20242
20679
|
});
|
20243
20680
|
}
|
20244
20681
|
catch (e) {
|
20245
20682
|
span.setStatus({
|
20246
20683
|
code: coreTracing.SpanStatusCode.ERROR,
|
20247
|
-
message: e.message
|
20684
|
+
message: e.message,
|
20248
20685
|
});
|
20249
20686
|
throw e;
|
20250
20687
|
}
|
@@ -20286,13 +20723,13 @@ class BlockBlobClient extends BlobClient {
|
|
20286
20723
|
try {
|
20287
20724
|
ensureCpkIfSpecified(options.customerProvidedKey, this.isHttps);
|
20288
20725
|
return await this.blockBlobContext.upload(contentLength, body, Object.assign({ abortSignal: options.abortSignal, blobHttpHeaders: options.blobHTTPHeaders, leaseAccessConditions: options.conditions, metadata: options.metadata, modifiedAccessConditions: Object.assign(Object.assign({}, options.conditions), { ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions }), requestOptions: {
|
20289
|
-
onUploadProgress: options.onProgress
|
20726
|
+
onUploadProgress: options.onProgress,
|
20290
20727
|
}, cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope, immutabilityPolicyExpiry: (_b = options.immutabilityPolicy) === null || _b === void 0 ? void 0 : _b.expiriesOn, immutabilityPolicyMode: (_c = options.immutabilityPolicy) === null || _c === void 0 ? void 0 : _c.policyMode, legalHold: options.legalHold, tier: toAccessTier(options.tier), blobTagsString: toBlobTagsString(options.tags) }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20291
20728
|
}
|
20292
20729
|
catch (e) {
|
20293
20730
|
span.setStatus({
|
20294
20731
|
code: coreTracing.SpanStatusCode.ERROR,
|
20295
|
-
message: e.message
|
20732
|
+
message: e.message,
|
20296
20733
|
});
|
20297
20734
|
throw e;
|
20298
20735
|
}
|
@@ -20329,13 +20766,13 @@ class BlockBlobClient extends BlobClient {
|
|
20329
20766
|
sourceIfModifiedSince: (_b = options.sourceConditions) === null || _b === void 0 ? void 0 : _b.ifModifiedSince,
|
20330
20767
|
sourceIfNoneMatch: (_c = options.sourceConditions) === null || _c === void 0 ? void 0 : _c.ifNoneMatch,
|
20331
20768
|
sourceIfUnmodifiedSince: (_d = options.sourceConditions) === null || _d === void 0 ? void 0 : _d.ifUnmodifiedSince,
|
20332
|
-
sourceIfTags: (_e = options.sourceConditions) === null || _e === void 0 ? void 0 : _e.tagConditions
|
20769
|
+
sourceIfTags: (_e = options.sourceConditions) === null || _e === void 0 ? void 0 : _e.tagConditions,
|
20333
20770
|
}, cpkInfo: options.customerProvidedKey, copySourceAuthorization: httpAuthorizationToString(options.sourceAuthorization), tier: toAccessTier(options.tier), blobTagsString: toBlobTagsString(options.tags) }), convertTracingToRequestOptionsBase(updatedOptions)));
|
20334
20771
|
}
|
20335
20772
|
catch (e) {
|
20336
20773
|
span.setStatus({
|
20337
20774
|
code: coreTracing.SpanStatusCode.ERROR,
|
20338
|
-
message: e.message
|
20775
|
+
message: e.message,
|
20339
20776
|
});
|
20340
20777
|
throw e;
|
20341
20778
|
}
|
@@ -20359,13 +20796,13 @@ class BlockBlobClient extends BlobClient {
|
|
20359
20796
|
try {
|
20360
20797
|
ensureCpkIfSpecified(options.customerProvidedKey, this.isHttps);
|
20361
20798
|
return await this.blockBlobContext.stageBlock(blockId, contentLength, body, Object.assign({ abortSignal: options.abortSignal, leaseAccessConditions: options.conditions, requestOptions: {
|
20362
|
-
onUploadProgress: options.onProgress
|
20799
|
+
onUploadProgress: options.onProgress,
|
20363
20800
|
}, transactionalContentMD5: options.transactionalContentMD5, transactionalContentCrc64: options.transactionalContentCrc64, cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20364
20801
|
}
|
20365
20802
|
catch (e) {
|
20366
20803
|
span.setStatus({
|
20367
20804
|
code: coreTracing.SpanStatusCode.ERROR,
|
20368
|
-
message: e.message
|
20805
|
+
message: e.message,
|
20369
20806
|
});
|
20370
20807
|
throw e;
|
20371
20808
|
}
|
@@ -20403,7 +20840,7 @@ class BlockBlobClient extends BlobClient {
|
|
20403
20840
|
catch (e) {
|
20404
20841
|
span.setStatus({
|
20405
20842
|
code: coreTracing.SpanStatusCode.ERROR,
|
20406
|
-
message: e.message
|
20843
|
+
message: e.message,
|
20407
20844
|
});
|
20408
20845
|
throw e;
|
20409
20846
|
}
|
@@ -20434,7 +20871,7 @@ class BlockBlobClient extends BlobClient {
|
|
20434
20871
|
catch (e) {
|
20435
20872
|
span.setStatus({
|
20436
20873
|
code: coreTracing.SpanStatusCode.ERROR,
|
20437
|
-
message: e.message
|
20874
|
+
message: e.message,
|
20438
20875
|
});
|
20439
20876
|
throw e;
|
20440
20877
|
}
|
@@ -20468,7 +20905,7 @@ class BlockBlobClient extends BlobClient {
|
|
20468
20905
|
catch (e) {
|
20469
20906
|
span.setStatus({
|
20470
20907
|
code: coreTracing.SpanStatusCode.ERROR,
|
20471
|
-
message: e.message
|
20908
|
+
message: e.message,
|
20472
20909
|
});
|
20473
20910
|
throw e;
|
20474
20911
|
}
|
@@ -20495,7 +20932,7 @@ class BlockBlobClient extends BlobClient {
|
|
20495
20932
|
async uploadData(data, options = {}) {
|
20496
20933
|
const { span, updatedOptions } = createSpan("BlockBlobClient-uploadData", options);
|
20497
20934
|
try {
|
20498
|
-
if (
|
20935
|
+
if (coreHttp.isNode) {
|
20499
20936
|
let buffer;
|
20500
20937
|
if (data instanceof Buffer) {
|
20501
20938
|
buffer = data;
|
@@ -20517,7 +20954,7 @@ class BlockBlobClient extends BlobClient {
|
|
20517
20954
|
catch (e) {
|
20518
20955
|
span.setStatus({
|
20519
20956
|
code: coreTracing.SpanStatusCode.ERROR,
|
20520
|
-
message: e.message
|
20957
|
+
message: e.message,
|
20521
20958
|
});
|
20522
20959
|
throw e;
|
20523
20960
|
}
|
@@ -20553,7 +20990,7 @@ class BlockBlobClient extends BlobClient {
|
|
20553
20990
|
catch (e) {
|
20554
20991
|
span.setStatus({
|
20555
20992
|
code: coreTracing.SpanStatusCode.ERROR,
|
20556
|
-
message: e.message
|
20993
|
+
message: e.message,
|
20557
20994
|
});
|
20558
20995
|
throw e;
|
20559
20996
|
}
|
@@ -20632,14 +21069,14 @@ class BlockBlobClient extends BlobClient {
|
|
20632
21069
|
abortSignal: options.abortSignal,
|
20633
21070
|
conditions: options.conditions,
|
20634
21071
|
encryptionScope: options.encryptionScope,
|
20635
|
-
tracingOptions: updatedOptions.tracingOptions
|
21072
|
+
tracingOptions: updatedOptions.tracingOptions,
|
20636
21073
|
});
|
20637
21074
|
// Update progress after block is successfully uploaded to server, in case of block trying
|
20638
21075
|
// TODO: Hook with convenience layer progress event in finer level
|
20639
21076
|
transferProgress += contentLength;
|
20640
21077
|
if (options.onProgress) {
|
20641
21078
|
options.onProgress({
|
20642
|
-
loadedBytes: transferProgress
|
21079
|
+
loadedBytes: transferProgress,
|
20643
21080
|
});
|
20644
21081
|
}
|
20645
21082
|
});
|
@@ -20650,7 +21087,7 @@ class BlockBlobClient extends BlobClient {
|
|
20650
21087
|
catch (e) {
|
20651
21088
|
span.setStatus({
|
20652
21089
|
code: coreTracing.SpanStatusCode.ERROR,
|
20653
|
-
message: e.message
|
21090
|
+
message: e.message,
|
20654
21091
|
});
|
20655
21092
|
throw e;
|
20656
21093
|
}
|
@@ -20679,14 +21116,14 @@ class BlockBlobClient extends BlobClient {
|
|
20679
21116
|
return () => fsCreateReadStream(filePath, {
|
20680
21117
|
autoClose: true,
|
20681
21118
|
end: count ? offset + count - 1 : Infinity,
|
20682
|
-
start: offset
|
21119
|
+
start: offset,
|
20683
21120
|
});
|
20684
21121
|
}, size, Object.assign(Object.assign({}, options), { tracingOptions: Object.assign(Object.assign({}, options.tracingOptions), convertTracingToRequestOptionsBase(updatedOptions)) }));
|
20685
21122
|
}
|
20686
21123
|
catch (e) {
|
20687
21124
|
span.setStatus({
|
20688
21125
|
code: coreTracing.SpanStatusCode.ERROR,
|
20689
|
-
message: e.message
|
21126
|
+
message: e.message,
|
20690
21127
|
});
|
20691
21128
|
throw e;
|
20692
21129
|
}
|
@@ -20730,7 +21167,7 @@ class BlockBlobClient extends BlobClient {
|
|
20730
21167
|
await this.stageBlock(blockID, body, length, {
|
20731
21168
|
conditions: options.conditions,
|
20732
21169
|
encryptionScope: options.encryptionScope,
|
20733
|
-
tracingOptions: updatedOptions.tracingOptions
|
21170
|
+
tracingOptions: updatedOptions.tracingOptions,
|
20734
21171
|
});
|
20735
21172
|
// Update progress after block is successfully uploaded to server, in case of block trying
|
20736
21173
|
transferProgress += length;
|
@@ -20749,7 +21186,7 @@ class BlockBlobClient extends BlobClient {
|
|
20749
21186
|
catch (e) {
|
20750
21187
|
span.setStatus({
|
20751
21188
|
code: coreTracing.SpanStatusCode.ERROR,
|
20752
|
-
message: e.message
|
21189
|
+
message: e.message,
|
20753
21190
|
});
|
20754
21191
|
throw e;
|
20755
21192
|
}
|
@@ -20800,12 +21237,17 @@ class PageBlobClient extends BlobClient {
|
|
20800
21237
|
const blobName = blobNameOrOptions;
|
20801
21238
|
const extractedCreds = extractConnectionStringParts(urlOrConnectionString);
|
20802
21239
|
if (extractedCreds.kind === "AccountConnString") {
|
20803
|
-
{
|
21240
|
+
if (coreHttp.isNode) {
|
20804
21241
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
20805
21242
|
url = appendToURLPath(appendToURLPath(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
20806
|
-
options.proxyOptions
|
21243
|
+
if (!options.proxyOptions) {
|
21244
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
21245
|
+
}
|
20807
21246
|
pipeline = newPipeline(sharedKeyCredential, options);
|
20808
21247
|
}
|
21248
|
+
else {
|
21249
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
21250
|
+
}
|
20809
21251
|
}
|
20810
21252
|
else if (extractedCreds.kind === "SASConnString") {
|
20811
21253
|
url =
|
@@ -20855,7 +21297,7 @@ class PageBlobClient extends BlobClient {
|
|
20855
21297
|
catch (e) {
|
20856
21298
|
span.setStatus({
|
20857
21299
|
code: coreTracing.SpanStatusCode.ERROR,
|
20858
|
-
message: e.message
|
21300
|
+
message: e.message,
|
20859
21301
|
});
|
20860
21302
|
throw e;
|
20861
21303
|
}
|
@@ -20878,20 +21320,19 @@ class PageBlobClient extends BlobClient {
|
|
20878
21320
|
try {
|
20879
21321
|
const conditions = { ifNoneMatch: ETagAny };
|
20880
21322
|
const res = await this.create(size, Object.assign(Object.assign({}, options), { conditions, tracingOptions: updatedOptions.tracingOptions }));
|
20881
|
-
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response
|
20882
|
-
});
|
21323
|
+
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response });
|
20883
21324
|
}
|
20884
21325
|
catch (e) {
|
20885
21326
|
if (((_a = e.details) === null || _a === void 0 ? void 0 : _a.errorCode) === "BlobAlreadyExists") {
|
20886
21327
|
span.setStatus({
|
20887
21328
|
code: coreTracing.SpanStatusCode.ERROR,
|
20888
|
-
message: "Expected exception when creating a blob only if it does not already exist."
|
21329
|
+
message: "Expected exception when creating a blob only if it does not already exist.",
|
20889
21330
|
});
|
20890
21331
|
return Object.assign(Object.assign({ succeeded: false }, (_b = e.response) === null || _b === void 0 ? void 0 : _b.parsedHeaders), { _response: e.response });
|
20891
21332
|
}
|
20892
21333
|
span.setStatus({
|
20893
21334
|
code: coreTracing.SpanStatusCode.ERROR,
|
20894
|
-
message: e.message
|
21335
|
+
message: e.message,
|
20895
21336
|
});
|
20896
21337
|
throw e;
|
20897
21338
|
}
|
@@ -20916,13 +21357,13 @@ class PageBlobClient extends BlobClient {
|
|
20916
21357
|
try {
|
20917
21358
|
ensureCpkIfSpecified(options.customerProvidedKey, this.isHttps);
|
20918
21359
|
return await this.pageBlobContext.uploadPages(count, body, Object.assign({ abortSignal: options.abortSignal, leaseAccessConditions: options.conditions, modifiedAccessConditions: Object.assign(Object.assign({}, options.conditions), { ifTags: (_a = options.conditions) === null || _a === void 0 ? void 0 : _a.tagConditions }), requestOptions: {
|
20919
|
-
onUploadProgress: options.onProgress
|
21360
|
+
onUploadProgress: options.onProgress,
|
20920
21361
|
}, range: rangeToString({ offset, count }), sequenceNumberAccessConditions: options.conditions, transactionalContentMD5: options.transactionalContentMD5, transactionalContentCrc64: options.transactionalContentCrc64, cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20921
21362
|
}
|
20922
21363
|
catch (e) {
|
20923
21364
|
span.setStatus({
|
20924
21365
|
code: coreTracing.SpanStatusCode.ERROR,
|
20925
|
-
message: e.message
|
21366
|
+
message: e.message,
|
20926
21367
|
});
|
20927
21368
|
throw e;
|
20928
21369
|
}
|
@@ -20952,13 +21393,13 @@ class PageBlobClient extends BlobClient {
|
|
20952
21393
|
sourceIfMatch: options.sourceConditions.ifMatch,
|
20953
21394
|
sourceIfModifiedSince: options.sourceConditions.ifModifiedSince,
|
20954
21395
|
sourceIfNoneMatch: options.sourceConditions.ifNoneMatch,
|
20955
|
-
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince
|
21396
|
+
sourceIfUnmodifiedSince: options.sourceConditions.ifUnmodifiedSince,
|
20956
21397
|
}, cpkInfo: options.customerProvidedKey, encryptionScope: options.encryptionScope, copySourceAuthorization: httpAuthorizationToString(options.sourceAuthorization) }, convertTracingToRequestOptionsBase(updatedOptions)));
|
20957
21398
|
}
|
20958
21399
|
catch (e) {
|
20959
21400
|
span.setStatus({
|
20960
21401
|
code: coreTracing.SpanStatusCode.ERROR,
|
20961
|
-
message: e.message
|
21402
|
+
message: e.message,
|
20962
21403
|
});
|
20963
21404
|
throw e;
|
20964
21405
|
}
|
@@ -20985,7 +21426,7 @@ class PageBlobClient extends BlobClient {
|
|
20985
21426
|
catch (e) {
|
20986
21427
|
span.setStatus({
|
20987
21428
|
code: coreTracing.SpanStatusCode.ERROR,
|
20988
|
-
message: e.message
|
21429
|
+
message: e.message,
|
20989
21430
|
});
|
20990
21431
|
throw e;
|
20991
21432
|
}
|
@@ -21014,7 +21455,7 @@ class PageBlobClient extends BlobClient {
|
|
21014
21455
|
catch (e) {
|
21015
21456
|
span.setStatus({
|
21016
21457
|
code: coreTracing.SpanStatusCode.ERROR,
|
21017
|
-
message: e.message
|
21458
|
+
message: e.message,
|
21018
21459
|
});
|
21019
21460
|
throw e;
|
21020
21461
|
}
|
@@ -21044,7 +21485,7 @@ class PageBlobClient extends BlobClient {
|
|
21044
21485
|
catch (e) {
|
21045
21486
|
span.setStatus({
|
21046
21487
|
code: coreTracing.SpanStatusCode.ERROR,
|
21047
|
-
message: e.message
|
21488
|
+
message: e.message,
|
21048
21489
|
});
|
21049
21490
|
throw e;
|
21050
21491
|
}
|
@@ -21074,7 +21515,7 @@ class PageBlobClient extends BlobClient {
|
|
21074
21515
|
catch (e) {
|
21075
21516
|
span.setStatus({
|
21076
21517
|
code: coreTracing.SpanStatusCode.ERROR,
|
21077
|
-
message: e.message
|
21518
|
+
message: e.message,
|
21078
21519
|
});
|
21079
21520
|
throw e;
|
21080
21521
|
}
|
@@ -21100,7 +21541,7 @@ class PageBlobClient extends BlobClient {
|
|
21100
21541
|
catch (e) {
|
21101
21542
|
span.setStatus({
|
21102
21543
|
code: coreTracing.SpanStatusCode.ERROR,
|
21103
|
-
message: e.message
|
21544
|
+
message: e.message,
|
21104
21545
|
});
|
21105
21546
|
throw e;
|
21106
21547
|
}
|
@@ -21127,7 +21568,7 @@ class PageBlobClient extends BlobClient {
|
|
21127
21568
|
catch (e) {
|
21128
21569
|
span.setStatus({
|
21129
21570
|
code: coreTracing.SpanStatusCode.ERROR,
|
21130
|
-
message: e.message
|
21571
|
+
message: e.message,
|
21131
21572
|
});
|
21132
21573
|
throw e;
|
21133
21574
|
}
|
@@ -21157,7 +21598,7 @@ class PageBlobClient extends BlobClient {
|
|
21157
21598
|
catch (e) {
|
21158
21599
|
span.setStatus({
|
21159
21600
|
code: coreTracing.SpanStatusCode.ERROR,
|
21160
|
-
message: e.message
|
21601
|
+
message: e.message,
|
21161
21602
|
});
|
21162
21603
|
throw e;
|
21163
21604
|
}
|
@@ -21305,7 +21746,7 @@ class BatchResponseParser {
|
|
21305
21746
|
return {
|
21306
21747
|
subResponses: deserializedSubResponses,
|
21307
21748
|
subResponsesSucceededCount: subResponsesSucceededCount,
|
21308
|
-
subResponsesFailedCount: subResponsesFailedCount
|
21749
|
+
subResponsesFailedCount: subResponsesFailedCount,
|
21309
21750
|
};
|
21310
21751
|
}
|
21311
21752
|
}
|
@@ -21452,7 +21893,7 @@ class BlobBatch {
|
|
21452
21893
|
this.setBatchType("delete");
|
21453
21894
|
await this.addSubRequestInternal({
|
21454
21895
|
url: url,
|
21455
|
-
credential: credential
|
21896
|
+
credential: credential,
|
21456
21897
|
}, async () => {
|
21457
21898
|
await new BlobClient(url, this.batchRequest.createPipeline(credential)).delete(updatedOptions);
|
21458
21899
|
});
|
@@ -21460,7 +21901,7 @@ class BlobBatch {
|
|
21460
21901
|
catch (e) {
|
21461
21902
|
span.setStatus({
|
21462
21903
|
code: coreTracing.SpanStatusCode.ERROR,
|
21463
|
-
message: e.message
|
21904
|
+
message: e.message,
|
21464
21905
|
});
|
21465
21906
|
throw e;
|
21466
21907
|
}
|
@@ -21499,7 +21940,7 @@ class BlobBatch {
|
|
21499
21940
|
this.setBatchType("setAccessTier");
|
21500
21941
|
await this.addSubRequestInternal({
|
21501
21942
|
url: url,
|
21502
|
-
credential: credential
|
21943
|
+
credential: credential,
|
21503
21944
|
}, async () => {
|
21504
21945
|
await new BlobClient(url, this.batchRequest.createPipeline(credential)).setAccessTier(tier, updatedOptions);
|
21505
21946
|
});
|
@@ -21507,7 +21948,7 @@ class BlobBatch {
|
|
21507
21948
|
catch (e) {
|
21508
21949
|
span.setStatus({
|
21509
21950
|
code: coreTracing.SpanStatusCode.ERROR,
|
21510
|
-
message: e.message
|
21951
|
+
message: e.message,
|
21511
21952
|
});
|
21512
21953
|
throw e;
|
21513
21954
|
}
|
@@ -21564,7 +22005,7 @@ class InnerBatchRequest {
|
|
21564
22005
|
this.subRequestPrefix,
|
21565
22006
|
`${HeaderConstants.CONTENT_ID}: ${this.operationCount}`,
|
21566
22007
|
"",
|
21567
|
-
`${request.method.toString()} ${getURLPathAndQuery(request.url)} ${HTTP_VERSION_1_1}${HTTP_LINE_ENDING}
|
22008
|
+
`${request.method.toString()} ${getURLPathAndQuery(request.url)} ${HTTP_VERSION_1_1}${HTTP_LINE_ENDING}`, // sub request start line with method
|
21568
22009
|
].join(HTTP_LINE_ENDING);
|
21569
22010
|
for (const header of request.headers.headersArray()) {
|
21570
22011
|
this.body += `${header.name}: ${header.value}${HTTP_LINE_ENDING}`;
|
@@ -21604,7 +22045,7 @@ class BatchRequestAssemblePolicy extends coreHttp.BaseRequestPolicy {
|
|
21604
22045
|
this.dummyResponse = {
|
21605
22046
|
request: new coreHttp.WebResource(),
|
21606
22047
|
status: 200,
|
21607
|
-
headers: new coreHttp.HttpHeaders()
|
22048
|
+
headers: new coreHttp.HttpHeaders(),
|
21608
22049
|
};
|
21609
22050
|
this.batchRequest = batchRequest;
|
21610
22051
|
}
|
@@ -21771,14 +22212,14 @@ class BlobBatchClient {
|
|
21771
22212
|
version: rawBatchResponse.version,
|
21772
22213
|
subResponses: responseSummary.subResponses,
|
21773
22214
|
subResponsesSucceededCount: responseSummary.subResponsesSucceededCount,
|
21774
|
-
subResponsesFailedCount: responseSummary.subResponsesFailedCount
|
22215
|
+
subResponsesFailedCount: responseSummary.subResponsesFailedCount,
|
21775
22216
|
};
|
21776
22217
|
return res;
|
21777
22218
|
}
|
21778
22219
|
catch (e) {
|
21779
22220
|
span.setStatus({
|
21780
22221
|
code: coreTracing.SpanStatusCode.ERROR,
|
21781
|
-
message: e.message
|
22222
|
+
message: e.message,
|
21782
22223
|
});
|
21783
22224
|
throw e;
|
21784
22225
|
}
|
@@ -21824,12 +22265,17 @@ class ContainerClient extends StorageClient {
|
|
21824
22265
|
const containerName = credentialOrPipelineOrContainerName;
|
21825
22266
|
const extractedCreds = extractConnectionStringParts(urlOrConnectionString);
|
21826
22267
|
if (extractedCreds.kind === "AccountConnString") {
|
21827
|
-
{
|
22268
|
+
if (coreHttp.isNode) {
|
21828
22269
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
21829
22270
|
url = appendToURLPath(extractedCreds.url, encodeURIComponent(containerName));
|
21830
|
-
options.proxyOptions
|
22271
|
+
if (!options.proxyOptions) {
|
22272
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
22273
|
+
}
|
21831
22274
|
pipeline = newPipeline(sharedKeyCredential, options);
|
21832
22275
|
}
|
22276
|
+
else {
|
22277
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
22278
|
+
}
|
21833
22279
|
}
|
21834
22280
|
else if (extractedCreds.kind === "SASConnString") {
|
21835
22281
|
url =
|
@@ -21881,7 +22327,7 @@ class ContainerClient extends StorageClient {
|
|
21881
22327
|
catch (e) {
|
21882
22328
|
span.setStatus({
|
21883
22329
|
code: coreTracing.SpanStatusCode.ERROR,
|
21884
|
-
message: e.message
|
22330
|
+
message: e.message,
|
21885
22331
|
});
|
21886
22332
|
throw e;
|
21887
22333
|
}
|
@@ -21901,20 +22347,19 @@ class ContainerClient extends StorageClient {
|
|
21901
22347
|
const { span, updatedOptions } = createSpan("ContainerClient-createIfNotExists", options);
|
21902
22348
|
try {
|
21903
22349
|
const res = await this.create(updatedOptions);
|
21904
|
-
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response
|
21905
|
-
});
|
22350
|
+
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response });
|
21906
22351
|
}
|
21907
22352
|
catch (e) {
|
21908
22353
|
if (((_a = e.details) === null || _a === void 0 ? void 0 : _a.errorCode) === "ContainerAlreadyExists") {
|
21909
22354
|
span.setStatus({
|
21910
22355
|
code: coreTracing.SpanStatusCode.ERROR,
|
21911
|
-
message: "Expected exception when creating a container only if it does not already exist."
|
22356
|
+
message: "Expected exception when creating a container only if it does not already exist.",
|
21912
22357
|
});
|
21913
22358
|
return Object.assign(Object.assign({ succeeded: false }, (_b = e.response) === null || _b === void 0 ? void 0 : _b.parsedHeaders), { _response: e.response });
|
21914
22359
|
}
|
21915
22360
|
span.setStatus({
|
21916
22361
|
code: coreTracing.SpanStatusCode.ERROR,
|
21917
|
-
message: e.message
|
22362
|
+
message: e.message,
|
21918
22363
|
});
|
21919
22364
|
throw e;
|
21920
22365
|
}
|
@@ -21936,7 +22381,7 @@ class ContainerClient extends StorageClient {
|
|
21936
22381
|
try {
|
21937
22382
|
await this.getProperties({
|
21938
22383
|
abortSignal: options.abortSignal,
|
21939
|
-
tracingOptions: updatedOptions.tracingOptions
|
22384
|
+
tracingOptions: updatedOptions.tracingOptions,
|
21940
22385
|
});
|
21941
22386
|
return true;
|
21942
22387
|
}
|
@@ -21944,13 +22389,13 @@ class ContainerClient extends StorageClient {
|
|
21944
22389
|
if (e.statusCode === 404) {
|
21945
22390
|
span.setStatus({
|
21946
22391
|
code: coreTracing.SpanStatusCode.ERROR,
|
21947
|
-
message: "Expected exception when checking container existence"
|
22392
|
+
message: "Expected exception when checking container existence",
|
21948
22393
|
});
|
21949
22394
|
return false;
|
21950
22395
|
}
|
21951
22396
|
span.setStatus({
|
21952
22397
|
code: coreTracing.SpanStatusCode.ERROR,
|
21953
|
-
message: e.message
|
22398
|
+
message: e.message,
|
21954
22399
|
});
|
21955
22400
|
throw e;
|
21956
22401
|
}
|
@@ -22024,7 +22469,7 @@ class ContainerClient extends StorageClient {
|
|
22024
22469
|
catch (e) {
|
22025
22470
|
span.setStatus({
|
22026
22471
|
code: coreTracing.SpanStatusCode.ERROR,
|
22027
|
-
message: e.message
|
22472
|
+
message: e.message,
|
22028
22473
|
});
|
22029
22474
|
throw e;
|
22030
22475
|
}
|
@@ -22050,7 +22495,7 @@ class ContainerClient extends StorageClient {
|
|
22050
22495
|
catch (e) {
|
22051
22496
|
span.setStatus({
|
22052
22497
|
code: coreTracing.SpanStatusCode.ERROR,
|
22053
|
-
message: e.message
|
22498
|
+
message: e.message,
|
22054
22499
|
});
|
22055
22500
|
throw e;
|
22056
22501
|
}
|
@@ -22070,20 +22515,19 @@ class ContainerClient extends StorageClient {
|
|
22070
22515
|
const { span, updatedOptions } = createSpan("ContainerClient-deleteIfExists", options);
|
22071
22516
|
try {
|
22072
22517
|
const res = await this.delete(updatedOptions);
|
22073
|
-
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response
|
22074
|
-
});
|
22518
|
+
return Object.assign(Object.assign({ succeeded: true }, res), { _response: res._response });
|
22075
22519
|
}
|
22076
22520
|
catch (e) {
|
22077
22521
|
if (((_a = e.details) === null || _a === void 0 ? void 0 : _a.errorCode) === "ContainerNotFound") {
|
22078
22522
|
span.setStatus({
|
22079
22523
|
code: coreTracing.SpanStatusCode.ERROR,
|
22080
|
-
message: "Expected exception when deleting a container only if it exists."
|
22524
|
+
message: "Expected exception when deleting a container only if it exists.",
|
22081
22525
|
});
|
22082
22526
|
return Object.assign(Object.assign({ succeeded: false }, (_b = e.response) === null || _b === void 0 ? void 0 : _b.parsedHeaders), { _response: e.response });
|
22083
22527
|
}
|
22084
22528
|
span.setStatus({
|
22085
22529
|
code: coreTracing.SpanStatusCode.ERROR,
|
22086
|
-
message: e.message
|
22530
|
+
message: e.message,
|
22087
22531
|
});
|
22088
22532
|
throw e;
|
22089
22533
|
}
|
@@ -22117,7 +22561,7 @@ class ContainerClient extends StorageClient {
|
|
22117
22561
|
catch (e) {
|
22118
22562
|
span.setStatus({
|
22119
22563
|
code: coreTracing.SpanStatusCode.ERROR,
|
22120
|
-
message: e.message
|
22564
|
+
message: e.message,
|
22121
22565
|
});
|
22122
22566
|
throw e;
|
22123
22567
|
}
|
@@ -22153,13 +22597,13 @@ class ContainerClient extends StorageClient {
|
|
22153
22597
|
requestId: response.requestId,
|
22154
22598
|
clientRequestId: response.clientRequestId,
|
22155
22599
|
signedIdentifiers: [],
|
22156
|
-
version: response.version
|
22600
|
+
version: response.version,
|
22157
22601
|
};
|
22158
22602
|
for (const identifier of response) {
|
22159
22603
|
let accessPolicy = undefined;
|
22160
22604
|
if (identifier.accessPolicy) {
|
22161
22605
|
accessPolicy = {
|
22162
|
-
permissions: identifier.accessPolicy.permissions
|
22606
|
+
permissions: identifier.accessPolicy.permissions,
|
22163
22607
|
};
|
22164
22608
|
if (identifier.accessPolicy.expiresOn) {
|
22165
22609
|
accessPolicy.expiresOn = new Date(identifier.accessPolicy.expiresOn);
|
@@ -22170,7 +22614,7 @@ class ContainerClient extends StorageClient {
|
|
22170
22614
|
}
|
22171
22615
|
res.signedIdentifiers.push({
|
22172
22616
|
accessPolicy,
|
22173
|
-
id: identifier.id
|
22617
|
+
id: identifier.id,
|
22174
22618
|
});
|
22175
22619
|
}
|
22176
22620
|
return res;
|
@@ -22178,7 +22622,7 @@ class ContainerClient extends StorageClient {
|
|
22178
22622
|
catch (e) {
|
22179
22623
|
span.setStatus({
|
22180
22624
|
code: coreTracing.SpanStatusCode.ERROR,
|
22181
|
-
message: e.message
|
22625
|
+
message: e.message,
|
22182
22626
|
});
|
22183
22627
|
throw e;
|
22184
22628
|
}
|
@@ -22217,9 +22661,9 @@ class ContainerClient extends StorageClient {
|
|
22217
22661
|
permissions: identifier.accessPolicy.permissions,
|
22218
22662
|
startsOn: identifier.accessPolicy.startsOn
|
22219
22663
|
? truncatedISO8061Date(identifier.accessPolicy.startsOn)
|
22220
|
-
: ""
|
22664
|
+
: "",
|
22221
22665
|
},
|
22222
|
-
id: identifier.id
|
22666
|
+
id: identifier.id,
|
22223
22667
|
});
|
22224
22668
|
}
|
22225
22669
|
return await this.containerContext.setAccessPolicy(Object.assign({ abortSignal: options.abortSignal, access, containerAcl: acl, leaseAccessConditions: options.conditions, modifiedAccessConditions: options.conditions }, convertTracingToRequestOptionsBase(updatedOptions)));
|
@@ -22227,7 +22671,7 @@ class ContainerClient extends StorageClient {
|
|
22227
22671
|
catch (e) {
|
22228
22672
|
span.setStatus({
|
22229
22673
|
code: coreTracing.SpanStatusCode.ERROR,
|
22230
|
-
message: e.message
|
22674
|
+
message: e.message,
|
22231
22675
|
});
|
22232
22676
|
throw e;
|
22233
22677
|
}
|
@@ -22273,13 +22717,13 @@ class ContainerClient extends StorageClient {
|
|
22273
22717
|
const response = await blockBlobClient.upload(body, contentLength, updatedOptions);
|
22274
22718
|
return {
|
22275
22719
|
blockBlobClient,
|
22276
|
-
response
|
22720
|
+
response,
|
22277
22721
|
};
|
22278
22722
|
}
|
22279
22723
|
catch (e) {
|
22280
22724
|
span.setStatus({
|
22281
22725
|
code: coreTracing.SpanStatusCode.ERROR,
|
22282
|
-
message: e.message
|
22726
|
+
message: e.message,
|
22283
22727
|
});
|
22284
22728
|
throw e;
|
22285
22729
|
}
|
@@ -22310,7 +22754,7 @@ class ContainerClient extends StorageClient {
|
|
22310
22754
|
catch (e) {
|
22311
22755
|
span.setStatus({
|
22312
22756
|
code: coreTracing.SpanStatusCode.ERROR,
|
22313
|
-
message: e.message
|
22757
|
+
message: e.message,
|
22314
22758
|
});
|
22315
22759
|
throw e;
|
22316
22760
|
}
|
@@ -22345,7 +22789,7 @@ class ContainerClient extends StorageClient {
|
|
22345
22789
|
catch (e) {
|
22346
22790
|
span.setStatus({
|
22347
22791
|
code: coreTracing.SpanStatusCode.ERROR,
|
22348
|
-
message: e.message
|
22792
|
+
message: e.message,
|
22349
22793
|
});
|
22350
22794
|
throw e;
|
22351
22795
|
}
|
@@ -22382,7 +22826,7 @@ class ContainerClient extends StorageClient {
|
|
22382
22826
|
return blobItem;
|
22383
22827
|
}), blobPrefixes: (_a = response.segment.blobPrefixes) === null || _a === void 0 ? void 0 : _a.map((blobPrefixInternal) => {
|
22384
22828
|
const blobPrefix = {
|
22385
|
-
name: BlobNameToString(blobPrefixInternal.name)
|
22829
|
+
name: BlobNameToString(blobPrefixInternal.name),
|
22386
22830
|
};
|
22387
22831
|
return blobPrefix;
|
22388
22832
|
}) }) });
|
@@ -22391,7 +22835,7 @@ class ContainerClient extends StorageClient {
|
|
22391
22835
|
catch (e) {
|
22392
22836
|
span.setStatus({
|
22393
22837
|
code: coreTracing.SpanStatusCode.ERROR,
|
22394
|
-
message: e.message
|
22838
|
+
message: e.message,
|
22395
22839
|
});
|
22396
22840
|
throw e;
|
22397
22841
|
}
|
@@ -22573,7 +23017,7 @@ class ContainerClient extends StorageClient {
|
|
22573
23017
|
*/
|
22574
23018
|
byPage: (settings = {}) => {
|
22575
23019
|
return this.listSegments(settings.continuationToken, Object.assign({ maxPageSize: settings.maxPageSize }, updatedOptions));
|
22576
|
-
}
|
23020
|
+
},
|
22577
23021
|
};
|
22578
23022
|
}
|
22579
23023
|
/**
|
@@ -22647,7 +23091,7 @@ class ContainerClient extends StorageClient {
|
|
22647
23091
|
* if (item.kind === "prefix") {
|
22648
23092
|
* console.log(`\tBlobPrefix: ${item.name}`);
|
22649
23093
|
* } else {
|
22650
|
-
* console.log(`\tBlobItem: name - ${item.name}
|
23094
|
+
* console.log(`\tBlobItem: name - ${item.name}`);
|
22651
23095
|
* }
|
22652
23096
|
* }
|
22653
23097
|
* ```
|
@@ -22662,7 +23106,7 @@ class ContainerClient extends StorageClient {
|
|
22662
23106
|
* if (item.kind === "prefix") {
|
22663
23107
|
* console.log(`\tBlobPrefix: ${item.name}`);
|
22664
23108
|
* } else {
|
22665
|
-
* console.log(`\tBlobItem: name - ${item.name}
|
23109
|
+
* console.log(`\tBlobItem: name - ${item.name}`);
|
22666
23110
|
* }
|
22667
23111
|
* entity = await iter.next();
|
22668
23112
|
* }
|
@@ -22680,7 +23124,7 @@ class ContainerClient extends StorageClient {
|
|
22680
23124
|
* }
|
22681
23125
|
* }
|
22682
23126
|
* for (const blob of response.segment.blobItems) {
|
22683
|
-
* console.log(`\tBlobItem: name - ${blob.name}
|
23127
|
+
* console.log(`\tBlobItem: name - ${blob.name}`);
|
22684
23128
|
* }
|
22685
23129
|
* }
|
22686
23130
|
* ```
|
@@ -22691,7 +23135,9 @@ class ContainerClient extends StorageClient {
|
|
22691
23135
|
* console.log("Listing blobs by hierarchy by page, specifying a prefix and a max page size");
|
22692
23136
|
*
|
22693
23137
|
* let i = 1;
|
22694
|
-
* for await (const response of containerClient
|
23138
|
+
* for await (const response of containerClient
|
23139
|
+
* .listBlobsByHierarchy("/", { prefix: "prefix2/sub1/" })
|
23140
|
+
* .byPage({ maxPageSize: 2 })) {
|
22695
23141
|
* console.log(`Page ${i++}`);
|
22696
23142
|
* const segment = response.segment;
|
22697
23143
|
*
|
@@ -22702,7 +23148,7 @@ class ContainerClient extends StorageClient {
|
|
22702
23148
|
* }
|
22703
23149
|
*
|
22704
23150
|
* for (const blob of response.segment.blobItems) {
|
22705
|
-
* console.log(`\tBlobItem: name - ${blob.name}
|
23151
|
+
* console.log(`\tBlobItem: name - ${blob.name}`);
|
22706
23152
|
* }
|
22707
23153
|
* }
|
22708
23154
|
* ```
|
@@ -22769,7 +23215,208 @@ class ContainerClient extends StorageClient {
|
|
22769
23215
|
*/
|
22770
23216
|
byPage: (settings = {}) => {
|
22771
23217
|
return this.listHierarchySegments(delimiter, settings.continuationToken, Object.assign({ maxPageSize: settings.maxPageSize }, updatedOptions));
|
23218
|
+
},
|
23219
|
+
};
|
23220
|
+
}
|
23221
|
+
/**
|
23222
|
+
* The Filter Blobs operation enables callers to list blobs in the container whose tags
|
23223
|
+
* match a given search expression.
|
23224
|
+
*
|
23225
|
+
* @param tagFilterSqlExpression - The where parameter enables the caller to query blobs whose tags match a given expression.
|
23226
|
+
* The given expression must evaluate to true for a blob to be returned in the results.
|
23227
|
+
* The[OData - ABNF] filter syntax rule defines the formal grammar for the value of the where query parameter;
|
23228
|
+
* however, only a subset of the OData filter syntax is supported in the Blob service.
|
23229
|
+
* @param marker - A string value that identifies the portion of
|
23230
|
+
* the list of blobs to be returned with the next listing operation. The
|
23231
|
+
* operation returns the continuationToken value within the response body if the
|
23232
|
+
* listing operation did not return all blobs remaining to be listed
|
23233
|
+
* with the current page. The continuationToken value can be used as the value for
|
23234
|
+
* the marker parameter in a subsequent call to request the next page of list
|
23235
|
+
* items. The marker value is opaque to the client.
|
23236
|
+
* @param options - Options to find blobs by tags.
|
23237
|
+
*/
|
23238
|
+
async findBlobsByTagsSegment(tagFilterSqlExpression, marker, options = {}) {
|
23239
|
+
const { span, updatedOptions } = createSpan("ContainerClient-findBlobsByTagsSegment", options);
|
23240
|
+
try {
|
23241
|
+
const response = await this.containerContext.filterBlobs(Object.assign({ abortSignal: options.abortSignal, where: tagFilterSqlExpression, marker, maxPageSize: options.maxPageSize }, convertTracingToRequestOptionsBase(updatedOptions)));
|
23242
|
+
const wrappedResponse = Object.assign(Object.assign({}, response), { _response: response._response, blobs: response.blobs.map((blob) => {
|
23243
|
+
var _a;
|
23244
|
+
let tagValue = "";
|
23245
|
+
if (((_a = blob.tags) === null || _a === void 0 ? void 0 : _a.blobTagSet.length) === 1) {
|
23246
|
+
tagValue = blob.tags.blobTagSet[0].value;
|
23247
|
+
}
|
23248
|
+
return Object.assign(Object.assign({}, blob), { tags: toTags(blob.tags), tagValue });
|
23249
|
+
}) });
|
23250
|
+
return wrappedResponse;
|
23251
|
+
}
|
23252
|
+
catch (e) {
|
23253
|
+
span.setStatus({
|
23254
|
+
code: coreTracing.SpanStatusCode.ERROR,
|
23255
|
+
message: e.message,
|
23256
|
+
});
|
23257
|
+
throw e;
|
23258
|
+
}
|
23259
|
+
finally {
|
23260
|
+
span.end();
|
23261
|
+
}
|
23262
|
+
}
|
23263
|
+
/**
|
23264
|
+
* Returns an AsyncIterableIterator for ContainerFindBlobsByTagsSegmentResponse.
|
23265
|
+
*
|
23266
|
+
* @param tagFilterSqlExpression - The where parameter enables the caller to query blobs whose tags match a given expression.
|
23267
|
+
* The given expression must evaluate to true for a blob to be returned in the results.
|
23268
|
+
* The[OData - ABNF] filter syntax rule defines the formal grammar for the value of the where query parameter;
|
23269
|
+
* however, only a subset of the OData filter syntax is supported in the Blob service.
|
23270
|
+
* @param marker - A string value that identifies the portion of
|
23271
|
+
* the list of blobs to be returned with the next listing operation. The
|
23272
|
+
* operation returns the continuationToken value within the response body if the
|
23273
|
+
* listing operation did not return all blobs remaining to be listed
|
23274
|
+
* with the current page. The continuationToken value can be used as the value for
|
23275
|
+
* the marker parameter in a subsequent call to request the next page of list
|
23276
|
+
* items. The marker value is opaque to the client.
|
23277
|
+
* @param options - Options to find blobs by tags.
|
23278
|
+
*/
|
23279
|
+
findBlobsByTagsSegments(tagFilterSqlExpression, marker, options = {}) {
|
23280
|
+
return tslib.__asyncGenerator(this, arguments, function* findBlobsByTagsSegments_1() {
|
23281
|
+
let response;
|
23282
|
+
if (!!marker || marker === undefined) {
|
23283
|
+
do {
|
23284
|
+
response = yield tslib.__await(this.findBlobsByTagsSegment(tagFilterSqlExpression, marker, options));
|
23285
|
+
response.blobs = response.blobs || [];
|
23286
|
+
marker = response.continuationToken;
|
23287
|
+
yield yield tslib.__await(response);
|
23288
|
+
} while (marker);
|
22772
23289
|
}
|
23290
|
+
});
|
23291
|
+
}
|
23292
|
+
/**
|
23293
|
+
* Returns an AsyncIterableIterator for blobs.
|
23294
|
+
*
|
23295
|
+
* @param tagFilterSqlExpression - The where parameter enables the caller to query blobs whose tags match a given expression.
|
23296
|
+
* The given expression must evaluate to true for a blob to be returned in the results.
|
23297
|
+
* The[OData - ABNF] filter syntax rule defines the formal grammar for the value of the where query parameter;
|
23298
|
+
* however, only a subset of the OData filter syntax is supported in the Blob service.
|
23299
|
+
* @param options - Options to findBlobsByTagsItems.
|
23300
|
+
*/
|
23301
|
+
findBlobsByTagsItems(tagFilterSqlExpression, options = {}) {
|
23302
|
+
return tslib.__asyncGenerator(this, arguments, function* findBlobsByTagsItems_1() {
|
23303
|
+
var e_3, _a;
|
23304
|
+
let marker;
|
23305
|
+
try {
|
23306
|
+
for (var _b = tslib.__asyncValues(this.findBlobsByTagsSegments(tagFilterSqlExpression, marker, options)), _c; _c = yield tslib.__await(_b.next()), !_c.done;) {
|
23307
|
+
const segment = _c.value;
|
23308
|
+
yield tslib.__await(yield* tslib.__asyncDelegator(tslib.__asyncValues(segment.blobs)));
|
23309
|
+
}
|
23310
|
+
}
|
23311
|
+
catch (e_3_1) { e_3 = { error: e_3_1 }; }
|
23312
|
+
finally {
|
23313
|
+
try {
|
23314
|
+
if (_c && !_c.done && (_a = _b.return)) yield tslib.__await(_a.call(_b));
|
23315
|
+
}
|
23316
|
+
finally { if (e_3) throw e_3.error; }
|
23317
|
+
}
|
23318
|
+
});
|
23319
|
+
}
|
23320
|
+
/**
|
23321
|
+
* Returns an async iterable iterator to find all blobs with specified tag
|
23322
|
+
* under the specified container.
|
23323
|
+
*
|
23324
|
+
* .byPage() returns an async iterable iterator to list the blobs in pages.
|
23325
|
+
*
|
23326
|
+
* Example using `for await` syntax:
|
23327
|
+
*
|
23328
|
+
* ```js
|
23329
|
+
* let i = 1;
|
23330
|
+
* for await (const blob of containerClient.findBlobsByTags("tagkey='tagvalue'")) {
|
23331
|
+
* console.log(`Blob ${i++}: ${blob.name}`);
|
23332
|
+
* }
|
23333
|
+
* ```
|
23334
|
+
*
|
23335
|
+
* Example using `iter.next()`:
|
23336
|
+
*
|
23337
|
+
* ```js
|
23338
|
+
* let i = 1;
|
23339
|
+
* const iter = containerClient.findBlobsByTags("tagkey='tagvalue'");
|
23340
|
+
* let blobItem = await iter.next();
|
23341
|
+
* while (!blobItem.done) {
|
23342
|
+
* console.log(`Blob ${i++}: ${blobItem.value.name}`);
|
23343
|
+
* blobItem = await iter.next();
|
23344
|
+
* }
|
23345
|
+
* ```
|
23346
|
+
*
|
23347
|
+
* Example using `byPage()`:
|
23348
|
+
*
|
23349
|
+
* ```js
|
23350
|
+
* // passing optional maxPageSize in the page settings
|
23351
|
+
* let i = 1;
|
23352
|
+
* for await (const response of containerClient.findBlobsByTags("tagkey='tagvalue'").byPage({ maxPageSize: 20 })) {
|
23353
|
+
* if (response.blobs) {
|
23354
|
+
* for (const blob of response.blobs) {
|
23355
|
+
* console.log(`Blob ${i++}: ${blob.name}`);
|
23356
|
+
* }
|
23357
|
+
* }
|
23358
|
+
* }
|
23359
|
+
* ```
|
23360
|
+
*
|
23361
|
+
* Example using paging with a marker:
|
23362
|
+
*
|
23363
|
+
* ```js
|
23364
|
+
* let i = 1;
|
23365
|
+
* let iterator = containerClient.findBlobsByTags("tagkey='tagvalue'").byPage({ maxPageSize: 2 });
|
23366
|
+
* let response = (await iterator.next()).value;
|
23367
|
+
*
|
23368
|
+
* // Prints 2 blob names
|
23369
|
+
* if (response.blobs) {
|
23370
|
+
* for (const blob of response.blobs) {
|
23371
|
+
* console.log(`Blob ${i++}: ${blob.name}`);
|
23372
|
+
* }
|
23373
|
+
* }
|
23374
|
+
*
|
23375
|
+
* // Gets next marker
|
23376
|
+
* let marker = response.continuationToken;
|
23377
|
+
* // Passing next marker as continuationToken
|
23378
|
+
* iterator = containerClient
|
23379
|
+
* .findBlobsByTags("tagkey='tagvalue'")
|
23380
|
+
* .byPage({ continuationToken: marker, maxPageSize: 10 });
|
23381
|
+
* response = (await iterator.next()).value;
|
23382
|
+
*
|
23383
|
+
* // Prints blob names
|
23384
|
+
* if (response.blobs) {
|
23385
|
+
* for (const blob of response.blobs) {
|
23386
|
+
* console.log(`Blob ${i++}: ${blob.name}`);
|
23387
|
+
* }
|
23388
|
+
* }
|
23389
|
+
* ```
|
23390
|
+
*
|
23391
|
+
* @param tagFilterSqlExpression - The where parameter enables the caller to query blobs whose tags match a given expression.
|
23392
|
+
* The given expression must evaluate to true for a blob to be returned in the results.
|
23393
|
+
* The[OData - ABNF] filter syntax rule defines the formal grammar for the value of the where query parameter;
|
23394
|
+
* however, only a subset of the OData filter syntax is supported in the Blob service.
|
23395
|
+
* @param options - Options to find blobs by tags.
|
23396
|
+
*/
|
23397
|
+
findBlobsByTags(tagFilterSqlExpression, options = {}) {
|
23398
|
+
// AsyncIterableIterator to iterate over blobs
|
23399
|
+
const listSegmentOptions = Object.assign({}, options);
|
23400
|
+
const iter = this.findBlobsByTagsItems(tagFilterSqlExpression, listSegmentOptions);
|
23401
|
+
return {
|
23402
|
+
/**
|
23403
|
+
* The next method, part of the iteration protocol
|
23404
|
+
*/
|
23405
|
+
next() {
|
23406
|
+
return iter.next();
|
23407
|
+
},
|
23408
|
+
/**
|
23409
|
+
* The connection to the async iterator, part of the iteration protocol
|
23410
|
+
*/
|
23411
|
+
[Symbol.asyncIterator]() {
|
23412
|
+
return this;
|
23413
|
+
},
|
23414
|
+
/**
|
23415
|
+
* Return an AsyncIterableIterator that works a page at a time
|
23416
|
+
*/
|
23417
|
+
byPage: (settings = {}) => {
|
23418
|
+
return this.findBlobsByTagsSegments(tagFilterSqlExpression, settings.continuationToken, Object.assign({ maxPageSize: settings.maxPageSize }, listSegmentOptions));
|
23419
|
+
},
|
22773
23420
|
};
|
22774
23421
|
}
|
22775
23422
|
getContainerNameFromUrl() {
|
@@ -23282,7 +23929,7 @@ function generateAccountSASQueryParameters(accountSASSignatureValues, sharedKeyC
|
|
23282
23929
|
accountSASSignatureValues.protocol ? accountSASSignatureValues.protocol : "",
|
23283
23930
|
version,
|
23284
23931
|
accountSASSignatureValues.encryptionScope ? accountSASSignatureValues.encryptionScope : "",
|
23285
|
-
"" // Account SAS requires an additional newline character
|
23932
|
+
"", // Account SAS requires an additional newline character
|
23286
23933
|
].join("\n");
|
23287
23934
|
}
|
23288
23935
|
else {
|
@@ -23298,7 +23945,7 @@ function generateAccountSASQueryParameters(accountSASSignatureValues, sharedKeyC
|
|
23298
23945
|
accountSASSignatureValues.ipRange ? ipRangeToString(accountSASSignatureValues.ipRange) : "",
|
23299
23946
|
accountSASSignatureValues.protocol ? accountSASSignatureValues.protocol : "",
|
23300
23947
|
version,
|
23301
|
-
"" // Account SAS requires an additional newline character
|
23948
|
+
"", // Account SAS requires an additional newline character
|
23302
23949
|
].join("\n");
|
23303
23950
|
}
|
23304
23951
|
const signature = sharedKeyCredential.computeHMACSHA256(stringToSign);
|
@@ -23349,12 +23996,17 @@ class BlobServiceClient extends StorageClient {
|
|
23349
23996
|
options = options || {};
|
23350
23997
|
const extractedCreds = extractConnectionStringParts(connectionString);
|
23351
23998
|
if (extractedCreds.kind === "AccountConnString") {
|
23352
|
-
{
|
23999
|
+
if (coreHttp.isNode) {
|
23353
24000
|
const sharedKeyCredential = new StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
23354
|
-
options.proxyOptions
|
24001
|
+
if (!options.proxyOptions) {
|
24002
|
+
options.proxyOptions = coreHttp.getDefaultProxySettings(extractedCreds.proxyUri);
|
24003
|
+
}
|
23355
24004
|
const pipeline = newPipeline(sharedKeyCredential, options);
|
23356
24005
|
return new BlobServiceClient(extractedCreds.url, pipeline);
|
23357
24006
|
}
|
24007
|
+
else {
|
24008
|
+
throw new Error("Account connection string is only supported in Node.js environment");
|
24009
|
+
}
|
23358
24010
|
}
|
23359
24011
|
else if (extractedCreds.kind === "SASConnString") {
|
23360
24012
|
const pipeline = newPipeline(new AnonymousCredential(), options);
|
@@ -23393,13 +24045,13 @@ class BlobServiceClient extends StorageClient {
|
|
23393
24045
|
const containerCreateResponse = await containerClient.create(updatedOptions);
|
23394
24046
|
return {
|
23395
24047
|
containerClient,
|
23396
|
-
containerCreateResponse
|
24048
|
+
containerCreateResponse,
|
23397
24049
|
};
|
23398
24050
|
}
|
23399
24051
|
catch (e) {
|
23400
24052
|
span.setStatus({
|
23401
24053
|
code: coreTracing.SpanStatusCode.ERROR,
|
23402
|
-
message: e.message
|
24054
|
+
message: e.message,
|
23403
24055
|
});
|
23404
24056
|
throw e;
|
23405
24057
|
}
|
@@ -23423,7 +24075,7 @@ class BlobServiceClient extends StorageClient {
|
|
23423
24075
|
catch (e) {
|
23424
24076
|
span.setStatus({
|
23425
24077
|
code: coreTracing.SpanStatusCode.ERROR,
|
23426
|
-
message: e.message
|
24078
|
+
message: e.message,
|
23427
24079
|
});
|
23428
24080
|
throw e;
|
23429
24081
|
}
|
@@ -23453,7 +24105,7 @@ class BlobServiceClient extends StorageClient {
|
|
23453
24105
|
catch (e) {
|
23454
24106
|
span.setStatus({
|
23455
24107
|
code: coreTracing.SpanStatusCode.ERROR,
|
23456
|
-
message: e.message
|
24108
|
+
message: e.message,
|
23457
24109
|
});
|
23458
24110
|
throw e;
|
23459
24111
|
}
|
@@ -23483,7 +24135,7 @@ class BlobServiceClient extends StorageClient {
|
|
23483
24135
|
catch (e) {
|
23484
24136
|
span.setStatus({
|
23485
24137
|
code: coreTracing.SpanStatusCode.ERROR,
|
23486
|
-
message: e.message
|
24138
|
+
message: e.message,
|
23487
24139
|
});
|
23488
24140
|
throw e;
|
23489
24141
|
}
|
@@ -23507,7 +24159,7 @@ class BlobServiceClient extends StorageClient {
|
|
23507
24159
|
catch (e) {
|
23508
24160
|
span.setStatus({
|
23509
24161
|
code: coreTracing.SpanStatusCode.ERROR,
|
23510
|
-
message: e.message
|
24162
|
+
message: e.message,
|
23511
24163
|
});
|
23512
24164
|
throw e;
|
23513
24165
|
}
|
@@ -23532,7 +24184,7 @@ class BlobServiceClient extends StorageClient {
|
|
23532
24184
|
catch (e) {
|
23533
24185
|
span.setStatus({
|
23534
24186
|
code: coreTracing.SpanStatusCode.ERROR,
|
23535
|
-
message: e.message
|
24187
|
+
message: e.message,
|
23536
24188
|
});
|
23537
24189
|
throw e;
|
23538
24190
|
}
|
@@ -23557,7 +24209,7 @@ class BlobServiceClient extends StorageClient {
|
|
23557
24209
|
catch (e) {
|
23558
24210
|
span.setStatus({
|
23559
24211
|
code: coreTracing.SpanStatusCode.ERROR,
|
23560
|
-
message: e.message
|
24212
|
+
message: e.message,
|
23561
24213
|
});
|
23562
24214
|
throw e;
|
23563
24215
|
}
|
@@ -23583,7 +24235,7 @@ class BlobServiceClient extends StorageClient {
|
|
23583
24235
|
catch (e) {
|
23584
24236
|
span.setStatus({
|
23585
24237
|
code: coreTracing.SpanStatusCode.ERROR,
|
23586
|
-
message: e.message
|
24238
|
+
message: e.message,
|
23587
24239
|
});
|
23588
24240
|
throw e;
|
23589
24241
|
}
|
@@ -23613,7 +24265,7 @@ class BlobServiceClient extends StorageClient {
|
|
23613
24265
|
catch (e) {
|
23614
24266
|
span.setStatus({
|
23615
24267
|
code: coreTracing.SpanStatusCode.ERROR,
|
23616
|
-
message: e.message
|
24268
|
+
message: e.message,
|
23617
24269
|
});
|
23618
24270
|
throw e;
|
23619
24271
|
}
|
@@ -23656,7 +24308,7 @@ class BlobServiceClient extends StorageClient {
|
|
23656
24308
|
catch (e) {
|
23657
24309
|
span.setStatus({
|
23658
24310
|
code: coreTracing.SpanStatusCode.ERROR,
|
23659
|
-
message: e.message
|
24311
|
+
message: e.message,
|
23660
24312
|
});
|
23661
24313
|
throw e;
|
23662
24314
|
}
|
@@ -23822,7 +24474,7 @@ class BlobServiceClient extends StorageClient {
|
|
23822
24474
|
*/
|
23823
24475
|
byPage: (settings = {}) => {
|
23824
24476
|
return this.findBlobsByTagsSegments(tagFilterSqlExpression, settings.continuationToken, Object.assign({ maxPageSize: settings.maxPageSize }, listSegmentOptions));
|
23825
|
-
}
|
24477
|
+
},
|
23826
24478
|
};
|
23827
24479
|
}
|
23828
24480
|
/**
|
@@ -23984,7 +24636,7 @@ class BlobServiceClient extends StorageClient {
|
|
23984
24636
|
*/
|
23985
24637
|
byPage: (settings = {}) => {
|
23986
24638
|
return this.listSegments(settings.continuationToken, Object.assign({ maxPageSize: settings.maxPageSize }, listSegmentOptions));
|
23987
|
-
}
|
24639
|
+
},
|
23988
24640
|
};
|
23989
24641
|
}
|
23990
24642
|
/**
|
@@ -24003,7 +24655,7 @@ class BlobServiceClient extends StorageClient {
|
|
24003
24655
|
try {
|
24004
24656
|
const response = await this.serviceContext.getUserDelegationKey({
|
24005
24657
|
startsOn: truncatedISO8061Date(startsOn, false),
|
24006
|
-
expiresOn: truncatedISO8061Date(expiresOn, false)
|
24658
|
+
expiresOn: truncatedISO8061Date(expiresOn, false),
|
24007
24659
|
}, Object.assign({ abortSignal: options.abortSignal }, convertTracingToRequestOptionsBase(updatedOptions)));
|
24008
24660
|
const userDelegationKey = {
|
24009
24661
|
signedObjectId: response.signedObjectId,
|
@@ -24012,7 +24664,7 @@ class BlobServiceClient extends StorageClient {
|
|
24012
24664
|
signedExpiresOn: new Date(response.signedExpiresOn),
|
24013
24665
|
signedService: response.signedService,
|
24014
24666
|
signedVersion: response.signedVersion,
|
24015
|
-
value: response.value
|
24667
|
+
value: response.value,
|
24016
24668
|
};
|
24017
24669
|
const res = Object.assign({ _response: response._response, requestId: response.requestId, clientRequestId: response.clientRequestId, version: response.version, date: response.date, errorCode: response.errorCode }, userDelegationKey);
|
24018
24670
|
return res;
|
@@ -24020,7 +24672,7 @@ class BlobServiceClient extends StorageClient {
|
|
24020
24672
|
catch (e) {
|
24021
24673
|
span.setStatus({
|
24022
24674
|
code: coreTracing.SpanStatusCode.ERROR,
|
24023
|
-
message: e.message
|
24675
|
+
message: e.message,
|
24024
24676
|
});
|
24025
24677
|
throw e;
|
24026
24678
|
}
|
@@ -24069,39 +24721,27 @@ class BlobServiceClient extends StorageClient {
|
|
24069
24721
|
|
24070
24722
|
Object.defineProperty(exports, 'BaseRequestPolicy', {
|
24071
24723
|
enumerable: true,
|
24072
|
-
get: function () {
|
24073
|
-
return coreHttp.BaseRequestPolicy;
|
24074
|
-
}
|
24724
|
+
get: function () { return coreHttp.BaseRequestPolicy; }
|
24075
24725
|
});
|
24076
24726
|
Object.defineProperty(exports, 'HttpHeaders', {
|
24077
24727
|
enumerable: true,
|
24078
|
-
get: function () {
|
24079
|
-
return coreHttp.HttpHeaders;
|
24080
|
-
}
|
24728
|
+
get: function () { return coreHttp.HttpHeaders; }
|
24081
24729
|
});
|
24082
24730
|
Object.defineProperty(exports, 'RequestPolicyOptions', {
|
24083
24731
|
enumerable: true,
|
24084
|
-
get: function () {
|
24085
|
-
return coreHttp.RequestPolicyOptions;
|
24086
|
-
}
|
24732
|
+
get: function () { return coreHttp.RequestPolicyOptions; }
|
24087
24733
|
});
|
24088
24734
|
Object.defineProperty(exports, 'RestError', {
|
24089
24735
|
enumerable: true,
|
24090
|
-
get: function () {
|
24091
|
-
return coreHttp.RestError;
|
24092
|
-
}
|
24736
|
+
get: function () { return coreHttp.RestError; }
|
24093
24737
|
});
|
24094
24738
|
Object.defineProperty(exports, 'WebResource', {
|
24095
24739
|
enumerable: true,
|
24096
|
-
get: function () {
|
24097
|
-
return coreHttp.WebResource;
|
24098
|
-
}
|
24740
|
+
get: function () { return coreHttp.WebResource; }
|
24099
24741
|
});
|
24100
24742
|
Object.defineProperty(exports, 'deserializationPolicy', {
|
24101
24743
|
enumerable: true,
|
24102
|
-
get: function () {
|
24103
|
-
return coreHttp.deserializationPolicy;
|
24104
|
-
}
|
24744
|
+
get: function () { return coreHttp.deserializationPolicy; }
|
24105
24745
|
});
|
24106
24746
|
exports.AccountSASPermissions = AccountSASPermissions;
|
24107
24747
|
exports.AccountSASResourceTypes = AccountSASResourceTypes;
|