Uploaded image for project: 'Byteman'
  1. Byteman
  2. BYTEMAN-381

BMUnit fails silently when BYTEMAN_HOME setting points at incompatible jar


    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 3.0.14, 4.0.6
    • Fix Version/s: 3.0.15, 4.0.7
    • Component/s: Contrib
    • Labels:


      If environment var BYTEMAN_HOME or system property org.jboss.byteman.home is set t a non-empty string BMUnit treats it as naming a directory and try to load the agent jar from that directory. If the env var is set by accident in the maven execution environment then this can cause a mismatch in the release versions of the bmunit jar and the byteman agent jar. In some cases this causes silent failure of rule injection.

      One solution is to make the agent and BMUnit code be aware of their release versions and have BMUnit verify a match after agent loading, throwing an exception if the match fails. If a release version string is injected into each jar then the agent code can publish it via a system property and the BMUnit code can test the property has the expected value after agent load. This will detect mismatches of new BMUnit releases with new agent releases. It will also detect mismatches of new BMUnit releases with old agent releases (since the property will be absent).

        Gliffy Diagrams




              • Assignee:
                adinn Andrew Dinn
                adinn Andrew Dinn
              • Votes:
                0 Vote for this issue
                1 Start watching this issue


                • Created: