--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/ab4e80bc-1c1e-4189-87dc-640d2ce5858a%40googlegroups.com.
Hi Yevgeny,it is possible to talk to the agent through its runtime API: https://www.jacoco.org/jacoco/trunk/doc/api/org/jacoco/agent/rt/package-summary.htmlRegards,-marc
On 4. Nov 2019, at 21:22, Yevgeny P <yev...@gmail.com> wrote:
Hey Team,Let's say I've started a Java program with Jacoco agent. Is it possible to retrieve the coverage from within the Java program itself via somekind of API or it should be an external program?I only saw an example doing something similar for a single class without Jacoco agent.Thanks,Yevgeny--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jac...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/290d2d71-da0c-4085-ad5d-81842f2d33fe%40googlegroups.com.
Interesting. Can you please provide the full stack trace?
On 5. Nov 2019, at 11:41, Yevgeny P <yev...@gmail.com> wrote:
I think I got it, this goal is running before the test goal so it's changes the JVM command-line. I have different problem now - I'm running with MVN_OPTS="-javaagent:<path>" this indeed generates the exec coverage file when the program exits but it I'm not able to use the API as I get:Caused by: java.lang.IllegalStateException: JaCoCo agent not started. even though it is started as I get the coverage after the program exits.
On Tuesday, November 5, 2019 at 8:37:07 AM UTC+2, yev...@fuzzit.dev wrote:Thanks! I'll try that out. Also Im trying to start the coverage in a maven plugin, kind like you did here: https://github.com/jacoco/jacoco/blob/master/jacoco-maven-plugin/src/org/jacoco/maven/AbstractAgentMojo.java .But this doesn't work for also I don't understand how it works in jacoco as the JVM is already started or does it spawn another JVM per test and then it's start the agent like specified in the properties.
On Tuesday, November 5, 2019 at 12:54:45 AM UTC+2, Marc R. Hoffmann wrote:Hi Yevgeny,it is possible to talk to the agent through its runtime API: https://www.jacoco.org/jacoco/trunk/doc/api/org/jacoco/agent/rt/package-summary.htmlRegards,-marcOn 4. Nov 2019, at 21:22, Yevgeny P <yev...@gmail.com> wrote:Hey Team,Let's say I've started a Java program with Jacoco agent. Is it possible to retrieve the coverage from within the Java program itself via somekind of API or it should be an external program?I only saw an example doing something similar for a single class without Jacoco agent.Thanks,Yevgeny--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jac...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/ab4e80bc-1c1e-4189-87dc-640d2ce5858a%40googlegroups.com.--
You received this message because you are subscribed to the Google Groups "JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jac...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/290d2d71-da0c-4085-ad5d-81842f2d33fe%40googlegroups.com.
Hey Marc, Attached is a github repo with complete reproduction steps in the README https://github.com/yevgenypats/jacoco-test
the call to getExecutionData(0.5s)
and parsing the data(0.5s).
But the performance is pretty slow
Is there anything to do with that or I would need to reimplement the instrumentation myself if I would like this to be faster?
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/517ba116-ce05-4b3e-8a73-6d683d1b7be5%40googlegroups.com.
Hi Yevgeny,
that sounds like an interesting project! If you publish it let us know, we can add your project to our integration matrix.I added an experimental API for you that just counts the number of hits (no overhead for serializing the data):Can you please tell us, whether this improves your performance?Cheers,-marc
To unsubscribe from this group and stop receiving emails from it, send an email to jac...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/517ba116-ce05-4b3e-8a73-6d683d1b7be5%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to jacoco+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/e23e17aa-fdd2-4446-b2b2-3e05f76c0313%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jacoco/D799CE74-8BCD-43D7-B5AC-D18BC1D10803%40mountainminds.com.