@azure/storage-file-datalake 12.27.0-beta.1 → 12.27.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/dist/browser/DataLakeFileSystemClient.d.ts +13 -13
- package/dist/browser/DataLakeFileSystemClient.js +136 -93
- package/dist/browser/DataLakeFileSystemClient.js.map +1 -1
- package/dist/browser/DataLakeLeaseClient.js +1 -0
- package/dist/browser/DataLakeLeaseClient.js.map +1 -1
- package/dist/browser/DataLakeServiceClient.d.ts +6 -6
- package/dist/browser/DataLakeServiceClient.js +28 -11
- package/dist/browser/DataLakeServiceClient.js.map +1 -1
- package/dist/browser/Pipeline.js +24 -15
- package/dist/browser/Pipeline.js.map +1 -1
- package/dist/browser/StorageClient.js +43 -3
- package/dist/browser/StorageClient.js.map +1 -1
- package/dist/browser/StorageContextClient.js +2 -3
- package/dist/browser/StorageContextClient.js.map +1 -1
- package/dist/browser/clients.d.ts +33 -33
- package/dist/browser/clients.js +269 -89
- package/dist/browser/clients.js.map +1 -1
- package/dist/browser/generated/src/operations/fileSystemOperations.js +1 -0
- package/dist/browser/generated/src/operations/fileSystemOperations.js.map +1 -1
- package/dist/browser/generated/src/operations/pathOperations.js +1 -0
- package/dist/browser/generated/src/operations/pathOperations.js.map +1 -1
- package/dist/browser/generated/src/operations/service.js +1 -0
- package/dist/browser/generated/src/operations/service.js.map +1 -1
- package/dist/browser/generated/src/storageClient.js +15 -4
- package/dist/browser/generated/src/storageClient.js.map +1 -1
- package/dist/browser/index-browser.d.mts.map +1 -1
- package/dist/browser/index-browser.mjs.map +1 -1
- package/dist/browser/index.d.ts +1 -1
- package/dist/browser/index.js +1 -1
- package/dist/browser/models.d.ts +1 -1
- package/dist/browser/models.js.map +1 -1
- package/dist/browser/sas/AccountSASPermissions.d.ts +1 -1
- package/dist/browser/sas/AccountSASPermissions.js +34 -36
- package/dist/browser/sas/AccountSASPermissions.js.map +1 -1
- package/dist/browser/sas/AccountSASResourceTypes.d.ts +1 -1
- package/dist/browser/sas/AccountSASResourceTypes.js +13 -15
- package/dist/browser/sas/AccountSASResourceTypes.js.map +1 -1
- package/dist/browser/sas/AccountSASServices.js +16 -18
- package/dist/browser/sas/AccountSASServices.js.map +1 -1
- package/dist/browser/sas/AccountSASSignatureValues.d.ts +3 -3
- package/dist/browser/sas/AccountSASSignatureValues.js +1 -1
- package/dist/browser/sas/AccountSASSignatureValues.js.map +1 -1
- package/dist/browser/sas/DataLakeSASPermissions.js +39 -41
- package/dist/browser/sas/DataLakeSASPermissions.js.map +1 -1
- package/dist/browser/sas/DataLakeSASSignatureValues.d.ts +1 -1
- package/dist/browser/sas/DataLakeSASSignatureValues.js +4 -3
- package/dist/browser/sas/DataLakeSASSignatureValues.js.map +1 -1
- package/dist/browser/sas/DirectorySASPermissions.d.ts +1 -1
- package/dist/browser/sas/DirectorySASPermissions.js +44 -46
- package/dist/browser/sas/DirectorySASPermissions.js.map +1 -1
- package/dist/browser/sas/FileSystemSASPermissions.d.ts +1 -1
- package/dist/browser/sas/FileSystemSASPermissions.js +44 -46
- package/dist/browser/sas/FileSystemSASPermissions.js.map +1 -1
- package/dist/browser/sas/SASQueryParameters.d.ts +2 -2
- package/dist/browser/sas/SASQueryParameters.js +131 -2
- package/dist/browser/sas/SASQueryParameters.js.map +1 -1
- package/dist/browser/transforms.js +8 -1
- package/dist/browser/transforms.js.map +1 -1
- package/dist/browser/utils/Batch.js +29 -21
- package/dist/browser/utils/Batch.js.map +1 -1
- package/dist/browser/utils/BufferScheduler.js +70 -44
- package/dist/browser/utils/BufferScheduler.js.map +1 -1
- package/dist/browser/utils/DataLakeAclChangeFailedError.js +8 -0
- package/dist/browser/utils/DataLakeAclChangeFailedError.js.map +1 -1
- package/dist/browser/utils/PathClientInternal.js +4 -0
- package/dist/browser/utils/PathClientInternal.js.map +1 -1
- package/dist/browser/utils/constants.d.ts.map +1 -1
- package/dist/browser/utils/constants.js +1 -1
- package/dist/browser/utils/constants.js.map +1 -1
- package/dist/browser/utils/utils.common.d.ts +2 -2
- package/dist/browser/utils/utils.common.js +5 -7
- package/dist/browser/utils/utils.common.js.map +1 -1
- package/dist/commonjs/DataLakeFileSystemClient.d.ts +13 -13
- package/dist/commonjs/DataLakeFileSystemClient.js +136 -93
- package/dist/commonjs/DataLakeFileSystemClient.js.map +1 -1
- package/dist/commonjs/DataLakeLeaseClient.js +1 -0
- package/dist/commonjs/DataLakeLeaseClient.js.map +1 -1
- package/dist/commonjs/DataLakeServiceClient.d.ts +6 -6
- package/dist/commonjs/DataLakeServiceClient.js +28 -11
- package/dist/commonjs/DataLakeServiceClient.js.map +1 -1
- package/dist/commonjs/Pipeline.js +32 -23
- package/dist/commonjs/Pipeline.js.map +1 -1
- package/dist/commonjs/StorageClient.js +43 -3
- package/dist/commonjs/StorageClient.js.map +1 -1
- package/dist/commonjs/StorageContextClient.js +2 -3
- package/dist/commonjs/StorageContextClient.js.map +1 -1
- package/dist/commonjs/clients.d.ts +33 -33
- package/dist/commonjs/clients.js +269 -89
- package/dist/commonjs/clients.js.map +1 -1
- package/dist/commonjs/credentials/UserDelegationKeyCredential.d.ts +1 -1
- package/dist/commonjs/credentials/UserDelegationKeyCredential.js +13 -1
- package/dist/commonjs/credentials/UserDelegationKeyCredential.js.map +1 -1
- package/dist/commonjs/generated/src/operations/fileSystemOperations.js +1 -0
- package/dist/commonjs/generated/src/operations/fileSystemOperations.js.map +1 -1
- package/dist/commonjs/generated/src/operations/pathOperations.js +1 -0
- package/dist/commonjs/generated/src/operations/pathOperations.js.map +1 -1
- package/dist/commonjs/generated/src/operations/service.js +1 -0
- package/dist/commonjs/generated/src/operations/service.js.map +1 -1
- package/dist/commonjs/generated/src/storageClient.js +15 -4
- package/dist/commonjs/generated/src/storageClient.js.map +1 -1
- package/dist/commonjs/models.d.ts +1 -1
- package/dist/commonjs/models.js.map +1 -1
- package/dist/commonjs/sas/AccountSASPermissions.d.ts +1 -1
- package/dist/commonjs/sas/AccountSASPermissions.js +34 -36
- package/dist/commonjs/sas/AccountSASPermissions.js.map +1 -1
- package/dist/commonjs/sas/AccountSASResourceTypes.d.ts +1 -1
- package/dist/commonjs/sas/AccountSASResourceTypes.js +13 -15
- package/dist/commonjs/sas/AccountSASResourceTypes.js.map +1 -1
- package/dist/commonjs/sas/AccountSASServices.js +16 -18
- package/dist/commonjs/sas/AccountSASServices.js.map +1 -1
- package/dist/commonjs/sas/AccountSASSignatureValues.d.ts +3 -3
- package/dist/commonjs/sas/AccountSASSignatureValues.js +1 -1
- package/dist/commonjs/sas/AccountSASSignatureValues.js.map +1 -1
- package/dist/commonjs/sas/DataLakeSASPermissions.js +39 -41
- package/dist/commonjs/sas/DataLakeSASPermissions.js.map +1 -1
- package/dist/commonjs/sas/DataLakeSASSignatureValues.d.ts +1 -1
- package/dist/commonjs/sas/DataLakeSASSignatureValues.js +4 -3
- package/dist/commonjs/sas/DataLakeSASSignatureValues.js.map +1 -1
- package/dist/commonjs/sas/DirectorySASPermissions.d.ts +1 -1
- package/dist/commonjs/sas/DirectorySASPermissions.js +44 -46
- package/dist/commonjs/sas/DirectorySASPermissions.js.map +1 -1
- package/dist/commonjs/sas/FileSystemSASPermissions.d.ts +1 -1
- package/dist/commonjs/sas/FileSystemSASPermissions.js +44 -46
- package/dist/commonjs/sas/FileSystemSASPermissions.js.map +1 -1
- package/dist/commonjs/sas/SASQueryParameters.d.ts +2 -2
- package/dist/commonjs/sas/SASQueryParameters.js +131 -2
- package/dist/commonjs/sas/SASQueryParameters.js.map +1 -1
- package/dist/commonjs/transforms.js +8 -1
- package/dist/commonjs/transforms.js.map +1 -1
- package/dist/commonjs/tsdoc-metadata.json +11 -11
- package/dist/commonjs/utils/Batch.js +29 -21
- package/dist/commonjs/utils/Batch.js.map +1 -1
- package/dist/commonjs/utils/BufferScheduler.js +70 -44
- package/dist/commonjs/utils/BufferScheduler.js.map +1 -1
- package/dist/commonjs/utils/DataLakeAclChangeFailedError.js +8 -0
- package/dist/commonjs/utils/DataLakeAclChangeFailedError.js.map +1 -1
- package/dist/commonjs/utils/PathClientInternal.js +4 -0
- package/dist/commonjs/utils/PathClientInternal.js.map +1 -1
- package/dist/commonjs/utils/constants.d.ts.map +1 -1
- package/dist/commonjs/utils/constants.js +1 -1
- package/dist/commonjs/utils/constants.js.map +1 -1
- package/dist/commonjs/utils/utils.common.d.ts +2 -2
- package/dist/commonjs/utils/utils.common.js +5 -7
- package/dist/commonjs/utils/utils.common.js.map +1 -1
- package/dist/commonjs/utils/utils.d.ts +1 -1
- package/dist/commonjs/utils/utils.d.ts.map +1 -1
- package/dist/commonjs/utils/utils.js +4 -4
- package/dist/commonjs/utils/utils.js.map +1 -1
- package/dist/esm/DataLakeFileSystemClient.d.ts +13 -13
- package/dist/esm/DataLakeFileSystemClient.js +136 -93
- package/dist/esm/DataLakeFileSystemClient.js.map +1 -1
- package/dist/esm/DataLakeLeaseClient.js +1 -0
- package/dist/esm/DataLakeLeaseClient.js.map +1 -1
- package/dist/esm/DataLakeServiceClient.d.ts +6 -6
- package/dist/esm/DataLakeServiceClient.js +28 -11
- package/dist/esm/DataLakeServiceClient.js.map +1 -1
- package/dist/esm/Pipeline.js +24 -15
- package/dist/esm/Pipeline.js.map +1 -1
- package/dist/esm/StorageClient.js +43 -3
- package/dist/esm/StorageClient.js.map +1 -1
- package/dist/esm/StorageContextClient.js +2 -3
- package/dist/esm/StorageContextClient.js.map +1 -1
- package/dist/esm/clients.d.ts +33 -33
- package/dist/esm/clients.js +269 -89
- package/dist/esm/clients.js.map +1 -1
- package/dist/esm/credentials/UserDelegationKeyCredential.d.ts +1 -1
- package/dist/esm/credentials/UserDelegationKeyCredential.js +13 -1
- package/dist/esm/credentials/UserDelegationKeyCredential.js.map +1 -1
- package/dist/esm/generated/src/operations/fileSystemOperations.js +1 -0
- package/dist/esm/generated/src/operations/fileSystemOperations.js.map +1 -1
- package/dist/esm/generated/src/operations/pathOperations.js +1 -0
- package/dist/esm/generated/src/operations/pathOperations.js.map +1 -1
- package/dist/esm/generated/src/operations/service.js +1 -0
- package/dist/esm/generated/src/operations/service.js.map +1 -1
- package/dist/esm/generated/src/storageClient.js +15 -4
- package/dist/esm/generated/src/storageClient.js.map +1 -1
- package/dist/esm/models.d.ts +1 -1
- package/dist/esm/models.js.map +1 -1
- package/dist/esm/sas/AccountSASPermissions.d.ts +1 -1
- package/dist/esm/sas/AccountSASPermissions.js +34 -36
- package/dist/esm/sas/AccountSASPermissions.js.map +1 -1
- package/dist/esm/sas/AccountSASResourceTypes.d.ts +1 -1
- package/dist/esm/sas/AccountSASResourceTypes.js +13 -15
- package/dist/esm/sas/AccountSASResourceTypes.js.map +1 -1
- package/dist/esm/sas/AccountSASServices.js +16 -18
- package/dist/esm/sas/AccountSASServices.js.map +1 -1
- package/dist/esm/sas/AccountSASSignatureValues.d.ts +3 -3
- package/dist/esm/sas/AccountSASSignatureValues.js +1 -1
- package/dist/esm/sas/AccountSASSignatureValues.js.map +1 -1
- package/dist/esm/sas/DataLakeSASPermissions.js +39 -41
- package/dist/esm/sas/DataLakeSASPermissions.js.map +1 -1
- package/dist/esm/sas/DataLakeSASSignatureValues.d.ts +1 -1
- package/dist/esm/sas/DataLakeSASSignatureValues.js +4 -3
- package/dist/esm/sas/DataLakeSASSignatureValues.js.map +1 -1
- package/dist/esm/sas/DirectorySASPermissions.d.ts +1 -1
- package/dist/esm/sas/DirectorySASPermissions.js +44 -46
- package/dist/esm/sas/DirectorySASPermissions.js.map +1 -1
- package/dist/esm/sas/FileSystemSASPermissions.d.ts +1 -1
- package/dist/esm/sas/FileSystemSASPermissions.js +44 -46
- package/dist/esm/sas/FileSystemSASPermissions.js.map +1 -1
- package/dist/esm/sas/SASQueryParameters.d.ts +2 -2
- package/dist/esm/sas/SASQueryParameters.js +131 -2
- package/dist/esm/sas/SASQueryParameters.js.map +1 -1
- package/dist/esm/transforms.js +8 -1
- package/dist/esm/transforms.js.map +1 -1
- package/dist/esm/utils/Batch.js +29 -21
- package/dist/esm/utils/Batch.js.map +1 -1
- package/dist/esm/utils/BufferScheduler.js +70 -44
- package/dist/esm/utils/BufferScheduler.js.map +1 -1
- package/dist/esm/utils/DataLakeAclChangeFailedError.js +8 -0
- package/dist/esm/utils/DataLakeAclChangeFailedError.js.map +1 -1
- package/dist/esm/utils/PathClientInternal.js +4 -0
- package/dist/esm/utils/PathClientInternal.js.map +1 -1
- package/dist/esm/utils/constants.d.ts.map +1 -1
- package/dist/esm/utils/constants.js +1 -1
- package/dist/esm/utils/constants.js.map +1 -1
- package/dist/esm/utils/utils.common.d.ts +2 -2
- package/dist/esm/utils/utils.common.js +5 -7
- package/dist/esm/utils/utils.common.js.map +1 -1
- package/dist/esm/utils/utils.d.ts +1 -1
- package/dist/esm/utils/utils.d.ts.map +1 -1
- package/dist/esm/utils/utils.js +2 -2
- package/dist/esm/utils/utils.js.map +1 -1
- package/dist/react-native/DataLakeFileSystemClient.d.ts +13 -13
- package/dist/react-native/DataLakeFileSystemClient.js +136 -93
- package/dist/react-native/DataLakeFileSystemClient.js.map +1 -1
- package/dist/react-native/DataLakeLeaseClient.js +1 -0
- package/dist/react-native/DataLakeLeaseClient.js.map +1 -1
- package/dist/react-native/DataLakeServiceClient.d.ts +6 -6
- package/dist/react-native/DataLakeServiceClient.js +28 -11
- package/dist/react-native/DataLakeServiceClient.js.map +1 -1
- package/dist/react-native/Pipeline.js +24 -15
- package/dist/react-native/Pipeline.js.map +1 -1
- package/dist/react-native/StorageClient.js +43 -3
- package/dist/react-native/StorageClient.js.map +1 -1
- package/dist/react-native/StorageContextClient.js +2 -3
- package/dist/react-native/StorageContextClient.js.map +1 -1
- package/dist/react-native/clients.d.ts +33 -33
- package/dist/react-native/clients.js +269 -89
- package/dist/react-native/clients.js.map +1 -1
- package/dist/react-native/credentials/UserDelegationKeyCredential.d.ts +1 -1
- package/dist/react-native/credentials/UserDelegationKeyCredential.js +13 -1
- package/dist/react-native/credentials/UserDelegationKeyCredential.js.map +1 -1
- package/dist/react-native/generated/src/operations/fileSystemOperations.js +1 -0
- package/dist/react-native/generated/src/operations/fileSystemOperations.js.map +1 -1
- package/dist/react-native/generated/src/operations/pathOperations.js +1 -0
- package/dist/react-native/generated/src/operations/pathOperations.js.map +1 -1
- package/dist/react-native/generated/src/operations/service.js +1 -0
- package/dist/react-native/generated/src/operations/service.js.map +1 -1
- package/dist/react-native/generated/src/storageClient.js +15 -4
- package/dist/react-native/generated/src/storageClient.js.map +1 -1
- package/dist/react-native/models.d.ts +1 -1
- package/dist/react-native/models.js.map +1 -1
- package/dist/react-native/sas/AccountSASPermissions.d.ts +1 -1
- package/dist/react-native/sas/AccountSASPermissions.js +34 -36
- package/dist/react-native/sas/AccountSASPermissions.js.map +1 -1
- package/dist/react-native/sas/AccountSASResourceTypes.d.ts +1 -1
- package/dist/react-native/sas/AccountSASResourceTypes.js +13 -15
- package/dist/react-native/sas/AccountSASResourceTypes.js.map +1 -1
- package/dist/react-native/sas/AccountSASServices.js +16 -18
- package/dist/react-native/sas/AccountSASServices.js.map +1 -1
- package/dist/react-native/sas/AccountSASSignatureValues.d.ts +3 -3
- package/dist/react-native/sas/AccountSASSignatureValues.js +1 -1
- package/dist/react-native/sas/AccountSASSignatureValues.js.map +1 -1
- package/dist/react-native/sas/DataLakeSASPermissions.js +39 -41
- package/dist/react-native/sas/DataLakeSASPermissions.js.map +1 -1
- package/dist/react-native/sas/DataLakeSASSignatureValues.d.ts +1 -1
- package/dist/react-native/sas/DataLakeSASSignatureValues.js +4 -3
- package/dist/react-native/sas/DataLakeSASSignatureValues.js.map +1 -1
- package/dist/react-native/sas/DirectorySASPermissions.d.ts +1 -1
- package/dist/react-native/sas/DirectorySASPermissions.js +44 -46
- package/dist/react-native/sas/DirectorySASPermissions.js.map +1 -1
- package/dist/react-native/sas/FileSystemSASPermissions.d.ts +1 -1
- package/dist/react-native/sas/FileSystemSASPermissions.js +44 -46
- package/dist/react-native/sas/FileSystemSASPermissions.js.map +1 -1
- package/dist/react-native/sas/SASQueryParameters.d.ts +2 -2
- package/dist/react-native/sas/SASQueryParameters.js +131 -2
- package/dist/react-native/sas/SASQueryParameters.js.map +1 -1
- package/dist/react-native/transforms.js +8 -1
- package/dist/react-native/transforms.js.map +1 -1
- package/dist/react-native/utils/Batch.js +29 -21
- package/dist/react-native/utils/Batch.js.map +1 -1
- package/dist/react-native/utils/BufferScheduler.js +70 -44
- package/dist/react-native/utils/BufferScheduler.js.map +1 -1
- package/dist/react-native/utils/DataLakeAclChangeFailedError.js +8 -0
- package/dist/react-native/utils/DataLakeAclChangeFailedError.js.map +1 -1
- package/dist/react-native/utils/PathClientInternal.js +4 -0
- package/dist/react-native/utils/PathClientInternal.js.map +1 -1
- package/dist/react-native/utils/constants.d.ts.map +1 -1
- package/dist/react-native/utils/constants.js +1 -1
- package/dist/react-native/utils/constants.js.map +1 -1
- package/dist/react-native/utils/utils.common.d.ts +2 -2
- package/dist/react-native/utils/utils.common.js +5 -7
- package/dist/react-native/utils/utils.common.js.map +1 -1
- package/dist/react-native/utils/utils.d.ts +1 -1
- package/dist/react-native/utils/utils.d.ts.map +1 -1
- package/dist/react-native/utils/utils.js +2 -2
- package/dist/react-native/utils/utils.js.map +1 -1
- package/package.json +8 -8
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.DataLakeFileSystemClient = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
4
|
const storage_blob_1 = require("@azure/storage-blob");
|
|
6
5
|
const Pipeline_js_1 = require("./Pipeline.js");
|
|
7
6
|
const StorageSharedKeyCredential_js_1 = require("./credentials/StorageSharedKeyCredential.js");
|
|
@@ -21,6 +20,18 @@ const PathClientInternal_js_1 = require("./utils/PathClientInternal.js");
|
|
|
21
20
|
* allowing you to manipulate its directories and files.
|
|
22
21
|
*/
|
|
23
22
|
class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
23
|
+
/**
|
|
24
|
+
* fileSystemContext provided by protocol layer.
|
|
25
|
+
*/
|
|
26
|
+
fileSystemContext;
|
|
27
|
+
/**
|
|
28
|
+
* fileSystemContext provided by protocol layer.
|
|
29
|
+
*/
|
|
30
|
+
fileSystemContextToBlobEndpoint;
|
|
31
|
+
/**
|
|
32
|
+
* blobContainerClient provided by `@azure/storage-blob` package.
|
|
33
|
+
*/
|
|
34
|
+
blobContainerClient;
|
|
24
35
|
constructor(url, credentialOrPipeline,
|
|
25
36
|
// Legacy, no way to fix the eslint error without breaking. Disable the rule for this line.
|
|
26
37
|
/* eslint-disable-next-line @azure/azure-sdk/ts-naming-options */
|
|
@@ -83,26 +94,36 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
83
94
|
* Creates a new file system under the specified account. If the file system with
|
|
84
95
|
* the same name already exists, the operation fails.
|
|
85
96
|
*
|
|
86
|
-
* @see https://learn.microsoft.com/
|
|
97
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/create-container
|
|
87
98
|
*
|
|
88
99
|
* @param options - Optional. Options when creating file system.
|
|
89
100
|
*/
|
|
90
101
|
async create(options = {}) {
|
|
91
102
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-create", options, async (updatedOptions) => {
|
|
92
|
-
return this.blobContainerClient.create(
|
|
103
|
+
return this.blobContainerClient.create({
|
|
104
|
+
...options,
|
|
105
|
+
access: (0, transforms_js_1.toContainerPublicAccessType)(options.access),
|
|
106
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
107
|
+
containerEncryptionScope: options.fileSystemEncryptionScope,
|
|
108
|
+
});
|
|
93
109
|
});
|
|
94
110
|
}
|
|
95
111
|
/**
|
|
96
112
|
* Creates a new file system under the specified account. If the file system with
|
|
97
113
|
* the same name already exists, it is not changed.
|
|
98
114
|
*
|
|
99
|
-
* @see https://learn.microsoft.com/
|
|
115
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/create-container
|
|
100
116
|
*
|
|
101
117
|
* @param options -
|
|
102
118
|
*/
|
|
103
119
|
async createIfNotExists(options = {}) {
|
|
104
120
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-createIfNotExists", options, async (updatedOptions) => {
|
|
105
|
-
return this.blobContainerClient.createIfNotExists(
|
|
121
|
+
return this.blobContainerClient.createIfNotExists({
|
|
122
|
+
...options,
|
|
123
|
+
access: (0, transforms_js_1.toContainerPublicAccessType)(options.access),
|
|
124
|
+
containerEncryptionScope: options.fileSystemEncryptionScope,
|
|
125
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
126
|
+
});
|
|
106
127
|
});
|
|
107
128
|
}
|
|
108
129
|
/**
|
|
@@ -122,19 +143,22 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
122
143
|
/**
|
|
123
144
|
* Delete current file system.
|
|
124
145
|
*
|
|
125
|
-
* @see https://learn.microsoft.com/
|
|
146
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/delete-container
|
|
126
147
|
*
|
|
127
148
|
* @param options - Optional. Options when deleting file system.
|
|
128
149
|
*/
|
|
129
150
|
async delete(options = {}) {
|
|
130
151
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-delete", options, async (updatedOptions) => {
|
|
131
|
-
return this.blobContainerClient.delete(
|
|
152
|
+
return this.blobContainerClient.delete({
|
|
153
|
+
...options,
|
|
154
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
155
|
+
});
|
|
132
156
|
});
|
|
133
157
|
}
|
|
134
158
|
/**
|
|
135
159
|
* Delete current file system if it exists.
|
|
136
160
|
*
|
|
137
|
-
* @see https://learn.microsoft.com/
|
|
161
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/delete-container
|
|
138
162
|
*
|
|
139
163
|
* @param options -
|
|
140
164
|
*/
|
|
@@ -152,13 +176,16 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
152
176
|
* the `listFileSystems` method of {@link DataLakeServiceClient} using the `includeMetadata` option, which
|
|
153
177
|
* will retain their original casing.
|
|
154
178
|
*
|
|
155
|
-
* @see https://learn.microsoft.com/
|
|
179
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/get-container-properties
|
|
156
180
|
*
|
|
157
181
|
* @param options - Optional. Options when getting file system properties.
|
|
158
182
|
*/
|
|
159
183
|
async getProperties(options = {}) {
|
|
160
184
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-getProperties", options, async (updatedOptions) => {
|
|
161
|
-
const rawResponse = await this.blobContainerClient.getProperties(
|
|
185
|
+
const rawResponse = await this.blobContainerClient.getProperties({
|
|
186
|
+
...options,
|
|
187
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
188
|
+
});
|
|
162
189
|
// Transfer and rename blobPublicAccess to publicAccess
|
|
163
190
|
const response = rawResponse;
|
|
164
191
|
response.publicAccess = (0, transforms_js_1.toPublicAccessType)(rawResponse.blobPublicAccess);
|
|
@@ -174,7 +201,7 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
174
201
|
* If no option provided, or no metadata defined in the parameter, the file system
|
|
175
202
|
* metadata will be removed.
|
|
176
203
|
*
|
|
177
|
-
* @see https://learn.microsoft.com/
|
|
204
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/set-container-metadata
|
|
178
205
|
*
|
|
179
206
|
* @param metadata - Replace existing metadata with this value.
|
|
180
207
|
* If no value provided the existing metadata will be removed.
|
|
@@ -182,7 +209,10 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
182
209
|
*/
|
|
183
210
|
async setMetadata(metadata, options = {}) {
|
|
184
211
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-setMetadata", options, async (updatedOptions) => {
|
|
185
|
-
return this.blobContainerClient.setMetadata(metadata,
|
|
212
|
+
return this.blobContainerClient.setMetadata(metadata, {
|
|
213
|
+
...options,
|
|
214
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
215
|
+
});
|
|
186
216
|
});
|
|
187
217
|
}
|
|
188
218
|
/**
|
|
@@ -192,13 +222,16 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
192
222
|
* WARNING: JavaScript Date will potentially lose precision when parsing startsOn and expiresOn strings.
|
|
193
223
|
* For example, new Date("2018-12-31T03:44:23.8827891Z").toISOString() will get "2018-12-31T03:44:23.882Z".
|
|
194
224
|
*
|
|
195
|
-
* @see https://learn.microsoft.com/
|
|
225
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/get-container-acl
|
|
196
226
|
*
|
|
197
227
|
* @param options - Optional. Options when getting file system access policy.
|
|
198
228
|
*/
|
|
199
229
|
async getAccessPolicy(options = {}) {
|
|
200
230
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-getAccessPolicy", options, async (updatedOptions) => {
|
|
201
|
-
const rawResponse = await this.blobContainerClient.getAccessPolicy(
|
|
231
|
+
const rawResponse = await this.blobContainerClient.getAccessPolicy({
|
|
232
|
+
...options,
|
|
233
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
234
|
+
});
|
|
202
235
|
// Transfer and rename blobPublicAccess to publicAccess
|
|
203
236
|
const response = rawResponse;
|
|
204
237
|
response.publicAccess = (0, transforms_js_1.toPublicAccessType)(rawResponse.blobPublicAccess);
|
|
@@ -216,7 +249,7 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
216
249
|
* If no access or containerAcl provided, the existing file system ACL will be
|
|
217
250
|
* removed.
|
|
218
251
|
*
|
|
219
|
-
* @see https://learn.microsoft.com/
|
|
252
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/set-container-acl
|
|
220
253
|
*
|
|
221
254
|
* @param access - Optional. The level of public access to data in the file system.
|
|
222
255
|
* @param fileSystemAcl - Optional. Array of elements each having a unique Id and details of the access policy.
|
|
@@ -224,7 +257,10 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
224
257
|
*/
|
|
225
258
|
async setAccessPolicy(access, fileSystemAcl, options = {}) {
|
|
226
259
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-setAccessPolicy", options, async (updatedOptions) => {
|
|
227
|
-
return this.blobContainerClient.setAccessPolicy((0, transforms_js_1.toContainerPublicAccessType)(access), fileSystemAcl,
|
|
260
|
+
return this.blobContainerClient.setAccessPolicy((0, transforms_js_1.toContainerPublicAccessType)(access), fileSystemAcl, {
|
|
261
|
+
...options,
|
|
262
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
263
|
+
});
|
|
228
264
|
});
|
|
229
265
|
}
|
|
230
266
|
/**
|
|
@@ -356,49 +392,44 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
356
392
|
return this;
|
|
357
393
|
},
|
|
358
394
|
byPage: (settings = {}) => {
|
|
359
|
-
return this.listSegments(settings.continuationToken,
|
|
395
|
+
return this.listSegments(settings.continuationToken, {
|
|
396
|
+
maxResults: settings.maxPageSize,
|
|
397
|
+
...options,
|
|
398
|
+
});
|
|
360
399
|
},
|
|
361
400
|
};
|
|
362
401
|
}
|
|
363
|
-
listItems() {
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
for (var _d = true, _e = tslib_1.__asyncValues(this.listSegments(undefined, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
|
|
368
|
-
_c = _f.value;
|
|
369
|
-
_d = false;
|
|
370
|
-
const response = _c;
|
|
371
|
-
yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(response.pathItems || [])));
|
|
372
|
-
}
|
|
373
|
-
}
|
|
374
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
375
|
-
finally {
|
|
376
|
-
try {
|
|
377
|
-
if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
|
|
378
|
-
}
|
|
379
|
-
finally { if (e_1) throw e_1.error; }
|
|
380
|
-
}
|
|
381
|
-
});
|
|
402
|
+
async *listItems(options = {}) {
|
|
403
|
+
for await (const response of this.listSegments(undefined, options)) {
|
|
404
|
+
yield* response.pathItems || [];
|
|
405
|
+
}
|
|
382
406
|
}
|
|
383
|
-
listSegments(
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
}
|
|
393
|
-
});
|
|
407
|
+
async *listSegments(continuation, options = {}) {
|
|
408
|
+
let response;
|
|
409
|
+
if (!!continuation || continuation === undefined) {
|
|
410
|
+
do {
|
|
411
|
+
response = await this.listPathsSegment(continuation, options);
|
|
412
|
+
continuation = response.continuation;
|
|
413
|
+
yield response;
|
|
414
|
+
} while (continuation);
|
|
415
|
+
}
|
|
394
416
|
}
|
|
395
417
|
async listPathsSegment(continuation, options = {}) {
|
|
396
418
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-listPathsSegment", options, async (updatedOptions) => {
|
|
397
|
-
const rawResponse = await this.fileSystemContext.listPaths(options.recursive || false,
|
|
419
|
+
const rawResponse = await this.fileSystemContext.listPaths(options.recursive || false, {
|
|
420
|
+
continuation,
|
|
421
|
+
...updatedOptions,
|
|
422
|
+
upn: options.userPrincipalName,
|
|
423
|
+
});
|
|
398
424
|
const response = rawResponse;
|
|
399
425
|
response.pathItems = [];
|
|
400
426
|
for (const path of rawResponse.paths || []) {
|
|
401
|
-
response.pathItems.push(
|
|
427
|
+
response.pathItems.push({
|
|
428
|
+
...path,
|
|
429
|
+
permissions: (0, transforms_js_1.toPermissions)(path.permissions),
|
|
430
|
+
createdOn: (0, utils_common_js_1.windowsFileTimeTicksToTime)(path.creationTime),
|
|
431
|
+
expiresOn: (0, utils_common_js_1.windowsFileTimeTicksToTime)(path.expiryTime),
|
|
432
|
+
});
|
|
402
433
|
}
|
|
403
434
|
delete rawResponse.paths;
|
|
404
435
|
return response;
|
|
@@ -534,45 +565,35 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
534
565
|
return this;
|
|
535
566
|
},
|
|
536
567
|
byPage: (settings = {}) => {
|
|
537
|
-
return this.listDeletedSegments(settings.continuationToken,
|
|
568
|
+
return this.listDeletedSegments(settings.continuationToken, {
|
|
569
|
+
maxResults: settings.maxPageSize,
|
|
570
|
+
...options,
|
|
571
|
+
});
|
|
538
572
|
},
|
|
539
573
|
};
|
|
540
574
|
}
|
|
541
|
-
listDeletedItems() {
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
for (var _d = true, _e = tslib_1.__asyncValues(this.listDeletedSegments(undefined, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
|
|
546
|
-
_c = _f.value;
|
|
547
|
-
_d = false;
|
|
548
|
-
const response = _c;
|
|
549
|
-
yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(response.pathItems || [])));
|
|
550
|
-
}
|
|
551
|
-
}
|
|
552
|
-
catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
|
553
|
-
finally {
|
|
554
|
-
try {
|
|
555
|
-
if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
|
|
556
|
-
}
|
|
557
|
-
finally { if (e_2) throw e_2.error; }
|
|
558
|
-
}
|
|
559
|
-
});
|
|
575
|
+
async *listDeletedItems(options = {}) {
|
|
576
|
+
for await (const response of this.listDeletedSegments(undefined, options)) {
|
|
577
|
+
yield* response.pathItems || [];
|
|
578
|
+
}
|
|
560
579
|
}
|
|
561
|
-
listDeletedSegments(
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
}
|
|
571
|
-
});
|
|
580
|
+
async *listDeletedSegments(continuation, options = {}) {
|
|
581
|
+
let response;
|
|
582
|
+
if (!!continuation || continuation === undefined) {
|
|
583
|
+
do {
|
|
584
|
+
response = await this.listDeletedPathsSegment(continuation, options);
|
|
585
|
+
continuation = response.continuation;
|
|
586
|
+
yield response;
|
|
587
|
+
} while (continuation);
|
|
588
|
+
}
|
|
572
589
|
}
|
|
573
590
|
async listDeletedPathsSegment(continuation, options = {}) {
|
|
574
591
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-listDeletedPathsSegment", options, async (updatedOptions) => {
|
|
575
|
-
const rawResponse = await this.fileSystemContextToBlobEndpoint.listBlobHierarchySegment(
|
|
592
|
+
const rawResponse = await this.fileSystemContextToBlobEndpoint.listBlobHierarchySegment({
|
|
593
|
+
marker: continuation,
|
|
594
|
+
...updatedOptions,
|
|
595
|
+
prefix: options.prefix === "" ? undefined : options.prefix,
|
|
596
|
+
});
|
|
576
597
|
const response = rawResponse;
|
|
577
598
|
response.pathItems = [];
|
|
578
599
|
for (const path of rawResponse.segment.blobItems || []) {
|
|
@@ -592,7 +613,7 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
592
613
|
/**
|
|
593
614
|
* Restores a soft deleted path.
|
|
594
615
|
*
|
|
595
|
-
* @see https://learn.microsoft.com/
|
|
616
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/undelete-blob
|
|
596
617
|
*
|
|
597
618
|
* @param deletedPath - Required. The path of the deleted path.
|
|
598
619
|
*
|
|
@@ -602,12 +623,22 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
602
623
|
async undeletePath(deletedPath, deletionId, options = {}) {
|
|
603
624
|
return tracing_js_1.tracingClient.withSpan("DataLakeFileSystemClient-undeletePath", options, async (updatedOptions) => {
|
|
604
625
|
const pathClient = new PathClientInternal_js_1.PathClientInternal((0, utils_common_js_1.appendToURLPath)(this.blobEndpointUrl, (0, utils_common_js_1.EscapePath)(deletedPath)), this.pipeline);
|
|
605
|
-
const rawResponse = (0, utils_common_js_1.assertResponse)(await pathClient.blobPathContext.undelete(
|
|
626
|
+
const rawResponse = (0, utils_common_js_1.assertResponse)(await pathClient.blobPathContext.undelete({
|
|
627
|
+
undeleteSource: "?" + constants_js_1.DeletionIdKey + "=" + deletionId,
|
|
628
|
+
...options,
|
|
629
|
+
tracingOptions: updatedOptions.tracingOptions,
|
|
630
|
+
}));
|
|
606
631
|
if (rawResponse.resourceType === constants_js_1.PathResultTypeConstants.DirectoryResourceType) {
|
|
607
|
-
return
|
|
632
|
+
return {
|
|
633
|
+
pathClient: this.getDirectoryClient(deletedPath),
|
|
634
|
+
...rawResponse,
|
|
635
|
+
};
|
|
608
636
|
}
|
|
609
637
|
else {
|
|
610
|
-
return
|
|
638
|
+
return {
|
|
639
|
+
pathClient: this.getFileClient(deletedPath),
|
|
640
|
+
...rawResponse,
|
|
641
|
+
};
|
|
611
642
|
}
|
|
612
643
|
});
|
|
613
644
|
}
|
|
@@ -617,7 +648,7 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
617
648
|
* Generates a Service Shared Access Signature (SAS) URI based on the client properties
|
|
618
649
|
* and parameters passed in. The SAS is signed by the shared key credential of the client.
|
|
619
650
|
*
|
|
620
|
-
* @see https://learn.microsoft.com/
|
|
651
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/constructing-a-service-sas
|
|
621
652
|
*
|
|
622
653
|
* @param options - Optional parameters.
|
|
623
654
|
* @returns The SAS URI consisting of the URI to the resource represented by this client, followed by the generated SAS token.
|
|
@@ -627,7 +658,10 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
627
658
|
if (!(this.credential instanceof StorageSharedKeyCredential_js_1.StorageSharedKeyCredential)) {
|
|
628
659
|
throw RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
629
660
|
}
|
|
630
|
-
const sas = (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParameters)(
|
|
661
|
+
const sas = (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParameters)({
|
|
662
|
+
fileSystemName: this.name,
|
|
663
|
+
...options,
|
|
664
|
+
}, this.credential).toString();
|
|
631
665
|
resolve((0, utils_common_js_1.appendToURLQuery)(this.url, sas));
|
|
632
666
|
});
|
|
633
667
|
}
|
|
@@ -637,7 +671,7 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
637
671
|
* Generates string to sign for a Service Shared Access Signature (SAS) URI based on the client properties
|
|
638
672
|
* and parameters passed in. The SAS is signed by the shared key credential of the client.
|
|
639
673
|
*
|
|
640
|
-
* @see https://learn.microsoft.com/
|
|
674
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/constructing-a-service-sas
|
|
641
675
|
*
|
|
642
676
|
* @param options - Optional parameters.
|
|
643
677
|
* @returns The SAS URI consisting of the URI to the resource represented by this client, followed by the generated SAS token.
|
|
@@ -647,13 +681,16 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
647
681
|
if (!(this.credential instanceof StorageSharedKeyCredential_js_1.StorageSharedKeyCredential)) {
|
|
648
682
|
throw RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
649
683
|
}
|
|
650
|
-
return (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParametersInternal)(
|
|
684
|
+
return (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParametersInternal)({
|
|
685
|
+
fileSystemName: this.name,
|
|
686
|
+
...options,
|
|
687
|
+
}, this.credential).stringToSign;
|
|
651
688
|
}
|
|
652
689
|
/**
|
|
653
690
|
* Generates a Service Shared Access Signature (SAS) URI based on the client properties
|
|
654
691
|
* and parameters passed in. The SAS is signed by the input user delegation key.
|
|
655
692
|
*
|
|
656
|
-
* @see https://learn.microsoft.com/
|
|
693
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/constructing-a-service-sas
|
|
657
694
|
*
|
|
658
695
|
* @param options - Optional parameters.
|
|
659
696
|
* @param userDelegationKey - Return value of `blobServiceClient.getUserDelegationKey()`
|
|
@@ -661,7 +698,10 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
661
698
|
*/
|
|
662
699
|
generateUserDelegationSasUrl(options, userDelegationKey) {
|
|
663
700
|
return new Promise((resolve) => {
|
|
664
|
-
const sas = (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParameters)(
|
|
701
|
+
const sas = (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParameters)({
|
|
702
|
+
fileSystemName: this.name,
|
|
703
|
+
...options,
|
|
704
|
+
}, userDelegationKey, this.accountName).toString();
|
|
665
705
|
resolve((0, utils_common_js_1.appendToURLQuery)(this.url, sas));
|
|
666
706
|
});
|
|
667
707
|
}
|
|
@@ -669,14 +709,17 @@ class DataLakeFileSystemClient extends StorageClient_js_1.StorageClient {
|
|
|
669
709
|
* Generates string to sign for a Service Shared Access Signature (SAS) URI based on the client properties
|
|
670
710
|
* and parameters passed in. The SAS is signed by the input user delegation key.
|
|
671
711
|
*
|
|
672
|
-
* @see https://learn.microsoft.com/
|
|
712
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/constructing-a-service-sas
|
|
673
713
|
*
|
|
674
714
|
* @param options - Optional parameters.
|
|
675
715
|
* @param userDelegationKey - Return value of `blobServiceClient.getUserDelegationKey()`
|
|
676
716
|
* @returns The SAS URI consisting of the URI to the resource represented by this client, followed by the generated SAS token.
|
|
677
717
|
*/
|
|
678
718
|
generateUserDelegationSasStringToSign(options, userDelegationKey) {
|
|
679
|
-
return (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParametersInternal)(
|
|
719
|
+
return (0, DataLakeSASSignatureValues_js_1.generateDataLakeSASQueryParametersInternal)({
|
|
720
|
+
fileSystemName: this.name,
|
|
721
|
+
...options,
|
|
722
|
+
}, userDelegationKey, this.accountName).stringToSign;
|
|
680
723
|
}
|
|
681
724
|
}
|
|
682
725
|
exports.DataLakeFileSystemClient = DataLakeFileSystemClient;
|