@dremio/js-sdk 0.1.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/LICENSE +202 -0
- package/dist/cloud/arctic/ArcticCatalog.d.ts +34 -0
- package/dist/cloud/arctic/ArcticCatalog.js +46 -0
- package/dist/cloud/arctic/ArcticCatalog.js.map +1 -0
- package/dist/cloud/arctic/ArcticResource.d.ts +15 -0
- package/dist/cloud/arctic/ArcticResource.js +40 -0
- package/dist/cloud/arctic/ArcticResource.js.map +1 -0
- package/dist/cloud/credentials/fromAccessToken.d.ts +2 -0
- package/dist/cloud/credentials/fromAccessToken.js +19 -0
- package/dist/cloud/credentials/fromAccessToken.js.map +1 -0
- package/dist/cloud/credentials/fromRefreshToken.d.ts +5 -0
- package/dist/cloud/credentials/fromRefreshToken.js +47 -0
- package/dist/cloud/credentials/fromRefreshToken.js.map +1 -0
- package/dist/cloud/credentials/fromUsernamePassword.d.ts +2 -0
- package/dist/cloud/credentials/fromUsernamePassword.js +41 -0
- package/dist/cloud/credentials/fromUsernamePassword.js.map +1 -0
- package/dist/cloud/credentials/index.d.ts +4 -0
- package/dist/cloud/credentials/index.js +20 -0
- package/dist/cloud/credentials/index.js.map +1 -0
- package/dist/cloud/engines/Engine.d.ts +47 -0
- package/dist/cloud/engines/Engine.js +58 -0
- package/dist/cloud/engines/Engine.js.map +1 -0
- package/dist/cloud/engines/EnginesResource.d.ts +15 -0
- package/dist/cloud/engines/EnginesResource.js +42 -0
- package/dist/cloud/engines/EnginesResource.js.map +1 -0
- package/dist/cloud/engines/utils.d.ts +17 -0
- package/dist/cloud/engines/utils.js +59 -0
- package/dist/cloud/engines/utils.js.map +1 -0
- package/dist/cloud/index.d.ts +487 -0
- package/dist/cloud/index.js +47 -0
- package/dist/cloud/index.js.map +1 -0
- package/dist/cloud/interfaces.d.ts +13 -0
- package/dist/cloud/interfaces.js +18 -0
- package/dist/cloud/interfaces.js.map +1 -0
- package/dist/cloud/oauth/OAuthApplication.d.ts +26 -0
- package/dist/cloud/oauth/OAuthApplication.js +49 -0
- package/dist/cloud/oauth/OAuthApplication.js.map +1 -0
- package/dist/cloud/oauth/OAuthApplicationsResource.d.ts +15 -0
- package/dist/cloud/oauth/OAuthApplicationsResource.js +66 -0
- package/dist/cloud/oauth/OAuthApplicationsResource.js.map +1 -0
- package/dist/cloud/oauth/oauth.d.ts +32 -0
- package/dist/cloud/oauth/oauth.js +57 -0
- package/dist/cloud/oauth/oauth.js.map +1 -0
- package/dist/cloud/projects/Project.d.ts +49 -0
- package/dist/cloud/projects/Project.js +61 -0
- package/dist/cloud/projects/Project.js.map +1 -0
- package/dist/cloud/projects/ProjectsResource.d.ts +17 -0
- package/dist/cloud/projects/ProjectsResource.js +50 -0
- package/dist/cloud/projects/ProjectsResource.js.map +1 -0
- package/dist/cloud/projects/projectApiMethods.d.ts +9 -0
- package/dist/cloud/projects/projectApiMethods.js +43 -0
- package/dist/cloud/projects/projectApiMethods.js.map +1 -0
- package/dist/cloud/projects/utils.d.ts +2 -0
- package/dist/cloud/projects/utils.js +37 -0
- package/dist/cloud/projects/utils.js.map +1 -0
- package/dist/cloud/resources.d.ts +472 -0
- package/dist/cloud/resources.js +41 -0
- package/dist/cloud/resources.js.map +1 -0
- package/dist/cloud/users/CloudUser.d.ts +4 -0
- package/dist/cloud/users/CloudUser.js +27 -0
- package/dist/cloud/users/CloudUser.js.map +1 -0
- package/dist/cloud/users/CloudUsersResource.d.ts +13 -0
- package/dist/cloud/users/CloudUsersResource.js +37 -0
- package/dist/cloud/users/CloudUsersResource.js.map +1 -0
- package/dist/common/Config.d.ts +54 -0
- package/dist/common/Config.js +17 -0
- package/dist/common/Config.js.map +1 -0
- package/dist/common/CredentialProvider.d.ts +4 -0
- package/dist/common/CredentialProvider.js +17 -0
- package/dist/common/CredentialProvider.js.map +1 -0
- package/dist/common/HttpError.d.ts +21 -0
- package/dist/common/HttpError.js +74 -0
- package/dist/common/HttpError.js.map +1 -0
- package/dist/common/Params.d.ts +16 -0
- package/dist/common/Params.js +17 -0
- package/dist/common/Params.js.map +1 -0
- package/dist/common/Problem.d.ts +45 -0
- package/dist/common/Problem.js +37 -0
- package/dist/common/Problem.js.map +1 -0
- package/dist/common/Query.d.ts +6 -0
- package/dist/common/Query.js +30 -0
- package/dist/common/Query.js.map +1 -0
- package/dist/common/batch.d.ts +2 -0
- package/dist/common/batch.js +42 -0
- package/dist/common/batch.js.map +1 -0
- package/dist/common/createRequest.d.ts +6 -0
- package/dist/common/createRequest.js +71 -0
- package/dist/common/createRequest.js.map +1 -0
- package/dist/common/fromAbortable.d.ts +4 -0
- package/dist/common/fromAbortable.js +35 -0
- package/dist/common/fromAbortable.js.map +1 -0
- package/dist/common/problems.d.ts +9 -0
- package/dist/common/problems.js +25 -0
- package/dist/common/problems.js.map +1 -0
- package/dist/common/sharedExports.d.ts +5 -0
- package/dist/common/sharedExports.js +21 -0
- package/dist/common/sharedExports.js.map +1 -0
- package/dist/enterprise/Grantee.d.ts +9 -0
- package/dist/enterprise/Grantee.js +17 -0
- package/dist/enterprise/Grantee.js.map +1 -0
- package/dist/enterprise/Ownable.d.ts +7 -0
- package/dist/enterprise/Ownable.js +17 -0
- package/dist/enterprise/Ownable.js.map +1 -0
- package/dist/enterprise/catalog/CatalogLineage.d.ts +37 -0
- package/dist/enterprise/catalog/CatalogLineage.js +26 -0
- package/dist/enterprise/catalog/CatalogLineage.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseDatasetCatalogObject.d.ts +39 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseDatasetCatalogObject.js +45 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseDatasetCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFileCatalogObject.d.ts +6 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFileCatalogObject.js +22 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFileCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFolderCatalogObject.d.ts +7 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFolderCatalogObject.js +25 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFolderCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFunctionCatalogObject.d.ts +6 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFunctionCatalogObject.js +22 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseFunctionCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseHomeCatalogObject.d.ts +6 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseHomeCatalogObject.js +22 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseHomeCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSourceCatalogObject.d.ts +46 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSourceCatalogObject.js +44 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSourceCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSpaceCatalogObject.d.ts +6 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSpaceCatalogObject.js +22 -0
- package/dist/enterprise/catalog/CatalogObjects/EnterpriseSpaceCatalogObject.js.map +1 -0
- package/dist/enterprise/catalog/CatalogObjects/index.d.ts +10 -0
- package/dist/enterprise/catalog/CatalogObjects/index.js +17 -0
- package/dist/enterprise/catalog/CatalogObjects/index.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseDatasetCatalogReference.d.ts +14 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseDatasetCatalogReference.js +28 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseDatasetCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFileCatalogReference.d.ts +3 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFileCatalogReference.js +19 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFileCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFolderCatalogReference.d.ts +12 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFolderCatalogReference.js +28 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFolderCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFunctionCatalogReference.d.ts +3 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFunctionCatalogReference.js +19 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseFunctionCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseHomeCatalogReference.d.ts +3 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseHomeCatalogReference.js +19 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseHomeCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSourceCatalogReference.d.ts +12 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSourceCatalogReference.js +28 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSourceCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSpaceCatalogReference.d.ts +3 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSpaceCatalogReference.js +19 -0
- package/dist/enterprise/catalog/CatalogReferences/EnterpriseSpaceCatalogReference.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/index.d.ts +9 -0
- package/dist/enterprise/catalog/CatalogReferences/index.js +17 -0
- package/dist/enterprise/catalog/CatalogReferences/index.js.map +1 -0
- package/dist/enterprise/catalog/CatalogReferences/retrieveCatalogGrants.d.ts +15 -0
- package/dist/enterprise/catalog/CatalogReferences/retrieveCatalogGrants.js +30 -0
- package/dist/enterprise/catalog/CatalogReferences/retrieveCatalogGrants.js.map +1 -0
- package/dist/enterprise/catalog/EnterpriseCatalogResource.d.ts +10 -0
- package/dist/enterprise/catalog/EnterpriseCatalogResource.js +38 -0
- package/dist/enterprise/catalog/EnterpriseCatalogResource.js.map +1 -0
- package/dist/enterprise/catalog/catalogObjectFromEntity.d.ts +3 -0
- package/dist/enterprise/catalog/catalogObjectFromEntity.js +73 -0
- package/dist/enterprise/catalog/catalogObjectFromEntity.js.map +1 -0
- package/dist/enterprise/catalog/catalogReferenceFromProperties.d.ts +6 -0
- package/dist/enterprise/catalog/catalogReferenceFromProperties.js +46 -0
- package/dist/enterprise/catalog/catalogReferenceFromProperties.js.map +1 -0
- package/dist/enterprise/catalog/catalogRetrieve.d.ts +5 -0
- package/dist/enterprise/catalog/catalogRetrieve.js +119 -0
- package/dist/enterprise/catalog/catalogRetrieve.js.map +1 -0
- package/dist/enterprise/credentials/exchangePat.d.ts +12 -0
- package/dist/enterprise/credentials/exchangePat.js +55 -0
- package/dist/enterprise/credentials/exchangePat.js.map +1 -0
- package/dist/enterprise/credentials/fromPat.d.ts +2 -0
- package/dist/enterprise/credentials/fromPat.js +36 -0
- package/dist/enterprise/credentials/fromPat.js.map +1 -0
- package/dist/enterprise/credentials/index.d.ts +2 -0
- package/dist/enterprise/credentials/index.js +18 -0
- package/dist/enterprise/credentials/index.js.map +1 -0
- package/dist/enterprise/engines/Engine.d.ts +78 -0
- package/dist/enterprise/engines/Engine.js +75 -0
- package/dist/enterprise/engines/Engine.js.map +1 -0
- package/dist/enterprise/engines/EnginesResource.d.ts +10 -0
- package/dist/enterprise/engines/EnginesResource.js +34 -0
- package/dist/enterprise/engines/EnginesResource.js.map +1 -0
- package/dist/enterprise/index.d.ts +60 -0
- package/dist/enterprise/index.js +43 -0
- package/dist/enterprise/index.js.map +1 -0
- package/dist/enterprise/interfaces.d.ts +12 -0
- package/dist/enterprise/interfaces.js +18 -0
- package/dist/enterprise/interfaces.js.map +1 -0
- package/dist/enterprise/reflections/ReflectionSummary.d.ts +74 -0
- package/dist/enterprise/reflections/ReflectionSummary.js +82 -0
- package/dist/enterprise/reflections/ReflectionSummary.js.map +1 -0
- package/dist/enterprise/resources.d.ts +44 -0
- package/dist/enterprise/resources.js +36 -0
- package/dist/enterprise/resources.js.map +1 -0
- package/dist/enterprise/roles/Role.d.ts +23 -0
- package/dist/enterprise/roles/Role.js +38 -0
- package/dist/enterprise/roles/Role.js.map +1 -0
- package/dist/enterprise/roles/RolesResource.d.ts +8 -0
- package/dist/enterprise/roles/RolesResource.js +32 -0
- package/dist/enterprise/roles/RolesResource.js.map +1 -0
- package/dist/enterprise/scripts/EnterpriseScript.d.ts +46 -0
- package/dist/enterprise/scripts/EnterpriseScript.js +62 -0
- package/dist/enterprise/scripts/EnterpriseScript.js.map +1 -0
- package/dist/enterprise/scripts/EnterpriseScriptsResource.d.ts +15 -0
- package/dist/enterprise/scripts/EnterpriseScriptsResource.js +72 -0
- package/dist/enterprise/scripts/EnterpriseScriptsResource.js.map +1 -0
- package/dist/enterprise/users/EnterpriseUser.d.ts +23 -0
- package/dist/enterprise/users/EnterpriseUser.js +43 -0
- package/dist/enterprise/users/EnterpriseUser.js.map +1 -0
- package/dist/enterprise/users/EnterpriseUsersResource.d.ts +11 -0
- package/dist/enterprise/users/EnterpriseUsersResource.js +32 -0
- package/dist/enterprise/users/EnterpriseUsersResource.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/DatasetCatalogObject.d.ts +43 -0
- package/dist/oss/catalog/CatalogObjects/DatasetCatalogObject.js +56 -0
- package/dist/oss/catalog/CatalogObjects/DatasetCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/FileCatalogObject.d.ts +17 -0
- package/dist/oss/catalog/CatalogObjects/FileCatalogObject.js +48 -0
- package/dist/oss/catalog/CatalogObjects/FileCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/FolderCatalogObject.d.ts +20 -0
- package/dist/oss/catalog/CatalogObjects/FolderCatalogObject.js +48 -0
- package/dist/oss/catalog/CatalogObjects/FolderCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/FunctionCatalogObject.d.ts +17 -0
- package/dist/oss/catalog/CatalogObjects/FunctionCatalogObject.js +47 -0
- package/dist/oss/catalog/CatalogObjects/FunctionCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/HomeCatalogObject.d.ts +18 -0
- package/dist/oss/catalog/CatalogObjects/HomeCatalogObject.js +48 -0
- package/dist/oss/catalog/CatalogObjects/HomeCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/SourceCatalogObject.d.ts +60 -0
- package/dist/oss/catalog/CatalogObjects/SourceCatalogObject.js +95 -0
- package/dist/oss/catalog/CatalogObjects/SourceCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/SpaceCatalogObject.d.ts +19 -0
- package/dist/oss/catalog/CatalogObjects/SpaceCatalogObject.js +53 -0
- package/dist/oss/catalog/CatalogObjects/SpaceCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/VersionedDatasetCatalogObject.d.ts +31 -0
- package/dist/oss/catalog/CatalogObjects/VersionedDatasetCatalogObject.js +58 -0
- package/dist/oss/catalog/CatalogObjects/VersionedDatasetCatalogObject.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/index.d.ts +10 -0
- package/dist/oss/catalog/CatalogObjects/index.js +17 -0
- package/dist/oss/catalog/CatalogObjects/index.js.map +1 -0
- package/dist/oss/catalog/CatalogObjects/utils/catalogObjectFromEntity.d.ts +11 -0
- package/dist/oss/catalog/CatalogObjects/utils/catalogObjectFromEntity.js +73 -0
- package/dist/oss/catalog/CatalogObjects/utils/catalogObjectFromEntity.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/BaseCatalogReference.d.ts +16 -0
- package/dist/oss/catalog/CatalogReferences/BaseCatalogReference.js +34 -0
- package/dist/oss/catalog/CatalogReferences/BaseCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/DatasetCatalogReference.d.ts +17 -0
- package/dist/oss/catalog/CatalogReferences/DatasetCatalogReference.js +39 -0
- package/dist/oss/catalog/CatalogReferences/DatasetCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/FileCatalogReference.d.ts +9 -0
- package/dist/oss/catalog/CatalogReferences/FileCatalogReference.js +28 -0
- package/dist/oss/catalog/CatalogReferences/FileCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/FolderCatalogReference.d.ts +22 -0
- package/dist/oss/catalog/CatalogReferences/FolderCatalogReference.js +40 -0
- package/dist/oss/catalog/CatalogReferences/FolderCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/FunctionCatalogReference.d.ts +9 -0
- package/dist/oss/catalog/CatalogReferences/FunctionCatalogReference.js +28 -0
- package/dist/oss/catalog/CatalogReferences/FunctionCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/HomeCatalogReference.d.ts +20 -0
- package/dist/oss/catalog/CatalogReferences/HomeCatalogReference.js +38 -0
- package/dist/oss/catalog/CatalogReferences/HomeCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/SourceCatalogReference.d.ts +24 -0
- package/dist/oss/catalog/CatalogReferences/SourceCatalogReference.js +61 -0
- package/dist/oss/catalog/CatalogReferences/SourceCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/SpaceCatalogReference.d.ts +20 -0
- package/dist/oss/catalog/CatalogReferences/SpaceCatalogReference.js +38 -0
- package/dist/oss/catalog/CatalogReferences/SpaceCatalogReference.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/index.d.ts +9 -0
- package/dist/oss/catalog/CatalogReferences/index.js +17 -0
- package/dist/oss/catalog/CatalogReferences/index.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogChildren.d.ts +14 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogChildren.js +62 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogChildren.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceEntityToProperties.d.ts +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceEntityToProperties.js +42 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceEntityToProperties.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceFromProperties.d.ts +6 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceFromProperties.js +45 -0
- package/dist/oss/catalog/CatalogReferences/utils/catalogReferenceFromProperties.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/getTags.d.ts +5 -0
- package/dist/oss/catalog/CatalogReferences/utils/getTags.js +23 -0
- package/dist/oss/catalog/CatalogReferences/utils/getTags.js.map +1 -0
- package/dist/oss/catalog/CatalogReferences/utils/getWiki.d.ts +5 -0
- package/dist/oss/catalog/CatalogReferences/utils/getWiki.js +23 -0
- package/dist/oss/catalog/CatalogReferences/utils/getWiki.js.map +1 -0
- package/dist/oss/catalog/CatalogResource.d.ts +10 -0
- package/dist/oss/catalog/CatalogResource.js +38 -0
- package/dist/oss/catalog/CatalogResource.js.map +1 -0
- package/dist/oss/catalog/CatalogTags.d.ts +26 -0
- package/dist/oss/catalog/CatalogTags.js +60 -0
- package/dist/oss/catalog/CatalogTags.js.map +1 -0
- package/dist/oss/catalog/CatalogWiki.d.ts +26 -0
- package/dist/oss/catalog/CatalogWiki.js +60 -0
- package/dist/oss/catalog/CatalogWiki.js.map +1 -0
- package/dist/oss/catalog/VersionReference.d.ts +13 -0
- package/dist/oss/catalog/VersionReference.js +19 -0
- package/dist/oss/catalog/VersionReference.js.map +1 -0
- package/dist/oss/catalog/catalogErrors.d.ts +18 -0
- package/dist/oss/catalog/catalogErrors.js +36 -0
- package/dist/oss/catalog/catalogErrors.js.map +1 -0
- package/dist/oss/catalog/catalogRetrieve.d.ts +6 -0
- package/dist/oss/catalog/catalogRetrieve.js +119 -0
- package/dist/oss/catalog/catalogRetrieve.js.map +1 -0
- package/dist/oss/credentials/fromUsernamePassword.d.ts +2 -0
- package/dist/oss/credentials/fromUsernamePassword.js +41 -0
- package/dist/oss/credentials/fromUsernamePassword.js.map +1 -0
- package/dist/oss/credentials/index.d.ts +1 -0
- package/dist/oss/credentials/index.js +17 -0
- package/dist/oss/credentials/index.js.map +1 -0
- package/dist/oss/index.d.ts +55 -0
- package/dist/oss/index.js +42 -0
- package/dist/oss/index.js.map +1 -0
- package/dist/oss/interfaces.d.ts +8 -0
- package/dist/oss/interfaces.js +18 -0
- package/dist/oss/interfaces.js.map +1 -0
- package/dist/oss/jobs/Job.d.ts +71 -0
- package/dist/oss/jobs/Job.js +133 -0
- package/dist/oss/jobs/Job.js.map +1 -0
- package/dist/oss/jobs/JobsResource.d.ts +10 -0
- package/dist/oss/jobs/JobsResource.js +74 -0
- package/dist/oss/jobs/JobsResource.js.map +1 -0
- package/dist/oss/jobs/utils/JobResultsResponse.d.ts +85 -0
- package/dist/oss/jobs/utils/JobResultsResponse.js +17 -0
- package/dist/oss/jobs/utils/JobResultsResponse.js.map +1 -0
- package/dist/oss/jobs/utils/createArrayForFieldType.d.ts +2 -0
- package/dist/oss/jobs/utils/createArrayForFieldType.js +55 -0
- package/dist/oss/jobs/utils/createArrayForFieldType.js.map +1 -0
- package/dist/oss/jobs/utils/createColumnRecordFromSchema.d.ts +2 -0
- package/dist/oss/jobs/utils/createColumnRecordFromSchema.js +21 -0
- package/dist/oss/jobs/utils/createColumnRecordFromSchema.js.map +1 -0
- package/dist/oss/jobs/utils/mapRowData.d.ts +3 -0
- package/dist/oss/jobs/utils/mapRowData.js +46 -0
- package/dist/oss/jobs/utils/mapRowData.js.map +1 -0
- package/dist/oss/jobs/utils/mapRowsToColumns.d.ts +2 -0
- package/dist/oss/jobs/utils/mapRowsToColumns.js +27 -0
- package/dist/oss/jobs/utils/mapRowsToColumns.js.map +1 -0
- package/dist/oss/reflections/Reflection.d.ts +60 -0
- package/dist/oss/reflections/Reflection.js +41 -0
- package/dist/oss/reflections/Reflection.js.map +1 -0
- package/dist/oss/resources.d.ts +38 -0
- package/dist/oss/resources.js +30 -0
- package/dist/oss/resources.js.map +1 -0
- package/dist/oss/scripts/Script.d.ts +64 -0
- package/dist/oss/scripts/Script.js +94 -0
- package/dist/oss/scripts/Script.js.map +1 -0
- package/dist/oss/scripts/ScriptErrors.d.ts +19 -0
- package/dist/oss/scripts/ScriptErrors.js +37 -0
- package/dist/oss/scripts/ScriptErrors.js.map +1 -0
- package/dist/oss/scripts/ScriptsResource.d.ts +15 -0
- package/dist/oss/scripts/ScriptsResource.js +72 -0
- package/dist/oss/scripts/ScriptsResource.js.map +1 -0
- package/dist/oss/users/User.d.ts +30 -0
- package/dist/oss/users/User.js +60 -0
- package/dist/oss/users/User.js.map +1 -0
- package/dist/oss/users/UsersResource.d.ts +11 -0
- package/dist/oss/users/UsersResource.js +32 -0
- package/dist/oss/users/UsersResource.js.map +1 -0
- package/package.json +70 -0
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
type VarcharType = {
|
|
2
|
+
name: "VARCHAR";
|
|
3
|
+
};
|
|
4
|
+
type TextType = {
|
|
5
|
+
name: "TEXT";
|
|
6
|
+
};
|
|
7
|
+
type BinaryType = {
|
|
8
|
+
name: "BINARY";
|
|
9
|
+
};
|
|
10
|
+
type VarbinaryType = {
|
|
11
|
+
name: "VARBINARY";
|
|
12
|
+
};
|
|
13
|
+
type FloatType = {
|
|
14
|
+
name: "FLOAT";
|
|
15
|
+
};
|
|
16
|
+
type DecimalType = {
|
|
17
|
+
name: "DECIMAL";
|
|
18
|
+
};
|
|
19
|
+
type IntegerType = {
|
|
20
|
+
name: "INTEGER";
|
|
21
|
+
};
|
|
22
|
+
type MixedType = {
|
|
23
|
+
name: "MIXED";
|
|
24
|
+
};
|
|
25
|
+
type UnionType = {
|
|
26
|
+
name: "UNION";
|
|
27
|
+
};
|
|
28
|
+
type DateType = {
|
|
29
|
+
name: "DATE";
|
|
30
|
+
};
|
|
31
|
+
type TimeType = {
|
|
32
|
+
name: "TIME";
|
|
33
|
+
};
|
|
34
|
+
type DatetimeType = {
|
|
35
|
+
name: "DATETIME";
|
|
36
|
+
};
|
|
37
|
+
type MapType = {
|
|
38
|
+
name: "MAP";
|
|
39
|
+
};
|
|
40
|
+
type GeoType = {
|
|
41
|
+
name: "GEO";
|
|
42
|
+
};
|
|
43
|
+
type OtherType = {
|
|
44
|
+
name: "OTHER";
|
|
45
|
+
};
|
|
46
|
+
type AnyType = {
|
|
47
|
+
name: "ANY";
|
|
48
|
+
};
|
|
49
|
+
type DoubleType = {
|
|
50
|
+
name: "DOUBLE";
|
|
51
|
+
};
|
|
52
|
+
type BigintType = {
|
|
53
|
+
name: "BIGINT";
|
|
54
|
+
};
|
|
55
|
+
type BooleanType = {
|
|
56
|
+
name: "BOOLEAN";
|
|
57
|
+
};
|
|
58
|
+
type TimestampType = {
|
|
59
|
+
name: "TIMESTAMP";
|
|
60
|
+
};
|
|
61
|
+
type SimpleTypes = VarcharType | DoubleType | BigintType | BooleanType | TimestampType | TextType | BinaryType | VarbinaryType | FloatType | DecimalType | IntegerType | MixedType | UnionType | DateType | TimeType | DatetimeType | MapType | GeoType | OtherType | AnyType;
|
|
62
|
+
type ListType = {
|
|
63
|
+
name: "LIST";
|
|
64
|
+
subSchema: {
|
|
65
|
+
type: SimpleTypes | ComplexTypes;
|
|
66
|
+
}[];
|
|
67
|
+
};
|
|
68
|
+
type StructType = {
|
|
69
|
+
name: "STRUCT";
|
|
70
|
+
subSchema: {
|
|
71
|
+
name: string;
|
|
72
|
+
type: SimpleTypes | ComplexTypes;
|
|
73
|
+
}[];
|
|
74
|
+
};
|
|
75
|
+
type ComplexTypes = ListType | StructType;
|
|
76
|
+
export type JobResultsSchema<TName extends string> = {
|
|
77
|
+
name: TName;
|
|
78
|
+
type: SimpleTypes | ComplexTypes;
|
|
79
|
+
}[];
|
|
80
|
+
export type JobResultsResponse<T extends Record<string, unknown> = Record<string, unknown>> = {
|
|
81
|
+
rowCount: number;
|
|
82
|
+
rows: T[];
|
|
83
|
+
schema: JobResultsSchema<Extract<keyof T, string>>;
|
|
84
|
+
};
|
|
85
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
export {};
|
|
17
|
+
//# sourceMappingURL=JobResultsResponse.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"JobResultsResponse.js","sourceRoot":"","sources":["../../../../src/oss/jobs/utils/JobResultsResponse.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\ntype VarcharType = {\n name: \"VARCHAR\";\n};\n\ntype TextType = {\n name: \"TEXT\";\n};\n\ntype BinaryType = {\n name: \"BINARY\";\n};\n\ntype VarbinaryType = {\n name: \"VARBINARY\";\n};\n\ntype FloatType = {\n name: \"FLOAT\";\n};\n\ntype DecimalType = {\n name: \"DECIMAL\";\n};\n\ntype IntegerType = {\n name: \"INTEGER\";\n};\n\ntype MixedType = {\n name: \"MIXED\";\n};\n\ntype UnionType = {\n name: \"UNION\";\n};\n\ntype DateType = {\n name: \"DATE\";\n};\n\ntype TimeType = {\n name: \"TIME\";\n};\n\ntype DatetimeType = {\n name: \"DATETIME\";\n};\n\ntype MapType = {\n name: \"MAP\";\n};\n\ntype GeoType = {\n name: \"GEO\";\n};\n\ntype OtherType = {\n name: \"OTHER\";\n};\n\ntype AnyType = {\n name: \"ANY\";\n};\n\ntype DoubleType = {\n name: \"DOUBLE\";\n};\n\ntype BigintType = {\n name: \"BIGINT\";\n};\n\ntype BooleanType = {\n name: \"BOOLEAN\";\n};\n\ntype TimestampType = {\n name: \"TIMESTAMP\";\n};\n\ntype SimpleTypes =\n | VarcharType\n | DoubleType\n | BigintType\n | BooleanType\n | TimestampType\n | TextType\n | BinaryType\n | VarbinaryType\n | FloatType\n | DecimalType\n | IntegerType\n | MixedType\n | UnionType\n | DateType\n | TimeType\n | DatetimeType\n | MapType\n | GeoType\n | OtherType\n | AnyType;\n\ntype ListType = {\n name: \"LIST\";\n subSchema: {\n type: SimpleTypes | ComplexTypes;\n }[];\n};\n\ntype StructType = {\n name: \"STRUCT\";\n subSchema: {\n name: string;\n type: SimpleTypes | ComplexTypes;\n }[];\n};\n\ntype ComplexTypes = ListType | StructType;\n\nexport type JobResultsSchema<TName extends string> = {\n name: TName;\n type: SimpleTypes | ComplexTypes;\n}[];\n\nexport type JobResultsResponse<T extends Record<string, unknown> = Record<string, unknown>> = {\n rowCount: number;\n rows: T[];\n schema: JobResultsSchema<Extract<keyof T, string>>;\n};\n"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import type { JobResultsResponse } from "./JobResultsResponse.ts";
|
|
2
|
+
export declare const createArrayForFieldType: <T extends Record<string, unknown>>(type: JobResultsResponse<T>["schema"][number]["type"], length: number) => unknown[] | Float64Array<ArrayBuffer> | Float32Array<ArrayBuffer> | Int32Array<ArrayBuffer>;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
export const createArrayForFieldType = (type, length) => {
|
|
17
|
+
switch (type.name) {
|
|
18
|
+
case "ANY":
|
|
19
|
+
case "BINARY":
|
|
20
|
+
case "GEO":
|
|
21
|
+
case "MAP":
|
|
22
|
+
case "MIXED":
|
|
23
|
+
case "OTHER":
|
|
24
|
+
case "UNION":
|
|
25
|
+
case "VARBINARY":
|
|
26
|
+
return new Array(length);
|
|
27
|
+
case "BOOLEAN":
|
|
28
|
+
return new Array(length);
|
|
29
|
+
case "DATE":
|
|
30
|
+
case "DATETIME":
|
|
31
|
+
case "DECIMAL":
|
|
32
|
+
case "TEXT":
|
|
33
|
+
case "TIME":
|
|
34
|
+
case "TIMESTAMP":
|
|
35
|
+
case "VARCHAR":
|
|
36
|
+
return new Array(length);
|
|
37
|
+
case "BIGINT":
|
|
38
|
+
return new Array(length);
|
|
39
|
+
case "DOUBLE":
|
|
40
|
+
return new Float64Array(length);
|
|
41
|
+
case "FLOAT":
|
|
42
|
+
return new Float32Array(length);
|
|
43
|
+
case "INTEGER":
|
|
44
|
+
return new Int32Array(length);
|
|
45
|
+
case "LIST":
|
|
46
|
+
return new Array(length);
|
|
47
|
+
case "STRUCT":
|
|
48
|
+
return new Array(length);
|
|
49
|
+
default:
|
|
50
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
51
|
+
//@ts-expect-error
|
|
52
|
+
throw new Error(`Unknown field type ${type.name}`);
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
//# sourceMappingURL=createArrayForFieldType.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createArrayForFieldType.js","sourceRoot":"","sources":["../../../../src/oss/jobs/utils/createArrayForFieldType.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAIH,MAAM,CAAC,MAAM,uBAAuB,GAAG,CACrC,IAAqD,EACrD,MAAc,EACd,EAAE;IACF,QAAQ,IAAI,CAAC,IAAI,EAAE,CAAC;QAClB,KAAK,KAAK,CAAC;QACX,KAAK,QAAQ,CAAC;QACd,KAAK,KAAK,CAAC;QACX,KAAK,KAAK,CAAC;QACX,KAAK,OAAO,CAAC;QACb,KAAK,OAAO,CAAC;QACb,KAAK,OAAO,CAAC;QACb,KAAK,WAAW;YACd,OAAO,IAAI,KAAK,CAAU,MAAM,CAAC,CAAC;QACpC,KAAK,SAAS;YACZ,OAAO,IAAI,KAAK,CAAU,MAAM,CAAC,CAAC;QACpC,KAAK,MAAM,CAAC;QACZ,KAAK,UAAU,CAAC;QAChB,KAAK,SAAS,CAAC;QACf,KAAK,MAAM,CAAC;QACZ,KAAK,MAAM,CAAC;QACZ,KAAK,WAAW,CAAC;QACjB,KAAK,SAAS;YACZ,OAAO,IAAI,KAAK,CAAS,MAAM,CAAC,CAAC;QACnC,KAAK,QAAQ;YACX,OAAO,IAAI,KAAK,CAAgB,MAAM,CAAC,CAAC;QAC1C,KAAK,QAAQ;YACX,OAAO,IAAI,YAAY,CAAC,MAAM,CAAC,CAAC;QAClC,KAAK,OAAO;YACV,OAAO,IAAI,YAAY,CAAC,MAAM,CAAC,CAAC;QAClC,KAAK,SAAS;YACZ,OAAO,IAAI,UAAU,CAAC,MAAM,CAAC,CAAC;QAChC,KAAK,MAAM;YACT,OAAO,IAAI,KAAK,CAAY,MAAM,CAAC,CAAC;QACtC,KAAK,QAAQ;YACX,OAAO,IAAI,KAAK,CAA0B,MAAM,CAAC,CAAC;QACpD;YACE,6DAA6D;YAC7D,kBAAkB;YAClB,MAAM,IAAI,KAAK,CAAC,sBAAsB,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;IACvD,CAAC;AACH,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { JobResultsResponse } from \"./JobResultsResponse.ts\";\n\nexport const createArrayForFieldType = <T extends Record<string, unknown>>(\n type: JobResultsResponse<T>[\"schema\"][number][\"type\"],\n length: number,\n) => {\n switch (type.name) {\n case \"ANY\":\n case \"BINARY\":\n case \"GEO\":\n case \"MAP\":\n case \"MIXED\":\n case \"OTHER\":\n case \"UNION\":\n case \"VARBINARY\":\n return new Array<unknown>(length);\n case \"BOOLEAN\":\n return new Array<boolean>(length);\n case \"DATE\":\n case \"DATETIME\":\n case \"DECIMAL\":\n case \"TEXT\":\n case \"TIME\":\n case \"TIMESTAMP\":\n case \"VARCHAR\":\n return new Array<string>(length);\n case \"BIGINT\":\n return new Array<bigint | null>(length);\n case \"DOUBLE\":\n return new Float64Array(length);\n case \"FLOAT\":\n return new Float32Array(length);\n case \"INTEGER\":\n return new Int32Array(length);\n case \"LIST\":\n return new Array<unknown[]>(length);\n case \"STRUCT\":\n return new Array<Record<string, unknown>>(length);\n default:\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n //@ts-expect-error\n throw new Error(`Unknown field type ${type.name}`);\n }\n};\n"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import type { JobResultsResponse } from "./JobResultsResponse.ts";
|
|
2
|
+
export declare const createColumnRecordFromSchema: <T extends Record<string, unknown>>(schema: JobResultsResponse<T>["schema"], rowCount: number) => Record<Extract<keyof T, string>, unknown[] | Float64Array<ArrayBuffer> | Float32Array<ArrayBuffer> | Int32Array<ArrayBuffer>>;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { createArrayForFieldType } from "./createArrayForFieldType.js";
|
|
17
|
+
export const createColumnRecordFromSchema = (schema, rowCount) => schema.reduce((colMap, field) => {
|
|
18
|
+
colMap[field.name] = createArrayForFieldType(field.type, rowCount);
|
|
19
|
+
return colMap;
|
|
20
|
+
}, {});
|
|
21
|
+
//# sourceMappingURL=createColumnRecordFromSchema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createColumnRecordFromSchema.js","sourceRoot":"","sources":["../../../../src/oss/jobs/utils/createColumnRecordFromSchema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAGvE,MAAM,CAAC,MAAM,4BAA4B,GAAG,CAC1C,MAAuC,EACvC,QAAgB,EAChB,EAAE,CACF,MAAM,CAAC,MAAM,CACX,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE;IAChB,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,uBAAuB,CAAC,KAAK,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;IACnE,OAAO,MAAM,CAAC;AAChB,CAAC,EACD,EAAqF,CACtF,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { createArrayForFieldType } from \"./createArrayForFieldType.ts\";\nimport type { JobResultsResponse } from \"./JobResultsResponse.ts\";\n\nexport const createColumnRecordFromSchema = <T extends Record<string, unknown>>(\n schema: JobResultsResponse<T>[\"schema\"],\n rowCount: number,\n) =>\n schema.reduce(\n (colMap, field) => {\n colMap[field.name] = createArrayForFieldType(field.type, rowCount);\n return colMap;\n },\n {} as Record<Extract<keyof T, string>, ReturnType<typeof createArrayForFieldType<T>>>,\n );\n"]}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { JobResultsResponse } from "./JobResultsResponse.ts";
|
|
2
|
+
export declare const createRowTypeMapper: (schema: JobResultsResponse["schema"]) => (row: Record<string, unknown>) => void;
|
|
3
|
+
export declare const mapRowData: (rows: JobResultsResponse["rows"], schema: JobResultsResponse["schema"]) => void;
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
const mapFieldValue = (fieldType, fieldValue) => {
|
|
17
|
+
if (fieldValue === null) {
|
|
18
|
+
return null;
|
|
19
|
+
}
|
|
20
|
+
switch (fieldType) {
|
|
21
|
+
case "TIMESTAMP":
|
|
22
|
+
return new Date(fieldValue + "Z");
|
|
23
|
+
case "BIGINT":
|
|
24
|
+
return BigInt(fieldValue);
|
|
25
|
+
default:
|
|
26
|
+
return fieldValue;
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export const createRowTypeMapper = (schema) => {
|
|
30
|
+
const fieldTypes = schema.reduce((accum, field) => {
|
|
31
|
+
accum.set(field.name, field.type.name);
|
|
32
|
+
return accum;
|
|
33
|
+
}, new Map());
|
|
34
|
+
return (row) => {
|
|
35
|
+
for (const property in row) {
|
|
36
|
+
row[property] = mapFieldValue(fieldTypes.get(property), row[property]);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
export const mapRowData = (rows, schema) => {
|
|
41
|
+
const rowMapper = createRowTypeMapper(schema);
|
|
42
|
+
for (const row of rows) {
|
|
43
|
+
rowMapper(row);
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
//# sourceMappingURL=mapRowData.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapRowData.js","sourceRoot":"","sources":["../../../../src/oss/jobs/utils/mapRowData.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAIH,MAAM,aAAa,GAAG,CACpB,SAA+D,EAC/D,UAAmB,EACnB,EAAE;IACF,IAAI,UAAU,KAAK,IAAI,EAAE,CAAC;QACxB,OAAO,IAAI,CAAC;IACd,CAAC;IAED,QAAQ,SAAS,EAAE,CAAC;QAClB,KAAK,WAAW;YACd,OAAO,IAAI,IAAI,CAAE,UAAqB,GAAG,GAAG,CAAC,CAAC;QAChD,KAAK,QAAQ;YACX,OAAO,MAAM,CAAC,UAAoB,CAAC,CAAC;QACtC;YACE,OAAO,UAAU,CAAC;IACtB,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,MAAoC,EAAE,EAAE;IAC1E,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE;QAChD,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACvC,OAAO,KAAK,CAAC;IACf,CAAC,EAAE,IAAI,GAAG,EAAgE,CAAC,CAAC;IAE5E,OAAO,CAAC,GAA4B,EAAE,EAAE;QACtC,KAAK,MAAM,QAAQ,IAAI,GAAG,EAAE,CAAC;YAC3B,GAAG,CAAC,QAAQ,CAAC,GAAG,aAAa,CAAC,UAAU,CAAC,GAAG,CAAC,QAAQ,CAAE,EAAE,GAAG,CAAC,QAAQ,CAAC,CAAC,CAAC;QAC1E,CAAC;IACH,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG,CACxB,IAAgC,EAChC,MAAoC,EAC9B,EAAE;IACR,MAAM,SAAS,GAAG,mBAAmB,CAAC,MAAM,CAAC,CAAC;IAE9C,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;QACvB,SAAS,CAAC,GAAG,CAAC,CAAC;IACjB,CAAC;AACH,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { JobResultsResponse } from \"./JobResultsResponse.ts\";\n\nconst mapFieldValue = (\n fieldType: JobResultsResponse[\"schema\"][number][\"type\"][\"name\"],\n fieldValue: unknown,\n) => {\n if (fieldValue === null) {\n return null;\n }\n\n switch (fieldType) {\n case \"TIMESTAMP\":\n return new Date((fieldValue as string) + \"Z\");\n case \"BIGINT\":\n return BigInt(fieldValue as number);\n default:\n return fieldValue;\n }\n};\n\nexport const createRowTypeMapper = (schema: JobResultsResponse[\"schema\"]) => {\n const fieldTypes = schema.reduce((accum, field) => {\n accum.set(field.name, field.type.name);\n return accum;\n }, new Map<string, JobResultsResponse[\"schema\"][number][\"type\"][\"name\"]>());\n\n return (row: Record<string, unknown>) => {\n for (const property in row) {\n row[property] = mapFieldValue(fieldTypes.get(property)!, row[property]);\n }\n };\n};\n\nexport const mapRowData = (\n rows: JobResultsResponse[\"rows\"],\n schema: JobResultsResponse[\"schema\"],\n): void => {\n const rowMapper = createRowTypeMapper(schema);\n\n for (const row of rows) {\n rowMapper(row);\n }\n};\n"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import type { JobResultsResponse } from "./JobResultsResponse.ts";
|
|
2
|
+
export declare const mapRowsToColumns: <T extends Record<string, unknown>>(jobResults: JobResultsResponse<T>) => Record<Extract<keyof T, string>, unknown[] | Float64Array<ArrayBuffer> | Float32Array<ArrayBuffer> | Int32Array<ArrayBuffer>>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { createColumnRecordFromSchema } from "./createColumnRecordFromSchema.js";
|
|
17
|
+
export const mapRowsToColumns = (jobResults) => {
|
|
18
|
+
const columnMap = createColumnRecordFromSchema(jobResults.schema, jobResults.rows.length);
|
|
19
|
+
for (const [index, row] of jobResults.rows.entries()) {
|
|
20
|
+
for (const columnName in row) {
|
|
21
|
+
const col = columnMap[columnName];
|
|
22
|
+
col[index] = row[columnName];
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
return columnMap;
|
|
26
|
+
};
|
|
27
|
+
//# sourceMappingURL=mapRowsToColumns.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapRowsToColumns.js","sourceRoot":"","sources":["../../../../src/oss/jobs/utils/mapRowsToColumns.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,4BAA4B,EAAE,MAAM,mCAAmC,CAAC;AAGjF,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC9B,UAAiC,EACjC,EAAE;IACF,MAAM,SAAS,GAAG,4BAA4B,CAAC,UAAU,CAAC,MAAM,EAAE,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAE1F,KAAK,MAAM,CAAC,KAAK,EAAE,GAAG,CAAC,IAAI,UAAU,CAAC,IAAI,CAAC,OAAO,EAAE,EAAE,CAAC;QACrD,KAAK,MAAM,UAAU,IAAI,GAAG,EAAE,CAAC;YAC7B,MAAM,GAAG,GAAG,SAAS,CAAC,UAAU,CAAC,CAAC;YAClC,GAAG,CAAC,KAAK,CAAC,GAAG,GAAG,CAAC,UAAU,CAAC,CAAC;QAC/B,CAAC;IACH,CAAC;IAED,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { createColumnRecordFromSchema } from \"./createColumnRecordFromSchema.ts\";\nimport type { JobResultsResponse } from \"./JobResultsResponse.ts\";\n\nexport const mapRowsToColumns = <T extends Record<string, unknown>>(\n jobResults: JobResultsResponse<T>,\n) => {\n const columnMap = createColumnRecordFromSchema(jobResults.schema, jobResults.rows.length);\n\n for (const [index, row] of jobResults.rows.entries()) {\n for (const columnName in row) {\n const col = columnMap[columnName];\n col[index] = row[columnName];\n }\n }\n\n return columnMap;\n};\n"]}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
export declare class Reflection {
|
|
2
|
+
#private;
|
|
3
|
+
createdAt: ReflectionProperties["createdAt"];
|
|
4
|
+
id: ReflectionProperties["id"];
|
|
5
|
+
name: ReflectionProperties["name"];
|
|
6
|
+
updatedAt: ReflectionProperties["updatedAt"];
|
|
7
|
+
type: ReflectionProperties["type"];
|
|
8
|
+
constructor(properties: ReflectionProperties);
|
|
9
|
+
}
|
|
10
|
+
export declare const reflectionEntityToProperties: (entity: {
|
|
11
|
+
id: string;
|
|
12
|
+
type: "RAW" | "AGGREGATION";
|
|
13
|
+
name: string;
|
|
14
|
+
tag: string;
|
|
15
|
+
createdAt: string;
|
|
16
|
+
updatedAt: string;
|
|
17
|
+
datasetId: string;
|
|
18
|
+
currentSizeBytes: number;
|
|
19
|
+
totalSizeBytes: number;
|
|
20
|
+
enabled: boolean;
|
|
21
|
+
status: {
|
|
22
|
+
config: "OK" | "INVALID";
|
|
23
|
+
refresh: "GIVEN_UP" | "MANUAL" | "RUNNING" | "SCHEDULED";
|
|
24
|
+
availability: "AVAILABLE" | "EXPIRED" | "INCOMPLETE" | "NONE";
|
|
25
|
+
combinedStatus: "CAN_ACCELERATE" | "CAN_ACCELERATE_WITH_FAILURES" | "CANNOT_ACCELERATE_INITIALIZING" | "CANNOT_ACCELERATE_MANUAL" | "CANNOT_ACCELERATE_SCHEDULED" | "DISABLED" | "EXPIRED" | "FAILED" | "INVALID" | "INCOMPLETE" | "REFRESHING";
|
|
26
|
+
failureCount: number;
|
|
27
|
+
lastDataFetch: string;
|
|
28
|
+
expiresAt: string;
|
|
29
|
+
};
|
|
30
|
+
dimensionFields: {
|
|
31
|
+
name: string;
|
|
32
|
+
granularity?: string;
|
|
33
|
+
}[];
|
|
34
|
+
measureFields: {
|
|
35
|
+
name: string;
|
|
36
|
+
measureTypeList: string[];
|
|
37
|
+
}[];
|
|
38
|
+
distributionFields: {
|
|
39
|
+
name: string;
|
|
40
|
+
}[];
|
|
41
|
+
partitionFields: {
|
|
42
|
+
name: string;
|
|
43
|
+
}[];
|
|
44
|
+
sortFields: {
|
|
45
|
+
name: string;
|
|
46
|
+
}[];
|
|
47
|
+
partitionDistributionStrategy: string;
|
|
48
|
+
canView: boolean;
|
|
49
|
+
canAlter: boolean;
|
|
50
|
+
entityType: "reflection";
|
|
51
|
+
}) => {
|
|
52
|
+
createdAt: Date;
|
|
53
|
+
id: string;
|
|
54
|
+
name: string;
|
|
55
|
+
tag: string;
|
|
56
|
+
type: "RAW" | "AGGREGATION";
|
|
57
|
+
updatedAt: Date;
|
|
58
|
+
};
|
|
59
|
+
type ReflectionProperties = ReturnType<typeof reflectionEntityToProperties>;
|
|
60
|
+
export {};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
export class Reflection {
|
|
17
|
+
createdAt;
|
|
18
|
+
id;
|
|
19
|
+
name;
|
|
20
|
+
updatedAt;
|
|
21
|
+
type;
|
|
22
|
+
// eslint-disable-next-line no-unused-private-class-members
|
|
23
|
+
#tag;
|
|
24
|
+
constructor(properties) {
|
|
25
|
+
this.createdAt = properties.createdAt;
|
|
26
|
+
this.id = properties.id;
|
|
27
|
+
this.name = properties.name;
|
|
28
|
+
this.updatedAt = properties.updatedAt;
|
|
29
|
+
this.type = properties.type;
|
|
30
|
+
this.#tag = properties.tag;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
export const reflectionEntityToProperties = (entity) => ({
|
|
34
|
+
createdAt: new Date(entity.createdAt),
|
|
35
|
+
id: entity.id,
|
|
36
|
+
name: entity.name,
|
|
37
|
+
tag: entity.tag,
|
|
38
|
+
type: entity.type,
|
|
39
|
+
updatedAt: new Date(entity.updatedAt),
|
|
40
|
+
});
|
|
41
|
+
//# sourceMappingURL=Reflection.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Reflection.js","sourceRoot":"","sources":["../../../src/oss/reflections/Reflection.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,MAAM,OAAO,UAAU;IACrB,SAAS,CAAoC;IAC7C,EAAE,CAA6B;IAC/B,IAAI,CAA+B;IACnC,SAAS,CAAoC;IAC7C,IAAI,CAA+B;IACnC,2DAA2D;IAC3D,IAAI,CAA8B;IAElC,YAAY,UAAgC;QAC1C,IAAI,CAAC,SAAS,GAAG,UAAU,CAAC,SAAS,CAAC;QACtC,IAAI,CAAC,EAAE,GAAG,UAAU,CAAC,EAAE,CAAC;QACxB,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,IAAI,CAAC;QAC5B,IAAI,CAAC,SAAS,GAAG,UAAU,CAAC,SAAS,CAAC;QACtC,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,IAAI,CAAC;QAC5B,IAAI,CAAC,IAAI,GAAG,UAAU,CAAC,GAAG,CAAC;IAC7B,CAAC;CACF;AAED,MAAM,CAAC,MAAM,4BAA4B,GAAG,CAAC,MAkD5C,EAAE,EAAE,CAAC,CAAC;IACL,SAAS,EAAE,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC;IACrC,EAAE,EAAE,MAAM,CAAC,EAAE;IACb,IAAI,EAAE,MAAM,CAAC,IAAI;IACjB,GAAG,EAAE,MAAM,CAAC,GAAG;IACf,IAAI,EAAE,MAAM,CAAC,IAAI;IACjB,SAAS,EAAE,IAAI,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC;CACtC,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport class Reflection {\n createdAt: ReflectionProperties[\"createdAt\"];\n id: ReflectionProperties[\"id\"];\n name: ReflectionProperties[\"name\"];\n updatedAt: ReflectionProperties[\"updatedAt\"];\n type: ReflectionProperties[\"type\"];\n // eslint-disable-next-line no-unused-private-class-members\n #tag: ReflectionProperties[\"tag\"];\n\n constructor(properties: ReflectionProperties) {\n this.createdAt = properties.createdAt;\n this.id = properties.id;\n this.name = properties.name;\n this.updatedAt = properties.updatedAt;\n this.type = properties.type;\n this.#tag = properties.tag;\n }\n}\n\nexport const reflectionEntityToProperties = (entity: {\n id: string;\n type: \"RAW\" | \"AGGREGATION\";\n name: string;\n tag: string;\n createdAt: string;\n updatedAt: string;\n datasetId: string;\n currentSizeBytes: number;\n totalSizeBytes: number;\n enabled: boolean;\n status: {\n config: \"OK\" | \"INVALID\";\n refresh: \"GIVEN_UP\" | \"MANUAL\" | \"RUNNING\" | \"SCHEDULED\";\n availability: \"AVAILABLE\" | \"EXPIRED\" | \"INCOMPLETE\" | \"NONE\";\n combinedStatus:\n | \"CAN_ACCELERATE\"\n | \"CAN_ACCELERATE_WITH_FAILURES\"\n | \"CANNOT_ACCELERATE_INITIALIZING\"\n | \"CANNOT_ACCELERATE_MANUAL\"\n | \"CANNOT_ACCELERATE_SCHEDULED\"\n | \"DISABLED\"\n | \"EXPIRED\"\n | \"FAILED\"\n | \"INVALID\"\n | \"INCOMPLETE\"\n | \"REFRESHING\";\n failureCount: number;\n lastDataFetch: string;\n expiresAt: string;\n };\n dimensionFields: {\n name: string;\n granularity?: string;\n }[];\n measureFields: {\n name: string;\n measureTypeList: string[];\n }[];\n distributionFields: {\n name: string;\n }[];\n partitionFields: {\n name: string;\n }[];\n sortFields: { name: string }[];\n partitionDistributionStrategy: string;\n canView: boolean;\n canAlter: boolean;\n entityType: \"reflection\";\n}) => ({\n createdAt: new Date(entity.createdAt),\n id: entity.id,\n name: entity.name,\n tag: entity.tag,\n type: entity.type,\n updatedAt: new Date(entity.updatedAt),\n});\n\ntype ReflectionProperties = ReturnType<typeof reflectionEntityToProperties>;\n"]}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import type { ResourceConfig, SonarV2Config, SonarV3Config } from "../common/Config.ts";
|
|
2
|
+
/**
|
|
3
|
+
* @hidden
|
|
4
|
+
* @internal
|
|
5
|
+
*/
|
|
6
|
+
export declare const Resources: (config: ResourceConfig & SonarV2Config & SonarV3Config) => {
|
|
7
|
+
catalog: {
|
|
8
|
+
_catalogReferenceFromEntity: (entity: unknown) => import("./interfaces.ts").CatalogReference;
|
|
9
|
+
list: () => {
|
|
10
|
+
data(): AsyncGenerator<import("./interfaces.ts").FunctionCatalogReference | import("./interfaces.ts").HomeCatalogReference | import("./interfaces.ts").SourceCatalogReference | import("./interfaces.ts").SpaceCatalogReference, void, unknown>;
|
|
11
|
+
};
|
|
12
|
+
retrieve: (key: string) => Promise<import("ts-results-es").Result<import("./interfaces.ts").CatalogObject, import("./index.ts").Problem>>;
|
|
13
|
+
retrieveByPath: (key: string[]) => Promise<import("ts-results-es").Result<import("./interfaces.ts").CatalogObject, import("./index.ts").Problem>>;
|
|
14
|
+
};
|
|
15
|
+
jobs: {
|
|
16
|
+
create: (query: import("./index.ts").Query) => Promise<import("ts-results-es").Err<unknown> | import("ts-results-es").Ok<string>>;
|
|
17
|
+
observe: (id: string) => import("rxjs").Observable<import("./jobs/Job.ts").JobResult>;
|
|
18
|
+
retrieve: (id: string, { signal }?: import("../common/Params.ts").SignalParam) => Promise<import("./jobs/Job.ts").JobResult>;
|
|
19
|
+
};
|
|
20
|
+
scripts: {
|
|
21
|
+
list(): {
|
|
22
|
+
data({ signal }?: import("../common/Params.ts").SignalParam): AsyncGenerator<import("./interfaces.ts").Script, void, unknown>;
|
|
23
|
+
};
|
|
24
|
+
retrieve: (id: string, { signal }?: import("../common/Params.ts").SignalParam) => Promise<import("ts-results-es").Err<unknown> | import("ts-results-es").Ok<import("./interfaces.ts").Script>>;
|
|
25
|
+
store: (properties: {
|
|
26
|
+
name: string;
|
|
27
|
+
query: import("./index.ts").Query;
|
|
28
|
+
}) => Promise<import("ts-results-es").Err<unknown> | import("ts-results-es").Ok<import("./interfaces.ts").Script>>;
|
|
29
|
+
};
|
|
30
|
+
users: {
|
|
31
|
+
retrieveById: (id: string, { signal }?: {
|
|
32
|
+
signal?: AbortSignal;
|
|
33
|
+
}) => Promise<import("ts-results-es").Err<unknown> | import("ts-results-es").Ok<import("./interfaces.ts").User>>;
|
|
34
|
+
retrieveByName: (name: string, { signal }?: {
|
|
35
|
+
signal?: AbortSignal;
|
|
36
|
+
}) => Promise<import("ts-results-es").Err<unknown> | import("ts-results-es").Ok<import("./interfaces.ts").User>>;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (C) 2024-2025 Dremio Corporation
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
import { CatalogResource } from "./catalog/CatalogResource.js";
|
|
17
|
+
import { JobsResource } from "./jobs/JobsResource.js";
|
|
18
|
+
import { ScriptsResource } from "./scripts/ScriptsResource.js";
|
|
19
|
+
import { UsersResource } from "./users/UsersResource.js";
|
|
20
|
+
/**
|
|
21
|
+
* @hidden
|
|
22
|
+
* @internal
|
|
23
|
+
*/
|
|
24
|
+
export const Resources = (config) => ({
|
|
25
|
+
catalog: CatalogResource(config),
|
|
26
|
+
jobs: JobsResource(config),
|
|
27
|
+
scripts: ScriptsResource(config),
|
|
28
|
+
users: UsersResource(config),
|
|
29
|
+
});
|
|
30
|
+
//# sourceMappingURL=resources.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resources.js","sourceRoot":"","sources":["../../src/oss/resources.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAGH,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAEzD;;;GAGG;AACH,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,MAAsD,EAAE,EAAE,CAAC,CAAC;IACpF,OAAO,EAAE,eAAe,CAAC,MAAM,CAAC;IAChC,IAAI,EAAE,YAAY,CAAC,MAAM,CAAC;IAC1B,OAAO,EAAE,eAAe,CAAC,MAAM,CAAC;IAChC,KAAK,EAAE,aAAa,CAAC,MAAM,CAAC;CAC7B,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { ResourceConfig, SonarV2Config, SonarV3Config } from \"../common/Config.ts\";\nimport { CatalogResource } from \"./catalog/CatalogResource.ts\";\nimport { JobsResource } from \"./jobs/JobsResource.ts\";\nimport { ScriptsResource } from \"./scripts/ScriptsResource.ts\";\nimport { UsersResource } from \"./users/UsersResource.ts\";\n\n/**\n * @hidden\n * @internal\n */\nexport const Resources = (config: ResourceConfig & SonarV2Config & SonarV3Config) => ({\n catalog: CatalogResource(config),\n jobs: JobsResource(config),\n scripts: ScriptsResource(config),\n users: UsersResource(config),\n});\n"]}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { Err, Ok } from "ts-results-es";
|
|
2
|
+
import { Query } from "../../common/Query.ts";
|
|
3
|
+
import type { SonarV3Config } from "../../common/Config.ts";
|
|
4
|
+
export declare class Script {
|
|
5
|
+
#private;
|
|
6
|
+
readonly createdAt: ScriptProperties["createdAt"];
|
|
7
|
+
readonly createdBy: ScriptProperties["createdBy"];
|
|
8
|
+
readonly id: ScriptProperties["id"];
|
|
9
|
+
readonly modifiedAt: ScriptProperties["modifiedAt"];
|
|
10
|
+
readonly modifiedBy: ScriptProperties["modifiedBy"];
|
|
11
|
+
readonly name: ScriptProperties["name"];
|
|
12
|
+
readonly query: ScriptProperties["query"];
|
|
13
|
+
constructor(properties: ScriptProperties, config: SonarV3Config);
|
|
14
|
+
delete(): Promise<Err<unknown> | Ok<undefined>>;
|
|
15
|
+
save(properties: ScriptPatchableProperties): Promise<Err<{
|
|
16
|
+
readonly errors: [{
|
|
17
|
+
readonly detail: "A script with this name already exists";
|
|
18
|
+
readonly pointer: "#/name";
|
|
19
|
+
readonly type: "https://api.dremio.dev/problems/validation/field-conflict";
|
|
20
|
+
readonly value: string;
|
|
21
|
+
}];
|
|
22
|
+
readonly title: "There was a problem validating the content of the request";
|
|
23
|
+
readonly type: "https://api.dremio.dev/problems/validation-problem";
|
|
24
|
+
}> | Err<import("../index.ts").Problem> | Ok<Script>>;
|
|
25
|
+
}
|
|
26
|
+
export declare const scriptEntityToProperties: (entity: ScriptEntity) => {
|
|
27
|
+
createdAt: Temporal.Instant;
|
|
28
|
+
createdBy: string;
|
|
29
|
+
id: string;
|
|
30
|
+
modifiedAt: Temporal.Instant;
|
|
31
|
+
modifiedBy: string;
|
|
32
|
+
name: string;
|
|
33
|
+
query: Query;
|
|
34
|
+
};
|
|
35
|
+
export type ScriptEntity = {
|
|
36
|
+
content: string;
|
|
37
|
+
context: string[];
|
|
38
|
+
createdAt: string;
|
|
39
|
+
createdBy: string;
|
|
40
|
+
id: string;
|
|
41
|
+
modifiedAt: string;
|
|
42
|
+
modifiedBy: string;
|
|
43
|
+
name: string;
|
|
44
|
+
};
|
|
45
|
+
export type ScriptPatchableProperties = {
|
|
46
|
+
name?: ScriptProperties["name"];
|
|
47
|
+
query?: ScriptProperties["query"];
|
|
48
|
+
};
|
|
49
|
+
export type ScriptProperties = ReturnType<typeof scriptEntityToProperties>;
|
|
50
|
+
export declare const createScriptPatchedFields: (properties: ScriptPatchableProperties) => {
|
|
51
|
+
name?: string;
|
|
52
|
+
content?: string;
|
|
53
|
+
context?: string[];
|
|
54
|
+
};
|
|
55
|
+
export declare const saveScript: (id: string, config: SonarV3Config) => (body: Record<string, any>) => Promise<Ok<ScriptEntity> | Err<{
|
|
56
|
+
readonly errors: [{
|
|
57
|
+
readonly detail: "A script with this name already exists";
|
|
58
|
+
readonly pointer: "#/name";
|
|
59
|
+
readonly type: "https://api.dremio.dev/problems/validation/field-conflict";
|
|
60
|
+
readonly value: string;
|
|
61
|
+
}];
|
|
62
|
+
readonly title: "There was a problem validating the content of the request";
|
|
63
|
+
readonly type: "https://api.dremio.dev/problems/validation-problem";
|
|
64
|
+
}> | Err<import("../index.ts").Problem>>;
|