Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-7556

Enable to upgrade proxy generation independently of beam for java support

Details

    • Task
    • Status: Triage Needed
    • P2
    • Resolution: Duplicate
    • 2.13.0
    • Not applicable
    • sdk-java-core

    Description

      Beam is now using a custom shaded version of bytebudy which makes impossible - until you reshade - to upgrade bytebuddy without requiring a new beam release.

      However with the fast release rate of the JVM it is important to be able to upgrade bytebuddy - at least while beam is using it which is technically not a strong requirement - to enable to run on the new JVM.

      For example, last beam release does not support recent java:

      Caused by: java.lang.UnsupportedOperationException: Cannot define class using reflection: Cannot define nest member class java.lang.reflect.AccessibleObject$Cache + within different package then class org.apache.beam.repackaged.beam_sdks_java_core.net.bytebuddy.mirror.AccessibleObject
      

      My preference to fix this issue would be to relax the proxying definition to just use a "proxy classloader" where the proxy would be defined but it requires to be able to attach it to an execution - where beam is not yet super clean.
      Alternative is to have a SPI for the asm usage and enable to user to replace the bytebuddy impl with either a not shaded version or even a pure asm one to let him control the dependencies.

      Romain

      Attachments

        1. error.txt
          4 kB
          Silvan Hollenstein

        Activity

          People

            Unassigned Unassigned
            romain.manni-bucau Romain Manni-Bucau
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: