Openfire cannot handle huge load of messages

Hello everyone,

I’ve two different machines, one running an xmpp client and the other one is running a container which has openfire on it.

VM1: An application using XMPP Client (Libstrophe) with 100 Anon Users Registerd
VM2: Container with Openfire 4.6.4

The problem is; when I do benchmark testing, i.e. sending messages from VM1 to VM2, the throughput is so high that I get a SIGPIPE error on VM1. I guess that Openfire cannot handle sooo many messages at a time and the PIPES of VM#1 are full.

I tried to increase the buffer size from Openfire WEBUI but it seems that it cannot be done through there :slight_smile: Should I increase these limits from the Container that Openfire is running on? Or do you folks have any idea how can I overcome this SIGPIPE error and handle more messages at any time?

Any help & comment is appreciated, many thanks in advance.

Although not written for raw performance, Openfire can be used to have many thousands of concurrent connections. At or above roughly 10.000 connections, specialized configuration is typically needed (your mileage will vary greatly, depending on use-cases and hardware).

As an aside - if people run into issues with these kind of numbers, they might want to consider enlisting the help of one of our professional support providers.

I’m not sure what’s going wrong in your specific setup. If it’s not an issue with the test setup itself, then common bottlenecks are caches that are undersized, or some kind of constraint on a shared resource (such as the database, or a thread pool). After cache utilization can be reviewed on the admin console. Creating thread dumps (either manually, or through the Openfire plugin aptly named ‘Thread Dump’) can often be used to pinpoint a source of resource contention.

Thank you for your response. In my case, there not that many connections, just 100. I try to send huge simultaneous messages from these users. How can I increase the Read Buffer in Openfire? Is there any way to increase that number from Openfire Settings? Or we need to configure that number right inside the Host OS (the Environment that Openfire runs on)?

The read buffer for port 5222 is controlled by the property xmpp.client.maxReadBufferSize. For 5223, use xmpp.client_ssl.maxReadBufferSize

That said, the chances that this happens to be the bottleneck that you’re running into are slim. My advise would be to first perform more diagnostics, before changing properties.