neo-project / neo-modules

MIT License
60 stars 100 forks source link

Plugin Storage Manager #819

Closed cschuchardt88 closed 11 months ago

cschuchardt88 commented 1 year ago

Summary or problem description One problem is accessing other plugins storage IStore. Yes these are mostly public classes that get created. But having to import all plugins to just read some data with unexposed API at a high level is a pain. We can do better than that.

Storage manager would be like the name suggests. It would manage storage of the plugins, to ensure data that is saved is not duplicated in anyway. This would allow other plugins to access and get the store's associated with other plugins. Each plugin can still have their own store/storage like it does, but opens an API.

Do you have any solution you want to propose? Storage manager would be in its simplest form; just storage the IStore interfaces for each plugin. Then each plugin would "Add Reference" to this plugins' project. The storage manager can have high level APIs for example like my #807 does. Allowing all of us to access an plugins storage at an time and to ensure no duplicate data being saved.

Where in the software does this update applies to?

cschuchardt88 commented 12 months ago

I think if we add a common method on the Plugin class, like for example GetStore method. That can help us get the store information. After thinking about it, we don't need a storage manager.