Uploaded image for project: 'Quarkus'
  1. Quarkus
  2. QUARKUS-6852

ArC: fix construction of interception proxies

XMLWordPrintable

      During execution of the constructor of an intercepted non-contextual instance (which is a superclass of an interception proxy, *_InterceptionSubclass), virtual method calls were supposed to be forwarded to the delegate. This isn't correct, because the delegate is only set at after the superclass constructor finishes; therefore, all such attempts used to fail with NullPointerException.
      This commit fixes that by adopting the same strategy we use for client proxies and classic interception subclasses (for contextual instances): virtual calls in the constructor are invoked on this (or, in fact, on super) and forwarding is not attempted. Note that this has to be checked both for intercepted and non-intercepted methods.
      Follows up on #49853

              jmartisk@redhat.com Jan Martiska
              msochure@redhat.com Miroslav Sochurek
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: