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

Support databases as storage #26

Open
kebugcheckex opened this issue Sep 18, 2022 · 3 comments
Open

Support databases as storage #26

kebugcheckex opened this issue Sep 18, 2022 · 3 comments

Comments

@kebugcheckex
Copy link

This is a feature request. I will probably work on it later.

Current storage uses file system to store keys and certificates. This will not scale well when the number of certificates grows to a magnitude of 10^4 or larger. I'm considering create a storage adapter that can support databases, both relational databases (e.g. MySQL) and key-value storage (e.g. Redis), while retaining the ability to use file system as the storage.

I don't have a detailed design yet. On the high level, we can abstract the load/save operations and have different implementations behind the scene. I will add more details soon.

@wixregiga
Copy link

Hey, did you make any progress on this or would you like some assistance? @kebugcheckex

@kebugcheckex
Copy link
Author

Sorry. I haven't got a chance to start working on this yet. This will require a bit design work. Here are some thoughts in my mind.

  1. What kind of database do we want to support? We can support one specific kind of database (e.g. MySQL) or a variety of them. Given that the existing code has a storage adapter, I guess we should create an abstraction based on that and support different databases through adapters.
  2. How to design the table schema? For example, shall we store certificates/keys as Base64 encoded string or just binary blobs?
  3. In the long term (obviously not any time soon) we may need to support distributed databases, how to shard, etc.

@BirknerAlex
Copy link

A interface which everyone can implement would be awesome, so everybody can decide which storage method to use. One interface implemenation would be the file system as we already have.

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

No branches or pull requests

3 participants