Hi Steinar, actually the Pax-Web iTests can be used as blueprint. When digging for certain Bugs I debug Pax-Web with those iTests. For example take the jetty ones:
https://github.com/ops4j/org.ops4j.pax.web/blob/master/pax-web-itest/pax-web-itest-container/pax-web-itest-container-jetty/src/test/java/org/ops4j/pax/web/itest/jetty/HttpServiceIntegrationTest.java#L132 Just place a breakpoint there and you're able to debug a) the Test, and b) the underlying Pax-Web Server parts. Debugging Pax-Web Karaf combination is a bit more trickier. Cause Pax-Exam actually spawns a new process for Karaf. If you want to debug those, there is a special trick, enable the runEmbedded flag. https://github.com/ops4j/org.ops4j.pax.web/blob/master/pax-web-itest/pax-web-itest-karaf/src/test/java/org/ops4j/pax/web/itest/karaf/KarafBaseTest.java#L85 But beware when using this flag only one test at a time can be executed. regards, Achim 2016-09-27 20:59 GMT+02:00 Steinar Bang <[email protected]>: > >>>>> Benson Margulies <[email protected]>: > > > Surely you want something that also works in your commands-line/CI > > system, not just eclipse? > > I plan to use karaf to actually run the webapp. > > But for now, I run the bundle(s) in two places; > 1. In a PaxExam JUnit test > https://github.com/steinarb/ukelonn/tree/master/ukelonn.tests > 2. In a felix instance launched by the maven-pax-plugin (kind of > abandoned but still works) > https://github.com/steinarb/ukelonn/tree/master/ukelonn.gogoshell > (launched by "mvn pax:provision" in that directory) > > But right now I have no way of debugging the actual running webapp. > > I can debug the PaxExam tests, but not the actual webapp. > > The PaxExam tests are trivial right now, they are mostly just proving > that the bundles start and find all the required OSGi services. > > I tried creating a test that actually used the web app, patterned on the > tests in PaxExam, using pax-web-itest, but I wasn't able to get it > working so I've @Ignored it (this test is on a currently unpushed > branch). > > -- > -- > ------------------ > OPS4J - http://www.ops4j.org - [email protected] > > --- > You received this message because you are subscribed to the Google Groups > "OPS4J" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- Apache Member Apache Karaf <http://karaf.apache.org/> Committer & PMC OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer & Project Lead blog <http://notizblog.nierbeck.de/> Co-Author of Apache Karaf Cookbook <http://bit.ly/1ps9rkS> Software Architect / Project Manager / Scrum Master -- -- ------------------ OPS4J - http://www.ops4j.org - [email protected] --- You received this message because you are subscribed to the Google Groups "OPS4J" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
