@xata.io/client 0.27.0 → 0.28.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.
@@ -1,4 +1,4 @@
1
1
 
2
- > @xata.io/client@0.27.0 add-version /home/runner/work/client-ts/client-ts/packages/client
2
+ > @xata.io/client@0.28.0 add-version /home/runner/work/client-ts/client-ts/packages/client
3
3
  > node ../../scripts/add-version-file.mjs
4
4
 
@@ -1,13 +1,13 @@
1
1
 
2
- > @xata.io/client@0.27.0 build /home/runner/work/client-ts/client-ts/packages/client
2
+ > @xata.io/client@0.28.0 build /home/runner/work/client-ts/client-ts/packages/client
3
3
  > rimraf dist && rollup -c
4
4
 
5
5
  
6
6
  src/index.ts → dist/index.cjs...
7
- created dist/index.cjs in 1.1s
7
+ created dist/index.cjs in 734ms
8
8
  
9
9
  src/index.ts → dist/index.mjs...
10
- created dist/index.mjs in 743ms
10
+ created dist/index.mjs in 465ms
11
11
  
12
12
  src/index.ts → dist/index.d.ts...
13
- created dist/index.d.ts in 7.1s
13
+ created dist/index.d.ts in 5s
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @xata.io/client
2
2
 
3
+ ## 0.28.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#1251](https://github.com/xataio/client-ts/pull/1251) [`e97d1999`](https://github.com/xataio/client-ts/commit/e97d1999f3c25f149213ceca81958e1674624e05) Thanks [@SferaDev](https://github.com/SferaDev)! - Remove Xata Workers support
8
+
3
9
  ## 0.27.0
4
10
 
5
11
  ### Minor Changes
package/dist/index.cjs CHANGED
@@ -528,7 +528,7 @@ function defaultOnOpen(response) {
528
528
  }
529
529
  }
530
530
 
531
- const VERSION = "0.27.0";
531
+ const VERSION = "0.28.0";
532
532
 
533
533
  class ErrorWithCause extends Error {
534
534
  constructor(message, options) {
@@ -768,6 +768,13 @@ function parseUrl(url) {
768
768
 
769
769
  const dataPlaneFetch = async (options) => fetch$1({ ...options, endpoint: "dataPlane" });
770
770
 
771
+ const applyMigration = (variables, signal) => dataPlaneFetch({ url: "/db/{dbBranchName}/pgroll/apply", method: "post", ...variables, signal });
772
+ const pgRollStatus = (variables, signal) => dataPlaneFetch({
773
+ url: "/db/{dbBranchName}/pgroll/status",
774
+ method: "get",
775
+ ...variables,
776
+ signal
777
+ });
771
778
  const getBranchList = (variables, signal) => dataPlaneFetch({
772
779
  url: "/dbs/{dbName}",
773
780
  method: "get",
@@ -982,6 +989,8 @@ const sqlQuery = (variables, signal) => dataPlaneFetch({
982
989
  });
983
990
  const operationsByTag$2 = {
984
991
  branch: {
992
+ applyMigration,
993
+ pgRollStatus,
985
994
  getBranchList,
986
995
  getBranchDetails,
987
996
  createBranch,
@@ -4755,21 +4764,6 @@ const deserialize = (json) => {
4755
4764
  return defaultSerializer.fromJSON(json);
4756
4765
  };
4757
4766
 
4758
- function buildWorkerRunner(config) {
4759
- return function xataWorker(name, worker) {
4760
- return async (...args) => {
4761
- const url = process.env.NODE_ENV === "development" ? `http://localhost:64749/${name}` : `https://dispatcher.xata.workers.dev/${config.workspace}/${config.worker}/${name}`;
4762
- const result = await fetch(url, {
4763
- method: "POST",
4764
- headers: { "Content-Type": "application/json" },
4765
- body: serialize({ args })
4766
- });
4767
- const text = await result.text();
4768
- return deserialize(text);
4769
- };
4770
- };
4771
- }
4772
-
4773
4767
  class XataError extends Error {
4774
4768
  constructor(message, status) {
4775
4769
  super(message);
@@ -4807,13 +4801,13 @@ exports.addGitBranchesEntry = addGitBranchesEntry;
4807
4801
  exports.addTableColumn = addTableColumn;
4808
4802
  exports.aggregateTable = aggregateTable;
4809
4803
  exports.applyBranchSchemaEdit = applyBranchSchemaEdit;
4804
+ exports.applyMigration = applyMigration;
4810
4805
  exports.askTable = askTable;
4811
4806
  exports.askTableSession = askTableSession;
4812
4807
  exports.branchTransaction = branchTransaction;
4813
4808
  exports.buildClient = buildClient;
4814
4809
  exports.buildPreviewBranchName = buildPreviewBranchName;
4815
4810
  exports.buildProviderString = buildProviderString;
4816
- exports.buildWorkerRunner = buildWorkerRunner;
4817
4811
  exports.bulkInsertTableRecords = bulkInsertTableRecords;
4818
4812
  exports.cancelWorkspaceMemberInvite = cancelWorkspaceMemberInvite;
4819
4813
  exports.compareBranchSchemas = compareBranchSchemas;
@@ -4921,6 +4915,7 @@ exports.operationsByTag = operationsByTag;
4921
4915
  exports.parseProviderString = parseProviderString;
4922
4916
  exports.parseWorkspacesUrlParts = parseWorkspacesUrlParts;
4923
4917
  exports.pattern = pattern;
4918
+ exports.pgRollStatus = pgRollStatus;
4924
4919
  exports.previewBranchSchemaEdit = previewBranchSchemaEdit;
4925
4920
  exports.pushBranchMigrations = pushBranchMigrations;
4926
4921
  exports.putFile = putFile;