FioranoMQ offers a very high message throughput and low latency for non-persistent messages. The boost in delivery rates has been achieved through a series of algorithmic changes for multi-threaded scenarios, data-copy optimizations, transport layer enhancements, changes in flow-control semantics, and removing bottlenecks from the code.
FioranoMQ provides the following configuration options for tuning the publish-subscribe model:

Setting the Message Receipt Acknowledgement

In the DupsOkBatchSize mode, message receipt acknowledgement is sent after a configurable number of messages. By default the number is 20.
Following steps enable you to configure this parameter through Fiorano Studio in the offline mode:

  1. Invoke the Fiorano Studio.
  2. Select Tools > Configure Profile from the menu bar, select the FioranoMQ folder, and click the Open button. This shifts the FioranoMQ environment to the offline mode.
  3. Navigate to FioranoMQ -> Fiorano -> mq -> pubsub -> TopicSubSystem in the Profile Manager pane. The properties of the CommonConfig are displayed in the Properties pane.
  4. Select ellipsis against the parameter DupsOkBatchSize. Enter the new value in the resulting DupsOkBatchSize dialog box and click OK.
  5. Right-click on FioranoMQ domain in the Profile Manager pane and select the Save option.

Setting in-memory buffers for Subscribers

Another mechanism to manage the flow control is to increase the size of the in-memory buffers of the topic and the subscribers with the Publisher slowdown algorithm option enabled. This will delay the initialization of publisher slowdown algorithm and increase the overall throughput. In scenarios where the subscriber receives messages slowly, increasing the buffer size may lead to the Publisher slowdown algorithm not initialize at all. This depends on the rate at which the messages are being published on the server. It is configurable using a parameter named BasicAllowedSize through Fiorano Studio in the offline mode. The default value of this variable is 1024 KB. This can be increased to a higher value depending on the scenario.
Following steps enable you to configure this parameter:

  1. Invoke the Fiorano Studio.
  2. Select Tools > Configure Profile from the menu bar, select the FioranoMQ folder and click the Open button. This shifts the FioranoMQ environment to the offline mode.
  3. Navigate to FioranoMQ -> Fiorano -> mq -> pubsub -> TopicSubSystem in the Profile Manager pane. The properties of the PubSub Manager are displayed in the Properties pane.
  4. Select the ellipsis against the parameter BasicAllowedSize. Enter the new value in the resulting BasicAllowedSize dialog box and click OK.
  5. Right-click on FioranoMQ domain in the Profile Manager pane and select the Save option.

Setting Parameters for New Pubsub Algorithm to Handle Slow Subscribes

The previous releases of FioranoMQ had no option to disable slowing down of the publisher when the subscribers happen to be slow. In the default configuration, the publisher blocks by predefined timeout and flow control starts.
From this release of FioranoMQ Server, the option of persisting the message to disk when subscriber becomes slow and publisher slowdown is disabled. The fast subscriber never gets affected by any number of slow subscribers.
The following are the parameters that determine the different behaviors of the algorithm and these parameters can be configured from the profile in Fiorano Studio (FioranoMQ->fiorano->mq->pubsub->TopicSubSystem) when "DemuxWhilePublishing" flag is set to 'yes'.
Note: FioranoMQ->fiorano->mq->pubsub->Topics->TopicName->DemuxWhilePublishing flag should be set to yes to make the new pubsub algorithm work where TopicName is the name of the Topic created in the FioranoMQ Server.

  • StoreMessageToDisk: When the session buffer in the client runtime overflows, the session state in server becomes passive and publisher starts pushing the message into temporary persistent queue in disk for that particular session. The slow subscriber will not receive the messages till the client's session buffer can accommodate more messages. Normal subscriber keeps receiving the message as publisher never slows down.

This parameter is navigated in the profile as follows:
FioranoMQ->fiorano->mq->pubsub->TopicSubSystem->StoreMessageToDisk
The default value of this parameter is set to "yes". The result of this parameter is not effective for non-persistent message that can be discarded.

  • PublishWait: indicates the default time interval by which the publisher slows down when

EnablePublisherSlowdown is set to "yes". As the size of Persistent Session Queue (PSQ) changes, the publisher blocking time also changes according to exponential back-off algorithm.
This parameter is navigated in the profile as follows:
FioranoMQ->fiorano->mq->pubsub->TopicSubSystem->PublishWait
The default value of this parameter is 5 millisecond (this cannot take values less than equal to 0).

  • EnablePublisherSlowdown: If it's set to "no" then the publisher while sending messages to the persistent queue, never slows down. It is used when publisher flow control is preferred and there are many slow subscribers. This option should be carefully selected considering different options as mentioned above. If this option is selected, the publisher will always slow down. The slow down time starts from the value specified by another parameter called publishWait. It increases according to the slowdown algorithm that depends on the size of persistent message queue for every slow subscriber. This slow down time dynamically changes as and when persistent storage keeps changing its size. This option dynamically balances the Publisher slowdown and the size of persistent message in the disk. It is recommended that the server should be run with a higher value of heap (> 256 MB) size, when it is run with EnablePublisherSlowdown flag set to false because the publisher accumulates messages into the disk at a speed faster than the speed at which it becomes empty.

This parameter is navigated in the profile as follows:
FioranoMQ->fiorano->mq->pubsub->TopicSubSystem->EnablePublisherSlowdown
The default value of this parameter is "no". If the user wants to have publisher flow control, then this parameter should be set to "yes" and the PublishWait parameter should be set accordingly.

  • DropOldestMessage: If set to "yes", the publisher first drops the oldest message from the persistent store and pushes the latest one into the queue thereby ensuring the maximum size of persistent store.

This parameter is navigated in the profile as follows:
FioranoMQ->fiorano->mq->pubsub->TopicSubSystem->DropOldestMessage
The default value of this parameter is set to "no". If the user wants to drop the latest message when the size of the total messages in the disk cross over a certain threshold, this parameter should be set to its default value.

  • MaxPersistentStoreSize: indicates the maximum size of the total messages stored in persistent queue in the disk. Once the current size cross over this threshold, the publisher starts dropping them if DropOldestMessage flag is set to "no". If this flag is set to "yes", the publisher first drops the oldest message from the persistent store and pushes the latest one.

This parameter is navigated in the profile as follows:
FioranoMQ->fiorano->mq->pubsub->TopicSubSystem->MaxPersistentStoreSize
The default value of this parameter is 1073741824 in bytes.
Note: This algorithm needs the new profile to be used in running the server. Older profile has to be ported to the new profile. To port older profile to the current profile, configurations need to be replicated manually. The server is recommended to run with JVM heap size according to the following setting to be made in fiorano_vars.bat/.sh
JVM_SERVER_ARGS=-server -Xms256m -Xmx512m (-Xms512m -Xmx1024m for enterprise operation)

Adaptavist ThemeBuilder EngineAtlassian Confluence