Uploaded image for project: 'Maven Surefire'
  1. Maven Surefire
  2. SUREFIRE-2078

systemPropertyVariables not working

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 3.0.0-M6
    • None
    • Maven Surefire Plugin
    • None

    Description

      Hi. Im trying to use the opentelemetry java agent, but either surefire is not passing through the parameters, or the agent is not picking them up.

      It works if I pass via the argLine, but not via systemPropertyVariables or systemProperties.

      https://maven.apache.org/surefire/maven-surefire-plugin/examples/system-properties.html

      https://opentelemetry.io/docs/instrumentation/java/automatic/agent-config/

      Here is my up-to-date reproducer

      https://github.com/delanym/java-maven-junit-helloworld/tree/opentelemetry

      Run `mvn test` and you should get a line on the console like

      [otel.javaagent 2022-04-26 10:33:44:015 +0200] [main] INFO io.opentelemetry.exporter.logging.LoggingSpanExporter - 'HelloTest.testSayHelloAFewTimes' : be46c05e6d80182590d5289426358fb7 e4c666619bfc7c2d INTERNAL [tracer: io.opentelemetry.opentelemetry-anno
      tations-1.0:1.13.0-alpha] AttributesMap{data={thread.id=1, thread.name=main}, capacity=128, totalAddedValues=2}

      Try to use the systemPropertyVariables instead and it will not show.

      Attachments

        Activity

          People

            Unassigned Unassigned
            delany Delany
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: