{"id":20770833,"url":"https://github.com/ably/ably-jmeter","last_synced_at":"2026-04-18T20:32:20.337Z","repository":{"id":46972787,"uuid":"271527415","full_name":"ably/ably-jmeter","owner":"ably","description":"An Apache JMeter plugin for Ably testing and benchmarking","archived":false,"fork":false,"pushed_at":"2021-09-19T20:15:50.000Z","size":4570,"stargazers_count":0,"open_issues_count":0,"forks_count":3,"subscribers_count":24,"default_branch":"main","last_synced_at":"2025-03-11T19:49:43.080Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ably.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-06-11T11:21:00.000Z","updated_at":"2021-09-19T20:15:48.000Z","dependencies_parsed_at":"2022-08-28T14:02:43.781Z","dependency_job_id":null,"html_url":"https://github.com/ably/ably-jmeter","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ably/ably-jmeter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fably-jmeter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fably-jmeter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fably-jmeter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fably-jmeter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ably","download_url":"https://codeload.github.com/ably/ably-jmeter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ably%2Fably-jmeter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31984127,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"ssl_error","status_checked_at":"2026-04-18T20:23:29.375Z","response_time":103,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-17T12:12:25.863Z","updated_at":"2026-04-18T20:32:20.310Z","avatar_url":"https://github.com/ably.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ably-jmeter\n\nAn Ably JMeter Plugin supporting the creating of [Apache JMeter](https://jmeter.apache.org/) tests involving Ably clients.\n\n## Status\n\nThis is in preview. All feedback and Pull Requests are welcomed.\n\nThis is evolving and liable to change. Class and property names and behaviour are all subject to change; anticipate any test plan using this to be invalidated by future releases.\n\n## Installation\n\nThe plugin is a standard JMeter plugin. You can download the latest version of ably-jmeter from [Github](https://github.com/ably/ably-jmeter/releases), and then copy the downloaded JAR file into the `$JMETER_HOME/lib/ext` directory. After restarting JMeter, the Ably samplers provided by this plugin are available.\n\n## Prerequisites\n\nThis has been tested with JMeter 5.1 and above.\n\n## Build from source code\n\nTo build the plugin binary from source, clone the repo and run `gradle build`.\n\n# Properties\n\nA number of JMeter properties can be defined as User Defined Variables, and these will be used as defaults where applicable:\n\n- `ably.environment`: a default for the `Environment` setting in the Ably samplers which, where specified, is used as the value of the `environment` `ClientOption`.\n\n- `ably.api_key`: a default for the `API Key` setting. Where specified, this is used as the `key` `ClientOption`.\n\n# Samplers\n\nThe plugin includes the following samplers.\n\n## REST operations\n\nSamplers exist that initialise an Ably REST or Realtime client.\n\n### Ably REST Configuration\n\nThis creates a REST client based on given parameters, which is stored in a JMeter variable (ie in thread scope) and usable by other REST operations.\nThe sampled operation is the (trivial) client instance creation.\n\n#### Configuration options\n\n- **Environment**: specify a non-default Ably endpoint via the `environment` client option.\n\n- **API key**: the Ably API key to use.\n\n- **ClientId**: the `clientId`. Optionally a random suffix can be added to the given `clientId`.\n\n- **Log level**: the `logLevel` passed to the ably library instance. Logging from the library goes to the default logger in the JMeter application, and therefore will be further filtered by the log level specified in JMeter itself.\n\n#### Variables\n\nThe variables added to thread scope are:\n\n- `ably.rest_client`: the REST client instance.\n\n- `ably.client_id`: the `clientId` associated with the instance (including any randomly-generated part).\n\n### Ably REST publish\n\nThis publishes a message on a named channel, with an Ably REST client instance previously established in the thread. The sampled operation is the publish and acknowledgement of the message.\n\n### Configuration options\n\n- **Channel name**: the name of the channel to use. Optionally, a random suffix can be added to the given name.\n\n- **Payload**: a specified payload, or auto-generated payload of a given length, may be specified. The payload becomes the `data` part of the message.\n\n- **Event name**: a specified `name` value for the message.\n\n- **Encoding**: a specified `encoding` value for the message. There is no attempt to infer the `encoding` from the given payload value.\n\n- **Timestamp**: optionally, the time at which the publish is initiated by the sampler, is added to the message in `extras.metadata.timestamp` as a number, Unix time in milliseconds.\n\n### Variables\n\nThe variables added to thread scope are:\n\n- `ably.channel_name`: the channel name used for the publish (including any randomly-generated part).\n\n### Ably REST Stats\n\nThis makes a single stats request using a previously established REST client. The JSON stats response is included in the sample response data, and can be processed by any relevant postprocessor (eg JSON extractor). The sampled operation is the stats request itself. Pagination is currently not supported.\n\n#### Configuration options\n\n- **Start**: this specifies the `start` request param which can be a formatted date/time string, or a Unix time in milliseconds. It defaults to the `TESTSTART.MS` JMeter property.\n\n- **End**: this specifies the `end` request param which can be a formatted date/time string, or a Unix time in milliseconds. It defaults to being unspecified, which means that stats up to the time of the call are included.\n\n- **Limit**: this specifies the `limit` request param. It defaults to `10`.\n\n- **Unit**: this specifies the `unit` request param which determines the granularity of the stats request. It defaults to `minute`.\n\n- **Direction**: this specifies the `direction` request param, which determines the order in which stats results are returned. It defaults to `backwards` - ie, most recent time intervals are listed first.\n\n#### Variables\n\nNo variables are added to thread scope.\n\n### Ably REST History\n\nThis makes a single history request using a previously established REST client. The JSON history response is included in the sample response data, and can be processed by any relevant postprocessor (eg JSON extractor). The sampled operation is the history request itself. Pagination is currently not supported.\n\n#### Configuration options\n\n- **Start**: this specifies the `start` request param which can be a formatted date/time string, or a Unix time in milliseconds. It defaults to the `TESTSTART.MS` JMeter property.\n\n- **End**: this specifies the `end` request param which can be a formatted date/time string, or a Unix time in milliseconds. It defaults to being unspecified, which means that history up to the time of the call is included.\n\n- **Limit**: this specifies the `limit` request param. It defaults to `100`.\n\n- **Direction**: this specifies the `direction` request param, which determines the order in which stats results are returned. It defaults to `backwards` - ie, most recent time intervals are listed first.\n\n#### Variables\n\nNo variables are added to thread scope.\n\n## Realtime operations\n\n### Ably Connect\n\nThis creates a Realtime client based on given parameters, which is stored in a JMeter variable (ie in thread scope) and usable by other Realtime operations.\n\n#### Configuration options\n\n- **Environment**: specify a non-default Ably endpoint via the `environment` client option.\n\n- **API key**: the Ably API key to use.\n\n- **ClientId**: the `clientId`. Optionally a random suffix can be added to the given `clientId`.\n\n- **Log level**: the `logLevel` passed to the ably library instance. Logging from the library goes to the default logger in the JMeter application, and therefore will be further filtered by the log level specified in JMeter itself.\n\n#### Variables\n\n- `ably.realtime_client`: the Realtime client instance.\n\n### Ably Disconnect\n\nThis closes a previously established Ably connection.\n\n### Ably Realtime publish\n\nThis publishes a message on a named channel using an established realtime connection, via a transient publish operation. The sampled operation is the publish and acknowledgement of the message.\n\n#### Configuration options\n\n- **Channel name**: the name of the channel to use. Optionally, a random suffix can be added to the given name.\n\n- **Payload**: a specified payload, or auto-generated payload of a given length, may be specified. The payload becomes the `data` part of the message.\n\n- **Event name**: a specified `name` value for the message.\n\n- **Encoding**: a specified `encoding` value for the message. There is no attempt to infer the `encoding` from the given payload value.\n\n- **Timestamp**: optionally, the time at which the publish is initiated by the sampler, is added to the message in `extras.metadata.timestamp` as a number, Unix time in milliseconds.\n\n#### Variables\n\nThe variables added to thread scope are:\n\n- `ably.channel_name`: the channel name used for the publish (including any randomly-generated part).\n\n### Ably Realtime Subscribe\n\nThis subscribes to a given channel via a previously established realtime connection. The sampled operation is subscription for a given time, or a given number of messages. If the connection failed to be established, this publish sampler will fail immediately.\n\n#### Configuration options\n\n- **Channel name**: the name of the channel to use.\n\n- **Sample on**: The basis on which sampling is performed. The default value is '**elapsed with specified time(ms)**', which means a sub sampler will occur every specified milli-seconds (default is 1000ms). During the 1000 ms, multiple messages could be received, and result in report is the summarized data during 1000 ms. If the value is set to 2000, then means summarized report during 2000 ms. Another option is '**number of received messages**', which means a sub sampler will occur after receiving these specified number of messages (default is 1). \n\n- **Debug response**: If checked, the received message will be displayed in the sampler response.\n\n- **Timestamp**: if the publisher added the publish time as message metadata, then this sampler will determine the mean latency across the sample as report that in the sample result.\n\n#### Variables\n\nNo variables are added to thread scope.\n\n### Ably Realtime Group samplers\n\nAnalogues of the Connect, Disconnect, and Subscribe samplers exist that operate on a group of realtime connections. The Ably Group Connect sampler has an additional **Group count** configuration option (defaulting to 32) that defines the number of parallel connections created. These primitives can be used to create test plans with very large numbers of connections without the adverse memory impact of having a large number of JMeter threads.\n\n## SSE operations\n\n### Ably SSE Connect\n\nThis creates an SSE subscription based on given parameters. Since subscription parameters are specified at the time of connection, this includes both connection and subscription-related configuration options.\n\n#### Configuration options\n\n- **Environment**: specify a non-default Ably endpoint via the `environment` client option.\n\n- **API key**: the Ably API key to use.\n\n- **ClientId**: the `clientId`. Optionally a random suffix can be added to the given `clientId`.\n\n- **Channel name**: the name of the channel to use.\n\n- **Sample on**: The basis on which sampling is performed. The default value is '**elapsed with specified time(ms)**', which means a sub sampler will occur every specified milli-seconds (default is 1000ms). During the 1000 ms, multiple messages could be received, and result in report is the summarized data during 1000 ms. If the value is set to 2000, then means summarized report during 2000 ms. Another option is '**number of received messages**', which means a sub sampler will occur after receiving these specified number of messages (default is 1). \n\n- **Debug response**: If checked, the received message will be displayed in the sampler response.\n\n- **Timestamp**: if the publisher added the publish time as message metadata, then this sampler will determine the mean latency across the sample as report that in the sample result.\n\n#### Variables\n\n- `ably.sse_client`: the Realtime client instance.\n- `ably.channel_name`: the channel name used for the publish (including any randomly-generated part).\n\n### Ably SSE Disconnect\n\nThis closes a previously established SSE connection.\n\n## Test app creation\n\nFor CI testing purposes, it is possible to create a temporary app.\n\n### Ably Create Test App\n\nThis creates a temporary app in a given environment. This may be used witih a setup threadgroup of a test plan. By default this creates a single root key in the app, and the following namespaces:\n\n- `push`: a push-enabled namespace;\n- `persisted`: a persistence-enabled namespace.\n\n#### Configuration options\n\n- **Environment**: specify a non-default Ably endpoint via the `environment` client option.\n\n#### Variables\n\nThe variables added to thread scope are:\n\n- `ably.app_spec`: an object mirroring the `AppSpec` response format of the `/apps` creation endpoint. This gives access to details of the keys, namespaces and other details of the created app.\n\nThis sampler also adds properties that are visible to add threads:\n\n- `ably.app_id`: the id of the created app;\n- `ably.account_id`: the id of the account associatad with the created app;\n- `ably.api_key`: the full API key string for the created root key.\n\nNote that, since these are set as properties instead of User Defined Variables, references to these values by other samplers must be as property references (eg as `${__P(ably.api_key)}`).\n\n### Ably Delete Test App\n\nThis closes a previously created Ably test app. This may be used within a teardown threadgroup of a test plan.\n\n#### Configuration options\n\nNone.\n\n#### Variables\n\nNone.\n\n## Example plans\n\nIllustrative plans are included in the `src/test/resources/plans` directory.\n\n## Release process\n\nThis library uses [semantic versioning](http://semver.org/). For each release, the following needs to be done:\n\n1. Create a branch for the release, named like `release/0.0.2`\n2. Replace all references of the current version number with the new version number (check this file [README.md](./README.md) and [build.gradle](./build.gradle)) and commit the changes\n3. Run [`github_changelog_generator`](https://github.com/skywinder/Github-Changelog-Generator) to update the [CHANGELOG](./CHANGELOG.md).\n4. Commit [CHANGELOG](./CHANGELOG.md)\n5. Make a PR against `main`\n6. Once the PR is approved, merge it into `main`\n7. Add a tag and push to origin - e.g.: `git tag v0.0.2 \u0026\u0026 git push origin v0.0.2`\n\n### Creating the release on Github\n\nVisit [https://github.com/ably/ably-jmeter/tags](https://github.com/ably/ably-java/tags) and `Add release notes` for the release including links to the changelog entry.\n\n## Support, feedback and troubleshooting\n\nPlease visit http://support.ably.io/ for access to our knowledgebase and to ask for any assistance.\n\nYou can also view the [community reported Github issues](https://github.com/ably/ably-jmeter/issues).\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create a new Pull Request\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fably%2Fably-jmeter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fably%2Fably-jmeter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fably%2Fably-jmeter/lists"}