Hi all,

Currently Message Broker enables flow controlling based on the content
chunk count. The configuration as shown below.

<flowControl>
<global>
            <lowLimit>800</lowLimit>
            <highLimit>8000</highLimit>
        </global>

        <bufferBased>
            <lowLimit>100</lowLimit>
            <highLimit>1000</highLimit>
        </bufferBased>
</flowControl>

Flow controlling is enabled when the chunk count that is read from the
buffer is higher than the specified number.

Since this is misleading for a user, we decided to set the above limits for
buffer sizes in Bytes.

With the new implementation, we face many problems since we cannot not
relate between the number of messages and the total space occupied by
messages at the configuration time (Messages with different sizes could be
published). Following are the problems faced due to this:

   - Flow controlling buffer limits are set for sizes in bytes.
   - Mina buffer accepts all the messages until we enable flow controlling.
      (It is enabled when the total size of the messages read by *the
      broker* is higher than the specified limit.)
      - For the given limit, the number of messages that could be taken in
      is high for small messages.
      - More time is taken to read and process a large number of small
      messages.
      - Therefore, by the time the broker enables flow controlling, the
      Mina buffer would have overflowed.

      - The ring buffer in the disruptor is initialized with a specified
   buffer size with a given number of elements.
      - If the publisher sends messages with smaller sizes, a large number
      of messages will be taken in before flow controlling is enabled, and the
      disruptor will overflow.
   - The user cannot relate between the number of messages that are
   published before flow controlling is enabled (By having a count specified
   as in the existing approach, the number of messages that are taken in is
   constant whatever the message size is).

Therefore, we decided to leave the configuration as it is. Any comments are
highly appreciated.

Thank you
-- 
Sasikala Kottegoda
*Software Engineer*
WSO2 Inc., http://wso2.com/
lean. enterprise. middleware
Mobile: +94 774835928/712792401
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to