Move dlayer All symbol

feature/node-rewrite
Sven Slootweg 1 year ago
parent 146f94bf65
commit 20997c0543

1
.gitignore vendored

@ -6,3 +6,4 @@ yarn-error.log
junk
virtual-disks/vdisk1
virtual-disks/vdisk2
roadmap.txt

@ -0,0 +1,3 @@
"use strict";
module.exports = Symbol("All");

@ -4,7 +4,7 @@ const Promise = require("bluebird");
const memoizee = require("memoizee");
// FIXME: Figure out a reasonable way to make this symbol its own (conflict-free) package, given that it'll be used all across both sysquery and CVM
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
// This generates a (memoized) source function for commands that always produce an entire list, that needs to be filtered for the desired item(s)
module.exports = function evaluateAndPick({ command, selectResult, selectID, many }) {

@ -1,7 +1,7 @@
"use strict";
const mapAsync = require("../map-async");
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
module.exports = function evaluateSingle({ command, selectResult }) {
return function (ids) {

@ -1,3 +0,0 @@
"use strict";
module.exports = Symbol("All");

@ -1,7 +1,7 @@
"use strict";
const Promise = require("bluebird");
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
module.exports = async function mapFromSource(source, ids, mapper) {
let results = (ids === All || ids == null)

@ -8,7 +8,7 @@ const { InvalidObject } = require("dlayer");
const unreachable = require("@joepie91/unreachable")("@sysquery/block-devices");
const dlayerSource = require("../dlayer-source");
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
const lsblk = require("../exec-lsblk");
const mapFromSource = require("../map-from-source");
const treeMapAsync = require("../tree-map-async");

@ -6,7 +6,7 @@ const dlayerSource = require("../dlayer-source");
const evaluateAndPick = require("../evaluate-and-pick");
const mapFromSource = require("../map-from-source");
const lvm = require("../exec-lvm");
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
module.exports = {
name: "sysquery.lvm",

@ -9,7 +9,7 @@ const dlayerSource = require("../dlayer-source");
const treeFilterFlatAsync = require("../tree-filter-flat-async");
const treeMapAsync = require("../tree-map-async");
const treeFind = require("../tree-find");
const All = require("../graphql-interface/symbols/all");
const All = require("../dlayer-symbol-all");
const mapAsync = require("../map-async");
module.exports = {

@ -3,7 +3,7 @@
require("@babel/register");
const Promise = require("bluebird");
const createLoaders = require("../src/api/loaders");
const All = require("../src/packages/graphql-interface/symbols/all");
const All = require("../src/packages/dlayer-symbol-all");
let loaders = createLoaders();

Loading…
Cancel
Save