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

Lazy Indexing #60

Open
pbogut opened this issue Sep 8, 2016 · 1 comment
Open

Lazy Indexing #60

pbogut opened this issue Sep 8, 2016 · 1 comment

Comments

@pbogut
Copy link
Member

pbogut commented Sep 8, 2016

Here's the idea. Instead of doing mass reindex in project root there could be something like a lazy index. On the first completion, we could collect files and classes only (which should be much faster than a full index), and then when doing completion inside the file index missing related files. So if class A uses object of class B then index class B etc. Hopefully, it's clear what the idea is.

With that feature, we could have full completion in any project without needs for full reindex.

Just to give you some figures, reindex in one of my projects:

$ \time -f %es padawan generate
...
74.82s

In the same project:

$ \time -f %es ag --php '^class.*$'
...
0.98s

It would be probably slower in pure PHP, but still should be faster than full reindex.

How feasible you think it is?

@mkusher
Copy link
Member

mkusher commented Sep 9, 2016

@pbogut there is a new feature in padawan "Index update", it will update index only for changed files. For now it's only available via http interface
Here is an example

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants