Skip to content

Conversation

misaya98
Copy link
Contributor

@misaya98 misaya98 commented Oct 31, 2024

compatible command like : java -jar -XX:MaxRAM=128m app.jar
The JAR file name does not always come immediately after the -jar command; there may be other JVM parameters in between the two.

by now, if we use the java -jar -XX:MaxRAM=128m app.jar command to start the applicaion. we can not get the real jar name.
we will get the warn log like below:
otel.javaagent 2024-10-29 09:24:19:600 +0000] [main] WARN io.opentelemetry.instrumentation.resources.ManifestResourceProvider - Error reading manifest java.nio.file.NoSuchFileException: -XX:MaxRAM=128m

Resolves #12545

compatible command like : java -jar -XX:MaxRAM=128m app.jar
…-style

compatible different command line style for find jar path
@misaya98 misaya98 requested a review from a team as a code owner October 31, 2024 05:00
Copy link

linux-foundation-easycla bot commented Oct 31, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

Copy link
Member

@trask trask left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you add a test for this to JarServiceNameDetectorTest?

@misaya98
Copy link
Contributor Author

misaya98 commented Nov 5, 2024

can you add a test for this to JarServiceNameDetectorTest?

yes.

Co-authored-by: Trask Stalnaker <[email protected]>
@trask trask merged commit 3ad4269 into open-telemetry:main Nov 6, 2024
56 checks passed
akats7 pushed a commit to akats7/opentelemetry-java-instrumentation that referenced this pull request Nov 21, 2024
akats7 pushed a commit to akats7/opentelemetry-java-instrumentation that referenced this pull request Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

compatible different command line style for find jar path

3 participants