Skip to content

Implement yarp::os::ContactStyle bindings and option "persist" in yarp.Network.connect #26

Description

@nunoguedelha

Preliminary checks

  • "persistent" option working on the terminal.
    yarp connect --persist OUTPUT_PORT INPUT_PORT
    yarp connect --persist-from OUTPUT_PORT INPUT_PORT
    yarp connect --persist-to OUTPUT_PORT INPUT_PORT
    
  • Test in Javascript/Node.js : ⚠️ FAIL ⚠️ . Bindings to the class yarp::os::ContactStyle are not implemented.
    ...

Other tests and obsevations:

...

  • Creating a persistent connection before creating the /write /read ports only works if we use the prefix topic://aTopic. Doing:
    yarp topic /aTopic
    yarp connect /write /aTopic
    [ERROR] |yarp.os.Network| Failure: could not find source port /write
    
    doesn't work without the --persit explicit option.
    ...

Conclusion

Having this in mind and the fact that Bindings to the class yarp::os::ContactStyle are not implemented, it seems easier to use topics for creating persistent connections, although the approach using the style option would be simpler if yarp::os::ContactStyle was available.

The drawback is that we won't be able to cleanup the topics once we don't need them anymore (unless we run a child process just for that of course, which we should avoid).

It might be worth trying to create the bindings for the class yarp::os::ContactStyle. If it's not straightforward enough, we'll go for the topics solutions.

Originally posted by @nunoguedelha in ami-iit/yarp-openmct#68 (comment)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions