Well ... you're doing something different there ... you're using it as
Server.
please don't nail me on it, but I've seen a similar problem arise in former
times with any kind of container started by a maven test. Sometimes those
maven teardowns aren't good on timing and especially waiting for a
container to finish on it.

regards, Achim


2016-10-25 20:12 GMT+02:00 Benson Margulies <[email protected]>:

>
>
> On Tue, Oct 25, 2016 at 1:58 PM, 'Achim Nierbeck' via OPS4J <
> [email protected]> wrote:
>
>> Hi,
>>
>> I haven't seen stuck Karafs now for a long time. So usually it's a hint
>> of a malfunctional test.
>>
>
> Nope. It gets stuck after the last test case has run, somewhere in the
> tear-down process. And it fails when the tests all _succeed_.
>
> I posted the thread dumps.
>
> It only fails sporadically. And it happens, now, to both David and me.
>
>
>
>
>> Especially if the test fails hard in a way that the tear down of the
>> karaf can't be run anymore.
>> Therefore first make sure your tests are "safe" enough to not block a
>> tear down, or release ports which are allocated with your applications.
>> Btw. Karaf itself and also the Pax-Web tests do successfully use the
>> Pax-Exam with Karaf, therefore maybe taking a look
>> at both projects might help to find some pointers :-)
>>
>> regards, Achim
>>
>>
>> 2016-10-25 19:13 GMT+02:00 Benson Margulies <[email protected]>:
>>
>>> The alternative you have is to use the exam-maven-plugin if you don't
>>> need to inject test cases into the container. However, I've also seen that
>>> get stuck on shutdown.
>>>
>>>
>>> On Tue, Oct 25, 2016 at 1:12 PM, David Karr <[email protected]>
>>> wrote:
>>>
>>>> Ah.  Now I see that it doesn't even matter, as PerSuite is not
>>>> supported for OSGi or Karaf modes.
>>>>
>>>> On Tuesday, October 25, 2016 at 9:36:14 AM UTC-7, David Karr wrote:
>>>>>
>>>>> I'm working in a largish project, with multiple subprojects, each of
>>>>> which have PaxExam-based integration tests.
>>>>>
>>>>> Presently, all of the tests are using the PerClass reactor strategy.
>>>>>
>>>>> When I run the "integration-test" goal from the top-level, it runs all
>>>>> of the integration tests in the entire project.  This is something that I
>>>>> eventually want to run from CI, but only if it can be done reliably.
>>>>>
>>>>> Presently, we're seeing issues where the Karaf container fails to shut
>>>>> down properly, resulting in the next test failing with "address in use"
>>>>> errors.  I'm considering all possible mitigation strategies for this
>>>>> problem.
>>>>>
>>>>> I noticed that another reactor strategy is "PerSuite".  This is a very
>>>>> long shot, but is there any chance the impact of using this is that all of
>>>>> the integration tests in the entire project would use the same container?
>>>>> I think this is unlikely, but I figured I might as well ask.  I understand
>>>>> that even if this works, there are potential tradeoffs from lack of
>>>>> isolation of tests, but a test that fails because it can't start up Karaf
>>>>> is worse than that.
>>>>>
>>>> --
>>>> --
>>>> ------------------
>>>> 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.
>>>>
>>>
>>> --
>>> --
>>> ------------------
>>> 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.
>>
>
> --
> --
> ------------------
> 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.

Reply via email to