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

Spring CGLIB proxies not handled as intended #674

Closed
zolyfarkas opened this issue Jan 9, 2015 · 1 comment
Closed

Spring CGLIB proxies not handled as intended #674

zolyfarkas opened this issue Jan 9, 2015 · 1 comment
Milestone

Comments

@zolyfarkas
Copy link

in BeanUtil.isCglibGetCallbacks

the callbacks is not detected because spring repackages cglib: org.springframework.cglib....

changing:

        if (pname.startsWith("net.sf.cglib")
            // also, as per [JACKSON-177]
            || pname.startsWith("org.hibernate.repackage.cglib")) {
            return true;
        }

to:

        if (pname.contains("cglib") // also, as per [JACKSON-177]
                ) {
            return true;
        }

would work, with the disadvantage or other cglib name usages....

@cowtowncoder
Copy link
Member

I think I'd rather be strict here, so adding another variant is fine.
However, what'd really be neat would be to have a unit test to verify these cases.
Also perhaps Spring module would be good, if there are other commonly encountered other issues.

But for now, I think I'll just add one more case. This is deep enough in code that removing a check that shouldn't be applied is difficult, so cost of false positive is non-trivial.

@cowtowncoder cowtowncoder added this to the 2.5.1 milestone Jan 11, 2015
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