incubator-teaclave
incubator-teaclave copied to clipboard
Support persistent data storage
Hi, I'm seeking for a way to persist data after relaunching teaclave services. I read your roadmap, and I found you guys have done a persistent database implementation work. Can I use this database to save like register information and data owner meta info? If not, do you have a other way that you guys maybe discussed before? Really need a way out.
Thanks for asking.
We have two places for data storage in services:
Authentication service: https://github.com/apache/incubator-teaclave/blob/master/services/authentication/enclave/src/user_db.rs#L96 Storage service: https://github.com/apache/incubator-teaclave/blob/master/services/storage/enclave/src/lib.rs#L80
Current implementations only open DB in memory.
To persist DB into disk, you can use these APIs to encrypt DB into disk:
https://github.com/apache/incubator-teaclave/blob/master/tests/integration/enclave/src/rusty_leveldb_sgx.rs#L103
However, we haven't implemented and provided interfaces to support this in our services right now.
@mssun what extra interfaces should I look forward to? I mean if I replace memory DBs in both authentication service and storage service with level-db, like what is happening in rusty_leveldb_sgx test, is it not enough?
I think we have already supported persistent data storage through rusty-leveldb-sgx. It can be enabled in storage service. Do I miss anything? @mssun @m4sterchain
Yes. This issue can be closed.