Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Standardised API Access To Database #196

Open
adrian-goe opened this issue Nov 29, 2022 · 2 comments
Open

Standardised API Access To Database #196

adrian-goe opened this issue Nov 29, 2022 · 2 comments

Comments

@adrian-goe
Copy link

Is your feature request related to a problem? Please describe.
Having Stored twice is redundant and results effort to synchronising

Describe the solution you'd like
An standardised API to write Database Adapters as a source to search. Then all Databases could have a custom fitting Adapter.
This would enable searching on top of a database of any type. This could be Postgres, MongoDB or even indexDB in the browser.

I'm aware that this would make search slower, but would be optional and this tradeoff may be worth for some projects.

@micheleriva
Copy link
Member

Hi @adrian-goe ,
that's actually a good proposal, thanks! Do you have any reference we can follow to understand your desired API?

@adrian-goe
Copy link
Author

I'm not so firm in creating/designing an plugin system like this. Also not, how Lyra works internally.
But I would assume something like nelify-cms do with their backends? see every netlify-cms-backend-... package -> https://github.com/netlify/netlify-cms/tree/master/packages

Its not documented at this moment, but basically, the provide an Interface and this needs to be implemented. The implemented class is the registered and used.

I guess, this adapter would be implemented per structure?

The more I think about this, the more complicated it gets 🙈
Like, dose lyra need to store metadata -> maybe the database has to provide a table for this? what about updates in the data, dose lyra needed to be informed about this?

I am willing to help and think about this, but I guess, i need to know lyras internals in the first place

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants