6 Quality Of Service And Admin Properties
6.1 Quality Of Service And Admin Properties
This chapter explain the allowed properties for CosNotification_QoSAdmin and CosNotification_AdminPropertiesAdmin.
6.1.1 Quality Of Service
The cosNotification application supports the following QoS settings:
QoS Range Default Comment EventReliability BestEffort BestEffort To allow Persistent EventReliability every event must be stored in a stable storage which would create a relatively huge overhead. Hence, only BestEffort is supported. ConnectionReliability BestEffort/Persistent BestEffort If this QoS is set to BestEffort and a client object returns anything else than ok
to its associated Proxy, the Proxy will discard all events and terminate. Using Persistent and anything else thanok
is returned events will be dropped but the proxy will retry later when next delivery is due. A child may not have Persistent while its parent have BestEffort QoS set, e.g., Proxy vs. Admin.Priority +/-32767 0 This QoS will treat all events as if they have the Priority equal to current value, unless the event itself contain a Priority setting, this event will be treated accordingly. Note, for this property to have any effect the DiscardPolicy and/or OrderPolicy must be set to PriorityOrder. OrderPolicy Any-, Fifo-, Priority- and Deadline-Order PriorityOrder If set to PriorityOrder events with the highest Priority will be delivered first. Deadline order will forward events with with shortest expiry time first. If two events have the same priority they will be delivered in FIFO-order. DiscardPolicy RejectNewEvents, Any-, Fifo-, Lifo-, Priority- and Deadline-Order RejectNewEvents If set to PriorityOrder and MaxEventsPerConsumer limit is reached events with the lowest Priority will be discarded first. Deadline order will discard events with with shortest expiry time first. MaximumBatchSize long() > 0 100 Only valid if the object is supposed to handle a sequence of structured events and determines the largest amount of events that may be passed each time. PacingInterval TimeBase::TimeT (see cosTime) 20 Seconds Determines how long an object will wait before forwarding an structured event sequence of length equalt to or less than MaximumBatchSize. StartTimeSupported boolean false If set to true events which contains the QoS Property StartTime
(TimeBase::UtcT - absolute time) will not be delivered until the StartTime value have been exceeded. See also thecosTime
application.StopTimeSupported boolean false If set to true events which contains the QoS Properties StopTime
(TimeBase::UtcT - absolute time) orTimeout
(TimeBase::TimeT - relative time) will be discarded if the object not have been able to deliver the event in time. See also thecosTime
application.MaxEventsPerConsumer long() > 0 100 The maximum number of events the associated object may store before discarding events in the way described by the DiscardPolicy. Timeout TimeBase::TimeT (see cosTime) No timeout If this QoS property is not included in the event, and the Property StopTimeSupported
equals true, this setting will be applied if events cannot be delivered within its time limit.Table 1: Supported QoS settings
Several of the above QoS Properties can be changed during run-time but we strongly advice not to since, if a relatively large amount of events is waiting for delivery, some of the QoS settings would require a total reorder of the events. The QoS property
ConnectioReliability
may never be updated during run-time since it may cause deadlock. Run-time, in this case, means activating the Channel by sending the first event.6.1.2 Setting Quality Of Service
Assume we have a Consumer Admin object which we want to change the current Quality of Service. Typical usage:
QoSPersistent = [#'CosNotification_Property' {name='CosNotification':'ConnectionReliability'(), value=any:create(orber_tc:short(), 'CosNotification':'Persistent'())}], 'CosNotification_QoSAdmin':set_qos(Ch, QoSPersistent),If it is not possible to set the requested QoS the
UnsupportedQoS
exception is raised, which inlcudes a sequence ofPropertyError
's describing which QoS, possible range and why is not allowed. The error codes are:
- UNSUPPORTED_PROPERTY - QoS not supported for this type of target object.
- UNAVAILABLE_PROPERTY - due to current QoS settings the given property is not allowed.
- UNSUPPORTED_VALUE - property value out of range; valid range is returned.
- UNAVAILABLE_VALUE - due to current QoS settings the given value is not allowed; valid range is returned.
- BAD_PROPERTY - unrecognized property.
- BAD_TYPE - type of supplied property is incorrect.
- BAD_VALUE - illegal value.
The CosNotification_QoSAdmin interface also supports an operation called
validate_qos/2
. The purpose of this operations is to check if a QoS setting is supported by the target object and if so, the operation returns additional properties which could be optionally added as well.6.1.3 Admin Properties
The cosNotification application supports the following Admin Properties:
Property Range Default MaxQueueLength 0 0 MaxConsumers long() >= 0 0 MaxSuppliers long() >= 0 0 Table 2: Supported Admin Properties According to the OMG specification the default values for Admin Properties is supposed to be
0
, which means that no limit applies to these properties.
Admin Properties can only be set on a Channel Object level, i.e., they will not have an impact on any Admin or Proxy Objects. Currently, setting the Admin Property
MaxQueueLength
have no effect since we cannot discard events accordingly to the Quality of Service PropertyDiscardPolicy
.