How do I debug this maven JAXB compiler?

Answered

So we have our own plugin and it overrides a lot of JAXB stuff. I have someone else's project which employs our compiler and it generates with no errors but there is a problem with some of the behavior. It's not generating quite right. The context is sufficiently complex, however, that it's best if I do the debugging on their build rather than ours.

How do I debug a maven plugin such that I can trace into it when the library doesn't show up in "External Libraries" ? I already know I can right-click and run the maven project as debug but how do I set breakpoints if I can't get at the library?

0
2 comments

You can run Maven build outside of IntelliJ IDEA and use Remote Debug configuration to debug it. You need to have your plug-in sources and classes in the module dependencies so that you can place breakpoints and debug it.

0

Actually, all we had to do was add the jars to the maven dependency list and change the plugin entry to run the code directly. We were able to trace after that. Have to target the generate-sources phase tho.

0

Please sign in to leave a comment.