Skip to content

Expose DbCache (for plugins, etc.) + useful Neo.IO.Helper methods#613

Merged
jsolman merged 2 commits intomasterfrom
ExposeDbCache
Feb 27, 2019
Merged

Expose DbCache (for plugins, etc.) + useful Neo.IO.Helper methods#613
jsolman merged 2 commits intomasterfrom
ExposeDbCache

Conversation

@jsolman
Copy link
Copy Markdown
Contributor

@jsolman jsolman commented Feb 27, 2019

Plugins that persist to a separate LevelDB store may want to use the DbCache in order to cache data they will be writing to disk and exposing through RPC. One example is moving #569 to a plugin, and there are other plugins I am working on that will need it.

@jsolman jsolman requested a review from erikzhang February 27, 2019 00:50
@jsolman jsolman changed the title Expose DbCache (for plugins, etc.) Expose DbCache (for plugins, etc.) + useful Neo.IO.Helper methods Feb 27, 2019
{
public static class Helper
{
public const int GroupingSizeInBytes = 16;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

private?

Copy link
Copy Markdown
Contributor Author

@jsolman jsolman Feb 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This also can be needed in code that uses Find from a plugin. I have code that needs it, because to search for a prefix one needs to add a 0 byte after every 16 characters to search for a prefix longer than this length.

Copy link
Copy Markdown
Contributor Author

@jsolman jsolman Feb 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the Find method inserted the 0 bytes after every 16 characters it wouldn’t be needed. If we change that in a subsequent PR we could change this to be internal perhaps, but for now, we need it public.

@jsolman jsolman merged commit e86a8b6 into master Feb 27, 2019
@shargon shargon deleted the ExposeDbCache branch February 27, 2019 17:26
Thacryba pushed a commit to simplitech/neo that referenced this pull request Feb 17, 2020
* 2.9.0

* updates for 2.9.0

* Update v2.9.0.md (neo-project#610)

Adjustment for instruction of getting nep-5 applicationlog.

* Update invokescript.md (neo-project#613)

Add tx

* Update invokefunction.md (neo-project#612)

Add tx for response.

* Create getwalletheight (neo-project#611)

Add getwalletheight api.

* updates for 2.9.0

* minor updates

* Update setup.md (neo-project#617)

Add introduction of Plugins.

* Update v2.9.0.md (neo-project#615)

Add introduction for setting config.json

* final updates

* Update v2.9.0.md (neo-project#618)

Add notes for install plugins.

* plugin related
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants