DDS 1.2 RTF Avatar
  1. OMG Issue

DDS12 — Should write() block when out of instance resources?

  • Key: DDS12-19
  • Legacy Issue Number: 9496
  • Status: closed  
  • Source: Real-Time Innovations ( Dr. Gerardo Pardo-Castellote, Ph.D.)
  • Summary:

    Currently it is stated that write() and dispose() may block and return TIMEOUT when the RELIABILITY QoS kind is set to RELIABLE and any of the RESOURCE_LIMITS QoS is hit.
    We should reconsider the action taken when it is instance resource limits that are hit. If instance resources are kept around until they are unregistered (and not even yet considering how RELIABILITY or DURABILITY QoS affects this), then it seems awkward to block when the user is required to take action. Perhaps returning immediately with OUT_OF_RESOURCES makes more sense in this situation.

    Proposed Resolution:
    When the writer is out of instance resources because all max_instances have been registered or written, the write/dispose() call will return OUT_OF_RESOURCES instead of blocking if it can be detected.

    Proposed Revised Text:

    Section 2.1.2.4.2.11 write
    Above the paragraph starting with "In case the provided handle is valid"; add the paragraph:
    Instead of blocking, the write operation is allowed to return immediately with the error code OUT_OF_RESOURCES provided the following two conditions are met:
    1. The reason for blocking would be that the RESOURCE_LIMITS are exceeded.
    2. The service determines that waiting the 'max_waiting_time' has no chance of freeing the necessary resources. For example, if the only way to gain the necessary resources would be for the user to unregister an instance.

    Section 2.1.2.4.2.12 write_w_timestamp
    After the paragraph "This operation may block" add the paragraph:
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

    Section 2.1.2.4.2.13 dispose
    After the paragraph "This operation may block…" add the paragraph:
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

    Section 2.1.2.4.2.14 dispose_w_timestamp
    After the paragraph "This operation may block…" add the paragraph:
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

    Section 2.1.2.4.2.14 dispose_w_timestamp
    After the paragraph "This operation may block…" add the paragraph:
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

    Section 2.1.2.4.2.5 register

    Replace the paragraph:
    This operation may block if the RELIABILITY kind is set to RELIABLE and the modification would cause data to be lost or else cause one of the limits specified in the RESOURCE_LIMITS to be exceeded. Under these circumstances, the RELIABILITY max_blocking_time configures the maximum time the write operation may block (waiting for space to become available). If max_blocking_time elapses before the DataWriter is able to store the modification without exceeding the limits, the operation will fail and return TIMEOUT.

    With:
    This operation may block and return TIMEOUT under the same circumstances described for the write operation (Section 2.1.2.4.2.11).
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

    Section 2.1.2.4.2.5 register_w_timestamp

    Replace the paragraph:
    This operation may block and return TIMEOUT under the same circumstances described for the register_instance operation (Section 2.1.2.4.2.5 ).
    With:
    This operation may block and return TIMEOUT under the same circumstances described for the write operation (Section 2.1.2.4.2.11).
    This operation may return OUT_OF_RESOURCES under the same circumstances described for the write operation (Section 2.1.2.4.2.11).

  • Reported: DDS 1.1 — Sun, 2 Apr 2006 05:00 GMT
  • Disposition: Resolved — DDS 1.2
  • Disposition Summary:

    see above

  • Updated: Fri, 6 Mar 2015 20:58 GMT