question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Feature request: .flush()

See original GitHub issue

It would be great if it were possible to .flush() (remove all records) a levelUP. Flushing is a fairly common operation for those of us who develop with levelup regularly

You can “flush” with the current (1.3.2) API by getting all the keys in the db, and then deleting them one by one. However depending on the *-down it is generally a lot faster to delete the store and then reinitialise a fresh store. Therefore it makes sense to extract out .flush() into its own API call.

Or does it…?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:11 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
fergiemcdowallcommented, Jul 26, 2017

“V2!, V2!” * stands outside building waving placard *

@juliangruber @ralphtheninja

1reaction
dominictarrcommented, Jul 6, 2017

@fergiemcdowall since destroy is a static method, if you are doing it this way, you’d need to pass the constructor + options instead of the initialized database.

Read more comments on GitHub >

github_iconTop Results From Across the Web

TestRequest.flush() throwing Unsupported responseType: text ...
Attempting to mock a GET endpoint returning a CSV using HttpTestController.expectOne() and TestRequest.flush() to mock/resolve request/response.
Read more >
TestRequest - Angular
flush() link · mode_edit code. Resolve the request by returning a body plus additional HTTP information (such as response headers) if provided.
Read more >
Single flush for single frame buffer - LVGL Forum
Single flush for single frame buffer · Feature request ... data between the two frame buffers in _lv_disp_refr_task() , so the true double ......
Read more >
[Feature Request]Add msg.flush to trigger as per delay node
The msg.flush has proved very useful for the delay node and it would be handy to have it in the trigger node as...
Read more >
Flush API | Elasticsearch Guide [8.5] | Elastic
If the Elasticsearch security features are enabled, you must have the maintenance ... If false , Elasticsearch returns an error if you request...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found