ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Actionlib notifications not received

asked 2011-07-24 23:04:30 -0500

joan gravatar image

updated 2014-01-28 17:10:06 -0500

ngrennan gravatar image


I have been trying to notify to both action server and action client when any of them dies. I would like the client to be notified by the server whenever this server dies. Similarly, I would like the server to be notified if the current client dies for some reason.

I am using a simple action server with the execute callback option, and a client with the done, active and feedback callbacks.

In the destructor of the node containing the action server, I have added the following code:

if ( as_.isActive() )

Unfortunately, the client never gets any kind of notification. I was expecting the done callback to receive an aborted status, or something similar.

For the client notification, I have tried to use the isServerConnected() and getState() functions from the node's destructor, but I always get the same result whether the server is running or not: isServerConnected()=0 and getState()=Aborted. I have also called cancelGoal() and stopTrackingGoal() to let the server cancel the current goal, but they seem to have no effect.

Maybe I am missing some important key points. Any Suggestion?


edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2011-07-26 07:26:46 -0500

eitan gravatar image

I think I've run into this before when trying to do something similar. In my case, ROS had already shutdown when my destructor was called which meant that no actionlib related messages were going over the wire.

There's actually a tool called bond that would be perfect for your use case. Not only will it let you know when nodes go down cleanly, it'll also let you know if they go down from a crash. Hope this helps.

edit flag offensive delete link more

Question Tools


Asked: 2011-07-24 23:04:30 -0500

Seen: 595 times

Last updated: Jul 26 '11