Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-8009

CXF should not use ClassUtils for cglib checks

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.7.18, 3.2.8, 3.3.1
    • 3.2.9, 3.3.2
    • JAX-RS
    • None
    • Unknown

    Description

      When using lambda to implement a jax-rs StreamingOutput we get a no message body writer found error.

      However if we use an anonymous class instead of the lambda then it works.

      This happens because CXF uses the spring method ClassUtils.isCglibProxyClass() for detecting cglib classes. However that method is not strict enough and incorrectly marks every lambda class as cglib as well. This causes CXF to get the superclass which will always be Object.class for which there is no message body writer.

      According to the feedback received on the spring project instead of ClassUtils.isCglibProxyClass() (which got deprecated) people should use other methods, for example AopUtils.isCglibProxy() which is more strict.

      Attachments

        Issue Links

          Activity

            People

              reta Andriy Redko
              akiraly Attila Király
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m