Hi. Thanks Patrik.

I am using shutdown() and then awaitTermination(). Both don't block and
return immediately. My previous test start two nodes and the the
awaitTermination()
blocks as expected and everything works fine. The only test which fails is
the one which works in single-node mode.

I've tried the TestKit and the behavior is exactly the same.

In other words, if I start a new node in the same test the function blocks
as expected.

Thanks again.


On Fri, Mar 11, 2016 at 1:33 PM, Patrik Nordwall <[email protected]>
wrote:

> You must use shutdown followed by awaitTermination.
> (note that awaitTermination is replaced by something else in 2.4.x, see
> deprecation)
>
> In TestKit there is a helper method to shutdown the actor system, await
> and verify.
>
> On Fri, Mar 11, 2016 at 1:22 PM, Eduardo Fernandes <[email protected]>
> wrote:
>
>> Hi.
>>
>> Hum... I think that is not the case. In fact the methods shutdown() and 
>> awaitTermination()
>> simply don't block at all and the next test says that the port 12551 is
>> already bound. If my previous test starts two nodes everything works find
>> and the awaitTermination() method waits for the node shutdown.
>>
>> The problem only appears when my test is single node.
>>
>> Thanks for your time.
>>
>> On Fri, Mar 11, 2016 at 1:14 PM, Akka Team <[email protected]>
>> wrote:
>>
>>> Hi Eduardo,
>>>
>>> If you have an actor that is blocking indefinitely, the actor system
>>> termination will never complete, could this be the case? If it is you
>>> should be able to see that by getting a thread dump from the JVM and see
>>> one of your actor blocking one of the dispatcher threads.
>>>
>>> --
>>> Johan Andrén
>>> Akka Team, Lightbend Inc.
>>>
>>> --
>>> >>>>>>>>>> Read the docs: http://akka.io/docs/
>>> >>>>>>>>>> Check the FAQ:
>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>> >>>>>>>>>> Search the archives:
>>> https://groups.google.com/group/akka-user
>>> ---
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "Akka User List" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/akka-user/tkCnKcjj1tI/unsubscribe.
>>> To unsubscribe from this group and all its topics, send an email to
>>> [email protected].
>>> To post to this group, send email to [email protected].
>>> Visit this group at https://groups.google.com/group/akka-user.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
>> >>>>>>>>>> Read the docs: http://akka.io/docs/
>> >>>>>>>>>> Check the FAQ:
>> http://doc.akka.io/docs/akka/current/additional/faq.html
>> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "Akka User List" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> To post to this group, send email to [email protected].
>> Visit this group at https://groups.google.com/group/akka-user.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
>
> Patrik Nordwall
> Akka Tech Lead
> Lightbend <http://www.lightbend.com/> -  Reactive apps on the JVM
> Twitter: @patriknw
>
> [image: Lightbend] <http://www.lightbend.com/>
>
> --
> >>>>>>>>>> Read the docs: http://akka.io/docs/
> >>>>>>>>>> Check the FAQ:
> http://doc.akka.io/docs/akka/current/additional/faq.html
> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "Akka User List" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/akka-user/tkCnKcjj1tI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to