This repository describes how to run stress testing of ONLYOFFICE Document Server using JMeter.
-
Install JMeter. Instructions for command line installation and usage on Debian-based systems are available here.
-
Install the "WebSocket Samplers by Peter Doornbosch" JMeter plugin via JMeter Plugins Manager or manulally as a .jar file.
-
Set property
websocket.thread.stop.policy=wsclose
according to these instructions. -
Set services.CoAuthoring.token.enable.browser configuration file property to false.
number-of-threads
: JMeter thread group property.server-name-or-ip
: WebSocket host.port
: WebSocket port, the full URL looks likews://${server-name-or-ip}:${port}/doc/${doc-id}/c/806/e204ietx/websocket
.document-url
: URL to the docx document.callback-url
: URL to send the assembled file (if empty, forgotten will be stored). Starting from version 6.5 of ONLYOFFICE Document Server, you can use dummyCallback handler.changes
: Only fits with a specificdocument-url
and version 6.3 of ONLYOFFICE Document Server.save-changes-throughput-per-minute
: Amount of saveChanges per minute (see JMeter constant throughput timer).close-session-percent-per-minute
: Percentage of threads closing the connection at the end of the minute, calculated by __threadNum.connect-timeout
: Connect timeout (ms) for all requests.download-timeout
: Response (read) timeout (ms) for operations: "read documentOpen".auth-timeout
: Response (read) timeout (ms) for operations: "open and send auth".read-timeout
: Response (read) timeout (ms) for operations: "read license", "read auth", "read getLock", "read saveLock", "read unSaveLock".conversion-timeout
: Response (read) timeout (ms) for operations: "read documentOpen".close-timeout
: Response (read) timeout (ms) for operations: "close".
Follow these steps:
- Open document with
document-url
in Chrome with ONLYOFFICE editor (Document Server). - Open Chrome DevTools (Ctrl + Shift + I) when opening a file.
- Make some changes in the editor in the Strict co-editing mode and press Save.
- Go to the Network tab.
- Find the WebSocket Messages tab.
- Cut out
changes
param from the message that starts with["{\"type\":\"saveChanges\"
. Use it as thechanges
parameter.