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

UIForm: Performance Improvement #5097

Closed
melloware opened this issue May 21, 2022 · 1 comment
Closed

UIForm: Performance Improvement #5097

melloware opened this issue May 21, 2022 · 1 comment

Comments

@melloware
Copy link
Contributor

Based on MyFaces fix: https://issues.apache.org/jira/browse/MYFACES-4283

In case when invokeOnComponent is used and the form has prependId=true, we can early skip the whole component tree if the baseClientId != form clientId.

I discovered this while working on this PFE issue: primefaces-extensions/primefaces-extensions#799

    @Override
    public boolean invokeOnComponent(FacesContext context, String clientId, ContextCallback callback) throws FacesException {
        if (isPrependId()) {
            String baseClientId = getClientId(context);

            // skip if the component is not a child of the UIForm
            if (!clientId.startsWith(baseClientId)) {
                return false;
            }
        }

        return super.invokeOnComponent(context, clientId, callback);
    }
melloware added a commit to melloware/mojarra that referenced this issue May 21, 2022
Signed-off-by: melloware <mellowaredev@gmail.com>
melloware added a commit to melloware/mojarra that referenced this issue May 21, 2022
Signed-off-by: melloware <mellowaredev@gmail.com>
melloware added a commit to melloware/mojarra that referenced this issue May 21, 2022
Signed-off-by: melloware <mellowaredev@gmail.com>
melloware added a commit to melloware/mojarra that referenced this issue May 21, 2022
Signed-off-by: melloware <mellowaredev@gmail.com>
melloware added a commit to melloware/mojarra that referenced this issue May 21, 2022
Signed-off-by: melloware <mellowaredev@gmail.com>
BalusC added a commit that referenced this issue May 22, 2022
Fix #5097: UIForm performance improvement 2.3
BalusC added a commit that referenced this issue May 22, 2022
Fix #5097: UIForm performance improvement 3.0
@BalusC BalusC closed this as completed in e6a5118 May 22, 2022
BalusC added a commit that referenced this issue May 22, 2022
Fix #5097: UIForm performance improvement 4.0
@BalusC
Copy link
Contributor

BalusC commented May 22, 2022

FYI: all 2.3 tests passed.

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

No branches or pull requests

2 participants