@dremio/js-sdk 0.50.0 → 0.51.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.
@@ -16,6 +16,7 @@
16
16
  const prodLikePattern = /^([^.]+)(\.(?:(?:eu\.)?dremio\.cloud|[^.]+\.dremio\.site))$/;
17
17
  const privateLinkPattern = /^([^.]+\.)([^.]+)((\.privatelink\.dremio\.cloud)|(\.privatelink\.([^.]+)\.dremio\.site))$/;
18
18
  const daasEnginePattern = /^(dcs-(?:aws|cloud)-\d+-ns\.)([^.]+)(\.drem\.io)$/;
19
+ const daasAzurePattern = /^([^.]+)(\.daas-azure\.drem\.io)$/;
19
20
  const awsInternalPattern = /^([^.]+)(\.([^.]+\.aws\.dremio\.site))$/;
20
21
  /**
21
22
  * @hidden
@@ -31,6 +32,10 @@ export function _replaceOriginResource(origin, resource) {
31
32
  url.hostname = hostname.replace(privateLinkPattern, `$1${resource}$3`);
32
33
  return url.origin;
33
34
  }
35
+ if (daasAzurePattern.test(hostname)) {
36
+ url.hostname = hostname.replace(daasAzurePattern, `${resource}$2`);
37
+ return url.origin;
38
+ }
34
39
  if (daasEnginePattern.test(hostname)) {
35
40
  url.hostname = hostname.replace(daasEnginePattern, `$1${resource}$3`);
36
41
  return url.origin;
@@ -1 +1 @@
1
- {"version":3,"file":"replaceOriginResource.js","sourceRoot":"","sources":["../../src/cloud/replaceOriginResource.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAIH,MAAM,eAAe,GAAG,6DAA6D,CAAC;AACtF,MAAM,kBAAkB,GACtB,2FAA2F,CAAC;AAC9F,MAAM,iBAAiB,GAAG,mDAAmD,CAAC;AAC9E,MAAM,kBAAkB,GAAG,yCAAyC,CAAC;AAErE;;;GAGG;AACH,MAAM,UAAU,sBAAsB,CAAC,MAAwB,EAAE,QAAgB;IAC/E,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC;IAC5B,MAAM,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;IAE9B,IAAI,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACtC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,GAAG,QAAQ,IAAI,CAAC,CAAC;IACvE,CAAC;IAED,IAAI,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACtC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,KAAK,QAAQ,IAAI,CAAC,CAAC;QACvE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,IAAI,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACrC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,iBAAiB,EAAE,KAAK,QAAQ,IAAI,CAAC,CAAC;QACtE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,IAAI,eAAe,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACnC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,eAAe,EAAE,GAAG,QAAQ,IAAI,CAAC,CAAC;QAClE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,OAAO,GAAG,CAAC,MAAM,CAAC;AACpB,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 { Config } from \"../common/Config.ts\";\n\nconst prodLikePattern = /^([^.]+)(\\.(?:(?:eu\\.)?dremio\\.cloud|[^.]+\\.dremio\\.site))$/;\nconst privateLinkPattern =\n /^([^.]+\\.)([^.]+)((\\.privatelink\\.dremio\\.cloud)|(\\.privatelink\\.([^.]+)\\.dremio\\.site))$/;\nconst daasEnginePattern = /^(dcs-(?:aws|cloud)-\\d+-ns\\.)([^.]+)(\\.drem\\.io)$/;\nconst awsInternalPattern = /^([^.]+)(\\.([^.]+\\.aws\\.dremio\\.site))$/;\n\n/**\n * @hidden\n * @internal\n */\nexport function _replaceOriginResource(origin: Config[\"origin\"], resource: string): string {\n const url = new URL(origin);\n const hostname = url.hostname;\n\n if (awsInternalPattern.test(hostname)) {\n url.hostname = hostname.replace(awsInternalPattern, `${resource}$2`);\n }\n\n if (privateLinkPattern.test(hostname)) {\n url.hostname = hostname.replace(privateLinkPattern, `$1${resource}$3`);\n return url.origin;\n }\n\n if (daasEnginePattern.test(hostname)) {\n url.hostname = hostname.replace(daasEnginePattern, `$1${resource}$3`);\n return url.origin;\n }\n\n if (prodLikePattern.test(hostname)) {\n url.hostname = hostname.replace(prodLikePattern, `${resource}$2`);\n return url.origin;\n }\n\n return url.origin;\n}\n"]}
1
+ {"version":3,"file":"replaceOriginResource.js","sourceRoot":"","sources":["../../src/cloud/replaceOriginResource.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAIH,MAAM,eAAe,GAAG,6DAA6D,CAAC;AACtF,MAAM,kBAAkB,GACtB,2FAA2F,CAAC;AAC9F,MAAM,iBAAiB,GAAG,mDAAmD,CAAC;AAC9E,MAAM,gBAAgB,GAAG,mCAAmC,CAAC;AAC7D,MAAM,kBAAkB,GAAG,yCAAyC,CAAC;AAErE;;;GAGG;AACH,MAAM,UAAU,sBAAsB,CAAC,MAAwB,EAAE,QAAgB;IAC/E,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC;IAC5B,MAAM,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;IAE9B,IAAI,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACtC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,GAAG,QAAQ,IAAI,CAAC,CAAC;IACvE,CAAC;IAED,IAAI,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACtC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,KAAK,QAAQ,IAAI,CAAC,CAAC;QACvE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,IAAI,gBAAgB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACpC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,gBAAgB,EAAE,GAAG,QAAQ,IAAI,CAAC,CAAC;QACnE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,IAAI,iBAAiB,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACrC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,iBAAiB,EAAE,KAAK,QAAQ,IAAI,CAAC,CAAC;QACtE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,IAAI,eAAe,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC;QACnC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,eAAe,EAAE,GAAG,QAAQ,IAAI,CAAC,CAAC;QAClE,OAAO,GAAG,CAAC,MAAM,CAAC;IACpB,CAAC;IAED,OAAO,GAAG,CAAC,MAAM,CAAC;AACpB,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 { Config } from \"../common/Config.ts\";\n\nconst prodLikePattern = /^([^.]+)(\\.(?:(?:eu\\.)?dremio\\.cloud|[^.]+\\.dremio\\.site))$/;\nconst privateLinkPattern =\n /^([^.]+\\.)([^.]+)((\\.privatelink\\.dremio\\.cloud)|(\\.privatelink\\.([^.]+)\\.dremio\\.site))$/;\nconst daasEnginePattern = /^(dcs-(?:aws|cloud)-\\d+-ns\\.)([^.]+)(\\.drem\\.io)$/;\nconst daasAzurePattern = /^([^.]+)(\\.daas-azure\\.drem\\.io)$/;\nconst awsInternalPattern = /^([^.]+)(\\.([^.]+\\.aws\\.dremio\\.site))$/;\n\n/**\n * @hidden\n * @internal\n */\nexport function _replaceOriginResource(origin: Config[\"origin\"], resource: string): string {\n const url = new URL(origin);\n const hostname = url.hostname;\n\n if (awsInternalPattern.test(hostname)) {\n url.hostname = hostname.replace(awsInternalPattern, `${resource}$2`);\n }\n\n if (privateLinkPattern.test(hostname)) {\n url.hostname = hostname.replace(privateLinkPattern, `$1${resource}$3`);\n return url.origin;\n }\n\n if (daasAzurePattern.test(hostname)) {\n url.hostname = hostname.replace(daasAzurePattern, `${resource}$2`);\n return url.origin;\n }\n\n if (daasEnginePattern.test(hostname)) {\n url.hostname = hostname.replace(daasEnginePattern, `$1${resource}$3`);\n return url.origin;\n }\n\n if (prodLikePattern.test(hostname)) {\n url.hostname = hostname.replace(prodLikePattern, `${resource}$2`);\n return url.origin;\n }\n\n return url.origin;\n}\n"]}
@@ -12648,6 +12648,7 @@ var DremioCloud = (() => {
12648
12648
  var prodLikePattern = /^([^.]+)(\.(?:(?:eu\.)?dremio\.cloud|[^.]+\.dremio\.site))$/;
12649
12649
  var privateLinkPattern = /^([^.]+\.)([^.]+)((\.privatelink\.dremio\.cloud)|(\.privatelink\.([^.]+)\.dremio\.site))$/;
12650
12650
  var daasEnginePattern = /^(dcs-(?:aws|cloud)-\d+-ns\.)([^.]+)(\.drem\.io)$/;
12651
+ var daasAzurePattern = /^([^.]+)(\.daas-azure\.drem\.io)$/;
12651
12652
  var awsInternalPattern = /^([^.]+)(\.([^.]+\.aws\.dremio\.site))$/;
12652
12653
  function _replaceOriginResource(origin, resource) {
12653
12654
  const url = new URL(origin);
@@ -12659,6 +12660,10 @@ var DremioCloud = (() => {
12659
12660
  url.hostname = hostname2.replace(privateLinkPattern, `$1${resource}$3`);
12660
12661
  return url.origin;
12661
12662
  }
12663
+ if (daasAzurePattern.test(hostname2)) {
12664
+ url.hostname = hostname2.replace(daasAzurePattern, `${resource}$2`);
12665
+ return url.origin;
12666
+ }
12662
12667
  if (daasEnginePattern.test(hostname2)) {
12663
12668
  url.hostname = hostname2.replace(daasEnginePattern, `$1${resource}$3`);
12664
12669
  return url.origin;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dremio/js-sdk",
3
- "version": "0.50.0",
3
+ "version": "0.51.0",
4
4
  "description": "JavaScript library for the Dremio API",
5
5
  "keywords": [
6
6
  "dremio",