Skip to content

[Ldap] Unused 'sizeLimit' option #58514

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

Closed
rela589n opened this issue Oct 9, 2024 · 0 comments · Fixed by #58558
Closed

[Ldap] Unused 'sizeLimit' option #58514

rela589n opened this issue Oct 9, 2024 · 0 comments · Fixed by #58558

Comments

@rela589n
Copy link
Contributor

rela589n commented Oct 9, 2024

Symfony version(s) affected

7.1.x

Description

Looking at the AbstractQuery option 'sizeLimit', it seems that this option is never used.

        $resolver->setDefaults([
            'filter' => '*',
            'maxItems' => 0,
            'sizeLimit' => 0,
            'timeout' => 0,
            'deref' => static::DEREF_NEVER,
            'attrsOnly' => 0,
            'scope' => static::SCOPE_SUB,
            'pageSize' => 0,
        ]);

This is the only place where 'sizeLimit' is referenced in the whole ldap component

How to reproduce

☝️

Possible Solution

Remove unused option not to confuse the folks

Additional Context

image

@rela589n rela589n added the Bug label Oct 9, 2024
@fabpot fabpot closed this as completed Oct 18, 2024
fabpot added a commit that referenced this issue Oct 18, 2024
…-daubois)

This PR was merged into the 7.2 branch.

Discussion
----------

[Ldap] Deprecate the `sizeLimit` query option

| Q             | A
| ------------- | ---
| Branch?       | 7.2
| Bug fix?      | no
| New feature?  | no
| Deprecations? | yes
| Issues        | Fix #58514
| License       | MIT

The `sizeLimit` option is never used, it is actually calculated with the `maxItems` option in `Query`. I propose to deprecate the option that is currently no-op anyway.

Commits
-------

ce66e4e [Ldap] Deprecate the `sizeLimit` query option
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants