-
Notifications
You must be signed in to change notification settings - Fork 144
Add tests demonstrating failure to recover from stream starvation #552
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
35b5de3
c0348ab
3703fee
4aaffdf
9196723
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5,6 +5,23 @@ This document contains notes on the migration of the ur_client_library between m | |
|
|
||
| It contains only breaking changes. | ||
|
|
||
| Migrating from 2.x.x to 3.x.x | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @urfeex - Wanted to call this to your attention, since I note that you tagged this into the 2.15 version. This was speculative that the major version would bump with the wire, so if that isn't true, this should be reverted.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We'll make a decision today when to include this. I've merely added it to the milestone so that I don't make a release without considering this beforehand. Most likely, this will indeed go to a 3.x release, though.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I've moved it to a 2.15.1 milestone. We think that we can do this without an API breaking change (I will make a review about this later). The wire-breaking changes are acceptable, since we consider the communication between the script code and the library an internal asset. We'll add a clear statement about this, separately. We have been doing wire-breaking changes in the past, as well. |
||
| ----------------------------- | ||
|
|
||
| - Trajectory point records sent on the "trajectory_socket" have gained a trailing field, and the | ||
| trajectory control message sent on the "reverse_socket" now carries a move identifier in a slot | ||
| that was previously zero padding. See :ref:`trajectory_point_interface` and | ||
| :ref:`reverse_interface` for the two layouts. The library and the ``external_control.urscript`` | ||
| that it sends to the robot must be upgraded together, because neither one can read the other's | ||
| record layout. This only affects you if you supply your own copy of the script rather than | ||
| using the one shipped alongside the library. | ||
|
|
||
| - ``urcl::control::ReverseInterface::writeTrajectoryControlMessage()`` takes a new ``move_id`` | ||
| argument, which sits before the existing ``robot_receive_timeout`` argument. Callers that | ||
| passed a receive timeout positionally will no longer compile until they are updated. Callers | ||
| that go through ``urcl::UrDriver`` need no change, since it assigns move identifiers on their | ||
| behalf. | ||
|
|
||
| Migrating from 1.x.x to 2.x.x | ||
| ----------------------------- | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,6 +28,7 @@ | |
| #ifndef UR_CLIENT_LIBRARY_UR_UR_DRIVER_H_INCLUDED | ||
| #define UR_CLIENT_LIBRARY_UR_UR_DRIVER_H_INCLUDED | ||
|
|
||
| #include <atomic> | ||
| #include <chrono> | ||
| #include <functional> | ||
| #include <memory> | ||
|
|
@@ -1136,6 +1137,13 @@ class UrDriver | |
| std::unique_ptr<control::ScriptSender> script_sender_; | ||
| std::unique_ptr<control::ScriptReader> script_reader_; | ||
|
|
||
| // Identifies the move that is currently being sent to the robot. The driver is what assigns these | ||
| // identifiers, because it is the only object which observes both the boundaries between moves and | ||
| // every point written within them. It issues one identifier for each command that begins a move, | ||
| // and never reuses one for the life of a connection. A value of 0 belongs to no move, and is what | ||
| // the robot holds before it has been told about any. | ||
| std::atomic<int32_t> trajectory_move_id_ = { 0 }; | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could we move this to the ReverseInterface, instead? This way we would not need to expose it on the ReverseInterface's |
||
|
|
||
| size_t socket_connection_attempts_ = 0; | ||
| std::chrono::milliseconds socket_reconnection_timeout_ = std::chrono::milliseconds(10000); | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One way to avoid wire-breaking here, would be to re-use the
ScriptReader::isVariableRegistered(const std::string& key)function introduced in 01292bd.