do I reduce the noise in the BioUno log? Both real errors and those
about missing property exceptions seems to be at the same log level.
pinpoint one specific case, it is hard to confirm we are currently
logging detailed enough information. But if you are able to specify a
use case, the current behaviour, and how we could change it to make it
easier to debug issues; then it must be easier to assess whether that is
doable or not, and how complex it would be.
>How do I write debug messages to the BioUno log? (can I use a logger somehow)
Hummmm. Very interesting. I never thought about that, but you should be able to do that in your scripts.
// not tested, but along these lines...
import java.util.logging.Level; import java.util.logging.Logger;
def LOGGER = Logger.getLogger("org.biouno.myscript");
LOGGER.log(Level.INFO, "Hello", exception);
>Other suggestions from people's experience in debugging while on the build form?
me the best way to debug problems with plug-ins is still importing the
source code into Eclipse, attaching the debugger and step through a few
parts of the code. It doesn't involve so much Java. Mainly knowing how
to use Maven, an IDE, how and where to put breakpoints, and some of the
Jenkins internal API (which you should be fine as you have been writing
Groovy in Jenkins for a while).
Hope that helps
From: Ioannis Moutsatsos <imout...@gmail.com
To: BioUno Developers <biouno-d...@googlegroups.com
Sent: Sunday, 2 April 2017 12:30 AM
Subject: [QUESTION]Best practices for debugging Active-Choices scripts?
Recently, I have been dealing with some AC groovy scripts that have proven tough to debug.
The BioUno log (even with v1.5.3) is littered with messages that this or the other AC parameter is missing. Real errors appear as well, embedded in there but in general are hard to find and hard to know exactly what script they originate in (all of them seem to reference Script1)
I'm not sure if I'm doing these things in a very efficient manner. I would like to ask the following questions:
1. How do I reduce the noise in the BioUno log? Both real errors and those about missing property exceptions seems to be at the same log level.
2. How do I write debug messages to the BioUno log? (can I use a logger somehow)
3. Other suggestions from people's experience in debugging while on the build form?
Good suggestions and ideas should go into the Active Choices wiki troubleshooting page.
Thanks and best regards
You received this message because you are subscribed to the Google Groups "BioUno Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to biouno-develop...@googlegroups.com
For more options, visit https://groups.google.com/d/optout