Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

stof
Copy link
Member

@stof stof commented Sep 15, 2015

Q A
Bug fix? yes (perf)
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets n/a
License MIT
Doc PR n/a

Sorting can be slow, so it is best to applied it after all filtering rules are applied instead of using a bigger list and filtering again after that.

This impacts only people using both the sorting and the name filtering (with ->names() or notNames())

Sorting can be slow, so it is best to applied it after all filtering
rules are applied instead of using a bigger list and filtering again
after that.
@nicolas-grekas
Copy link
Member

👍

@fabpot
Copy link
Member

fabpot commented Sep 15, 2015

Thank you @stof.

@fabpot fabpot merged commit e5bf0ab into symfony:2.3 Sep 15, 2015
fabpot added a commit that referenced this pull request Sep 15, 2015
…orting (stof)

This PR was merged into the 2.3 branch.

Discussion
----------

[Finder] Exclude files based on path before applying the sorting

| Q             | A
| ------------- | ---
| Bug fix?      | yes (perf)
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Sorting can be slow, so it is best to applied it after all filtering rules are applied instead of using a bigger list and filtering again after that.

This impacts only people using both the sorting and the name filtering (with ``->names()`` or ``notNames()``)

Commits
-------

e5bf0ab Exclude files based on path before applying the sorting
@stof stof deleted the exclude_before_sorting branch September 15, 2015 09:54
@stof
Copy link
Member Author

stof commented Sep 15, 2015

We may even need to think about the order of the different filtering to put the faster filters first (so that slower filters only run for files not excluded already by faster filters). the current order of filters is quite random AFAICT (it depends mostly of when it was implemented)

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

Successfully merging this pull request may close these issues.

4 participants