Closed rmtuckerphx closed 1 year ago
@jankoenig @aswetlow How do we solve this build error?
/node_modules/@redis/client/dist/lib/client/socket.d.ts(39,5): error TS18028: Private identifiers are only available when targeting ECMAScript 2015 and higher.
Will removing tsconfig.build.esm5.json
from db-redis
solve this?
What is the impact?
Could you add "skipLibCheck": true
to tsconfig.build.esm5.json
? This should solve this issue.
What is the latency for connect()
and disconnect()
?
@aswetlow
Here are some timings for Redis connect
and disconnect
:
getDbItem - Redis connect: 247.458ms getDbItem - Redis disconnect: 5.134ms saveData - Redis connect: 160.305ms saveData - Redis disconnect: 1.051ms
getDbItem - Redis connect: 238.067ms getDbItem - Redis disconnect: 0.911ms saveData - Redis connect: 143.946ms saveData - Redis disconnect: 0.931ms
Would it make sense to keep the connection alive after getDbItem and reuse it in saveData? At least for the time of the request. You could store the client
in jovo
. This would save ~150ms in latency.
We could improve it, even more, by using connection pools. This is something that could be done in the future.
@aswetlow I vote to optimize in the future. This is something that I need immediately.
Thank you @rmtuckerphx 🎉
Proposed Changes
Add Database integration for Redis including entry splitting and TTL. Users of the plugin have the ability to encrypt Redis values without that code being part of the plugin.
Types of Changes
Checklist