datafolder 1.0.47 → 1.0.48

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/src/simulate2.js CHANGED
@@ -64,7 +64,7 @@ async function y(t, e) {
64
64
  }
65
65
  }
66
66
 
67
- function b(t) {
67
+ function D(t) {
68
68
  var e = t;
69
69
  console.time("insertAirports");
70
70
  var o, s = e.batch;
@@ -100,13 +100,12 @@ function b(t) {
100
100
  process.argv[5] && (f.level = process.argv[5]), console.time("loadData"), [ d, h ] = await Promise.all([ u("airports.json"), u("flights.json") ]),
101
101
  await !console.timeEnd("loadData"), console.log(`airports:${d.length}, flights:` + h.length);
102
102
  var s = new n(p, {
103
- fileLogLevel: "basic",
104
103
  maxInMemSnapshotCount: 3
105
- }), r = (t && (await s.start(), b(s), await s.stop()), await s.start(), g(s),
104
+ }), r = (t && (await s.start(), D(s), await s.stop()), await s.start(), g(s),
106
105
  `simulate ${e} ` + o), i = (console.time(r), console.time("simulateStop"), []);
107
106
  for (let t = 0; t < e; ++t) i.push(y(s, o));
108
107
  await Promise.all(i), console.timeEnd(r), f.log(`Simulate ${e} for ${o} ended.`),
109
- console.time("del%"), s.delDir("%"), console.timeEnd("del%"), b(s), await s.stop(),
108
+ console.time("del%"), s.delDir("%"), console.timeEnd("del%"), D(s), await s.stop(),
110
109
  console.timeEnd("simulateStop"), console.time("start"), await s.start(), console.timeEnd("start"),
111
110
  g(s), await s.stop(), console.timeEnd("total"), global.gc && global.gc();
112
111
  })();