Open MKRazz opened 2 years ago
I'm no TS expert, but looking at the code it appears to create a child key every time the child DB is accessed. I think a better approach would be to use scoped keys. Fauna schema migrate already needs access to an admin key for the parent database in order to create child ones, so it shouldn't need to create a new key.
If you run a command while using a child database, it will create a new key and leave it there, so you eventually end up with tons of keys on the parent database. Could these keys be deleted after the command is done running?