autobee 2.0.0-rc.19 → 2.0.0-rc.20

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.
Files changed (3) hide show
  1. package/index.js +7 -0
  2. package/lib/boot.js +2 -0
  3. package/package.json +1 -1
package/index.js CHANGED
@@ -865,9 +865,16 @@ module.exports = class Autobee extends ReadyResource {
865
865
  }
866
866
 
867
867
  async _bumpMigratedWriters() {
868
+ const opened = new Set()
869
+
868
870
  for (const batch of this._catchupMigratedNodes) {
869
871
  await this._processBatch(batch)
872
+ for (const node of batch) {
873
+ if (node.from) opened.add(node.from)
874
+ }
870
875
  }
876
+
877
+ for (const core of opened) await core.close()
871
878
  }
872
879
 
873
880
  // append a null value node to ack writer
package/lib/boot.js CHANGED
@@ -201,6 +201,8 @@ async function checkAutobaseMigration(store, local, bootstrap, legacyViews) {
201
201
  mappedViews.set(name, v)
202
202
  }
203
203
 
204
+ await core.close()
205
+
204
206
  return {
205
207
  encryptionKey,
206
208
  system,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "autobee",
3
- "version": "2.0.0-rc.19",
3
+ "version": "2.0.0-rc.20",
4
4
  "description": "Bee based autobase",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Holepunch Inc.",