-
Notifications
You must be signed in to change notification settings - Fork 9
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
Completions caching #6
Comments
Thanks for raising this. A completion cache would be a useful addition for your environment and I'm definitely open to reviewing a PR for it.
This sounds sensible to me, here are a few thoughts:
Happy to discuss further, otherwise look forward to a PR! |
Caching per |
Good idea, it should also include the user since they may have different read permissions - so something like hash(user || tnsname). |
Sounds good, I'll start working on this ASAP. |
@mriehl will do tomorrow, thanks. |
Today is 2021, has it come true? |
The oracle databases I currently work with unfortunately have a ton of namespaces and tables.
This results in "Refreshing completions" for around a minute every time I start
okcli
.I've talked a bit with @icepuma about this issue and we had the idea to add optional completion caching to okcli.
It could work like this:
--enable-completions-cache
or similar)The cache would be per-connection, for example after hashing the connection string.
I don't have any particular preference regarding cache invalidation, maybe simply removing the file manually would be good enough for a first start, or a
--force-invalidate-cache
option (slightly better especially if the file name is a hash).A slightly easier variation to avoid dealing with XDG would be to simply support
--completion-cache <path>
so the user can decide if and when to delete the file. But it also introduces the potential mistake of using a completion cache for a different connection which would be confusing.What are your thoughts on this and would you accept a pull request implementing this?
The text was updated successfully, but these errors were encountered: