Why would a write cause this error?

3 posts / 0 new
Last post
Offline
Last seen: 3 weeks 6 hours ago
Joined: 07/30/2021
Posts: 1
Why would a write cause this error?

I'm getting this error when running my application.

    terminate called after throwing an instance of 'dds::core::TimeoutError'
      what():  write
    terminate called after throwing an instance of 'dds::core::TimeoutError'
      what():  write

And from the `what(): write`, I'm guessing that's when I write out a message like so

    my_writer->write(msg);
    
But I can't understand why I would be getting a timeout for a write and was hoping for some hints as to what might cause this.



Offline
Last seen: 1 month 4 days ago
Joined: 04/02/2013
Posts: 172

A reliable reader can block. When write() blocks for longer than the writer's max blocking time it fails with a TimeoutError.

See: 

  • https://community.rti.com/static/documentation/connext-dds/6.1.0/doc/manuals/connext_dds_professional/users_manual/index.htm#users_manual/Writing_Data.htm#7.3.8.1_Blocking_During_a_write()%3FTocPath%3DPart%25202%253A%2520Core%2520Concepts%7C7.%2520Sending%2520Data%7C7.3%2520DataWriters%7C7.3.8%2520Writing%2520Data%7C_____1
  • https://community.rti.com/static/documentation/connext-dds/6.1.0/doc/api/connext_dds/api_cpp2/classdds_1_1pub_1_1DataWriter.html#ae02db70be8d1a4e20c15881d79a5d038
Offline
Last seen: 1 month 4 days ago
Joined: 04/02/2013
Posts: 172

Before I meant: "a reliable writer can block"