Commit Graph

164 Commits

Author SHA1 Message Date
Philip Kuryloski 15a79466b1 Use the new xref2 macro from rules_erlang
That adopts the modern erlang.mk xref behaviour
2022-06-09 23:18:28 +02:00
Philip Kuryloski 327f075d57 Make rabbitmq-server work with rules_erlang 3
Also rework elixir dependency handling, so we no longer rely on mix to
fetch the rabbitmq_cli deps

Also:

- Specify ra version with a commit rather than a branch
- Fixup compilation options for erlang 23
- Add missing ra reference in MODULE.bazel
- Add missing flag in oci.yaml
- Reduce bazel rbe jobs to try to save memory
- Use bazel built erlang for erlang git master tests
- Use the same cache for all the workflows but windows
- Avoid using `mix local.hex --force` in elixir rules
  - Fetching seems blocked in CI, and this should reduce hex api usage in
    all builds, which is always nice
- Remove xref and dialyze tags since rules_erlang 3 includes them in
  the defaults
2022-06-08 14:04:53 +02:00
Philip Kuryloski b24ab46a1a Switch the default python binary for codegen scripts to python3 2022-06-02 10:58:42 +02:00
David Ansari 4472ddf71c Increase receiving throughput from a stream via AMQP
This commit increases consumption throughput from a stream via AMQP 0.9.1
for 1 consumer by 83k msg/s or 55%,
for 4 consumers by 140k msg/s or 44%.

This commit tries to follow https://www.erlang.org/doc/efficiency_guide/binaryhandling.html
by reusing match contexts instead of creating new sub-binaries.

The CPU and mmap() memory flame graphs show that
when producing and consuming from a stream via AMQP 0.9.1
module amqp10_binary_parser requires
before this commit: 10.1% CPU time and 8.0% of mmap system calls
after this commit:  2.6% CPU time 2.5% of mmap system calls

Performance tests

Start rabbitmq-server without any plugins enabled and with 4 schedulers:
```
make run-broker PLUGINS="" RABBITMQ_SERVER_ADDITIONAL_ERL_ARGS="+JPperf true +S 4"
```

Test 1

Perf test client:
```
-x 1 -y 2 -qa x-queue-type=stream -ad false -f persistent -u s1 --qos 10000 --multi-ack-every 1000 -z 30
```

master branch:
sending rate avg msg/s 143k - 146k
receiving rate avg msg/s 188k - 194k

PR:
sending rate avg 133k - 138k
receiving rate avg 266k - 276k

This shows that with AMQP 0.9.1 and a stream, prior to this commit the broker could not
deliver messages to consumers as fast as they were published.
After this commit, it can.

Test 2

First, produce a few millions messages:
```
-x 1 -y 0 -qa x-queue-type=stream -ad false -f persistent -u s2
```
Then, consume them:
```
-x 0 -y 1 -qa x-queue-type=stream -ad false -f persistent -u s2 --qos 10000 --multi-ack-every 1000 -ca x-stream-offset=first -z 30
```

receving rate avg msg/s
master branch:
147k - 156k

PR:
230k - 237k

Improvement: 83k / 55%

Test 3

-x 0 -y 4 -qa x-queue-type=stream -ad false -f persistent -u s2 --qos 10000 --multi-ack-every 1000 -ca x-stream-offset=first -z 30

receving rate avg msg/s
master branch:
313k - 319k

PR:
450k - 461k

Improvement: 140k / 44%
2022-05-16 09:07:46 +00:00
Michael Klishin cfb1d44920
Correct GitHub repo links in Hex metadata 2022-04-20 11:14:12 +04:00
Luke Bakken 6433613146
Fix incorrect location of HEX_TARBALL_FILES in deps/amqp10_common 2022-04-19 14:22:25 -07:00
Luke Bakken fb5068a80e
Begin work migrating to native hex publishing
Use hex for credentials_obfuscation dep
2022-04-19 13:21:52 -07:00
Luke Bakken dba25f6462
Replace files with symlinks
This prevents duplicated and out-of-date instructions.
2022-04-15 06:04:29 -07:00
Philip Kuryloski 2dd9bde891 Bring over PROJECT_APP_EXTRA_KEYS values from make to bazel 2022-04-07 17:39:33 +02:00
Luke Bakken d3e15b35ff
Update amqp10_client and amqp10_common for hex.pm publish
Fixes #2577

Related rabbitmq/rabbitmq-ci#50

Yolo-copy amqp_client targets for dist

Update license short name

Remove unnecessary targets now that hex.pm exists
2022-03-29 09:54:30 -07:00
Michael Klishin c38a3d697d
Bump (c) year 2022-03-21 01:21:56 +04:00
Philip Kuryloski efcd881658 Use rules_erlang v2
bazel-erlang has been renamed rules_erlang. v2 is a substantial
refactor that brings Windows support. While this alone isn't enough to
run all rabbitmq-server suites on windows, one can at least now start
the broker (bazel run broker) and run the tests that do not start a
background broker process
2022-01-18 13:43:46 +01:00
Michal Kuratczyk 1a2126676d Update CLA URL 2021-09-23 14:29:36 +02:00
Philip Kuryloski 8f9de08de7 Also assert no missing suites for all other deps 2021-07-12 18:05:55 +02:00
Philip Kuryloski 3899b316da Add dialyze for amqp10_common 2021-05-31 10:08:59 +02:00
Philip Kuryloski 98e71c45d8 Perform xref checks on many tier-1 plugins 2021-05-21 12:03:22 +02:00
Philip Kuryloski 667f5e0a22 Add basic xref for deps/rabbit 2021-05-19 12:43:25 +02:00
Philip Kuryloski 78bb20f0aa Adopt change of suite_name -> name in ct_suite from @bazel-erlang 2021-04-08 14:25:06 +02:00
Michael Klishin 87170e2995
Naming 2021-04-07 11:34:35 +03:00
Michael Klishin a19db0c285
A typo 2021-04-07 11:34:27 +03:00
Michael Klishin 87c9633c39
AMQP 1.0 binary parser: treat arrays with extra or missing input as fatal errors
With some input it is possible that the terminating clause will never
match.

While at it, consume binary input when parsing short form
primitives: null, true, false, as well as uint/ulong zero values.

Pair: @lhoguin.
2021-04-07 10:57:59 +03:00
Philip Kuryloski 388654c542
Add a partial Bazel build (#2938)
Adds WORKSPACE.bazel, BUILD.bazel & *.bzl files for partial build & test with Bazel. Introduces a build-time dependency on https://github.com/rabbitmq/bazel-erlang
2021-03-29 11:01:43 +02:00
Philip Kuryloski a63f169fcb Remove duplicate rabbitmq-components.mk and erlang.mk files
Also adjust the references in rabbitmq-components.mk to account for
post monorepo locations
2021-03-22 15:40:19 +01:00
kjnilsson d6e96c238c fix missing Ra deps updates 2021-03-19 13:54:43 +00:00
Michael Klishin 8b203e316e
Sync rabbitmq-components.mk in a few more places 2021-03-12 19:58:51 +03:00
Michael Klishin a310687478
Sync rabbitmq-components.mk 2021-03-05 02:52:23 +03:00
Michael Klishin a5098b28a7
Bump Lager to 3.8.2 for OTP 24 compatibility 2021-02-24 12:53:30 +03:00
Michael Klishin 52479099ec
Bump (c) year 2021-01-22 09:00:14 +03:00
Arnaud Cogoluègnes 87e440b9f6 Update rabbitmq-components.mk 2020-11-03 14:27:31 +01:00
Michael Klishin d4202b53c4 Update rabbitmq-components.mk 2020-10-21 12:55:27 +03:00
Luke Bakken dc38aa689e Update rabbitmq-components.mk 2020-08-04 08:41:45 -07:00
Jean-Sébastien Pédron da1ec9127e Update rabbitmq-components.mk 2020-07-30 12:06:49 +02:00
Luke Bakken 19373af512 Update rabbitmq-components.mk 2020-07-29 10:02:00 -07:00
dcorbacho 4ccd7cb6e7 Update erlang.mk 2020-07-21 14:31:28 +01:00
Jean-Sébastien Pédron 02eb482aea Update rabbitmq-components.mk 2020-07-21 12:07:55 +02:00
Michael Klishin 4686ed5962 Update rabbitmq-components.mk 2020-07-21 03:42:16 +03:00
dcorbacho 40fc847cc3 Revert drop of Exhibit B on MPL 2.0 2020-07-20 16:50:05 +01:00
Michael Klishin af93c4f00b Update MPL2 license file, drop Exhibit B
and add a VMware copyright notice.

We did not mean to make this code Incompatible with Secondary Licenses
as defined in [1].

1. https://www.mozilla.org/en-US/MPL/2.0/FAQ/
2020-07-17 14:53:09 +03:00
dcorbacho 42c8ea7b6e Switch to Mozilla Public License 2.0 (MPL 2.0) 2020-07-10 15:01:10 +01:00
Jean-Sébastien Pédron ad282a3f2b Update erlang.mk 2020-06-23 17:12:48 +02:00
Michael Klishin 57b6cb3e8c Bump Recon to 2.5.1
for Erlang 23 compatibility of 'rabbitmq-diagnostics observer'

References zhongwencool/observer_cli#68.
2020-06-09 08:22:16 +03:00
Jean-Sébastien Pédron a5a4571f05 Update copyright (year 2020) 2020-03-10 17:04:36 +01:00
Jean-Sébastien Pédron d086fc2102 Update rabbitmq-components.mk 2020-03-06 12:14:49 +01:00
Jean-Sébastien Pédron a7114075ba Makefile: Add rabbit_common to $BUILD_DEPS 2020-03-06 12:12:10 +01:00
Jean-Sébastien Pédron 306278ec76 Travis CI: Update config from rabbitmq-common 2020-03-06 11:59:59 +01:00
Jean-Sébastien Pédron ed1a7753bb Update rabbitmq-components.mk 2020-03-06 11:54:21 +01:00
Jean-Sébastien Pédron c579da8096 Makefile: Include Erlang.mk plugins
Otherwise this project is "half" a RabbitMQ components. In particular,
`rabbitmq-components.mk` is not updated.
2020-03-06 11:54:21 +01:00
Gerhard Lazu 1d3e695fd2 Update erlang.mk 2020-03-06 09:17:01 +00:00
Jean-Sébastien Pédron a32437df17 Update rabbitmq-components.mk 2019-12-12 16:00:49 +01:00
Jean-Sébastien Pédron d54a4afdba Git: Ignore copied CLI 2019-12-12 16:00:13 +01:00
Jean-Sébastien Pédron 21fadc3bf5 Update erlang.mk 2019-08-29 20:44:31 +02:00
Jean-Sébastien Pédron a55b26e372 Makefile: Remove all useless bits
... which were copy-pasted from `rabbit_common` probably.

They were all ineffective because:
* this application was never published to Hex.pm so far
- the `$(BUILD_DEPS)` variable is overwritten in `development.pre.mk`,
  meaning that `rabbit_common` was never used as a dependency.

However in the Umbrella, Erlang.mk plugins were implicitly loaded
because they were available by chance. This went well so far, but broke
in the rabbitmq-server(8) replacement experiment because one of the
plugin started to rely on CLI scripts and escripts when running tests.
This is useless for this application anyway, so getting rid of the
plugin inclusions fix the problem.
2019-08-06 11:16:41 +02:00
Jean-Sébastien Pédron 82d5903a3f Update erlang.mk 2019-08-02 09:53:12 +02:00
Michael Klishin 44c1a15086 Update rabbitmq-components.mk 2019-08-01 17:13:04 +03:00
Arnaud Cogoluègnes 6928d88a84 Update rabbitmq-components.mk 2019-07-09 16:05:45 +02:00
Jean-Sébastien Pédron 05de21f4d9 Update rabbitmq-components.mk 2019-06-28 16:05:22 +02:00
Jean-Sébastien Pédron 9a1751876c Update erlang.mk 2019-06-28 16:01:24 +02:00
Gerhard Lazu c1615112ac Update rabbitmq-components.mk 2019-06-03 02:23:28 +01:00
Jean-Sébastien Pédron 4f9e98f84b Update rabbitmq-components.mk 2019-05-17 15:17:10 +02:00
Michael Klishin 461dd66a48 Update rabbitmq-components.mk 2019-05-17 08:36:12 +03:00
Michael Klishin 30bd21bada Update rabbitmq-components.mk 2019-05-16 23:22:38 +03:00
Michael Klishin f9f261e1d9 Update rabbitmq-components.mk 2019-05-14 11:50:29 +03:00
Michael Klishin 4b3274e83d Update rabbitmq-components.mk 2019-05-13 16:40:20 +03:00
Gerhard Lazu c7939964b7 Update rabbitmq-components.mk 2019-05-01 13:18:04 +01:00
Luke Bakken fd06701c87 Update rabbitmq-components.mk 2019-04-30 16:20:51 -07:00
Jean-Sébastien Pédron 80964d8fb5 Update rabbitmq-components.mk 2019-04-30 14:47:23 +02:00
Gerhard Lazu 6df4cda8c0 Update rabbitmq-components.mk 2019-04-22 21:54:55 +01:00
Michael Klishin 9dc38161e9 Travis: use Erlang 21.3, Elixir 1.8.1 2019-03-20 10:33:10 +03:00
Michael Klishin 78e0610664 Update rabbitmq-components.mk 2019-03-15 05:32:40 +03:00
Michael Klishin d822d31443 Update rabbitmq-components.mk 2019-03-15 05:05:32 +03:00
Michael Klishin f6796ad5f5 Update rabbitmq-components.mk 2019-02-12 23:23:42 +03:00
Michael Klishin fee13882b1 .travis.yml: sync Erlang and Elixir versions, require Erlang/OTP 21.2 2019-01-13 05:50:14 +03:00
Luke Bakken f91272a2e5 Update rabbitmq-components.mk 2019-01-09 12:54:49 -08:00
Luke Bakken 7d30790634 Update rabbitmq-components.mk 2019-01-08 11:58:21 -08:00
Michael Klishin 6084637b76 Update rabbitmq-components.mk 2018-12-06 18:28:34 +03:00
Michael Klishin 625f9779ba Update rabbitmq-components.mk 2018-12-06 03:15:00 +03:00
Jean-Sébastien Pédron 2f3b67d44e Update rabbitmq-components.mk 2018-11-30 14:56:41 +01:00
Jean-Sébastien Pédron 4f9326fa20 Update rabbitmq-components.mk 2018-11-22 09:19:26 +01:00
kjnilsson 233925b37a Update rabbitmq-components.mk 2018-10-29 12:43:10 +00:00
Jean-Sébastien Pédron f7d0a9e52d Update rabbitmq-components.mk 2018-09-19 10:38:08 +02:00
Jean-Sébastien Pédron c59b78efec Update rabbitmq-components.mk 2018-09-11 14:22:20 +02:00
kjnilsson 9bb64ce7d4 Make amqp_sequence roundtrippable
[#159434026]
2018-08-13 15:21:35 +01:00
Jean-Sébastien Pédron 51ec71e569 Update rabbitmq-components.mk 2018-08-09 17:44:06 +02:00
Jean-Sébastien Pédron b96073b5f1 Update rabbitmq-components.mk 2018-08-09 12:16:53 +02:00
Jean-Sébastien Pédron e9807ece13 Update rabbitmq-components.mk 2018-06-07 11:31:28 +02:00
Michael Klishin 3f71ee0ec3 Merge pull request #1 from rabbitmq/qpid-jms-client-support
Qpid jms client support
2018-04-24 01:08:11 +09:00
kjnilsson 7a39cc3b19 tidy up 2018-04-23 12:23:37 +01:00
kjnilsson f810bd5664 User larger symbol type for arrays
Also support decoding variable sizes for utf8 and symbol.

[#156613309]
2018-04-23 11:22:02 +01:00
kjnilsson 75832a81bc Fix array serialization
Ensure types can rountrip and add and extend test coverage.

[#156613309]
2018-04-20 17:38:17 +01:00
Jean-Sébastien Pédron 967d310bcc Update erlang.mk 2018-04-11 10:52:13 +02:00
Jean-Sébastien Pédron 1ae065f308 Update rabbitmq-components.mk 2018-04-11 10:51:13 +02:00
Jean-Sébastien Pédron 06abef6a3a Update rabbitmq-components.mk 2018-04-11 10:09:56 +02:00
Jean-Sébastien Pédron 0f8f35f40d Travis CI: Update config from rabbitmq-common 2018-04-10 12:51:15 +02:00
Jean-Sébastien Pédron ff68c1dffb Update erlang.mk 2018-03-02 19:02:33 +01:00
Jean-Sébastien Pédron 595f516e1b Update rabbitmq-components.mk 2018-01-30 15:23:23 +01:00
Luke Bakken ec144a3d19 Update rabbitmq-components.mk 2018-01-29 16:22:06 -08:00
Jean-Sébastien Pédron 33bafaacfa Update rabbitmq-components.mk 2018-01-23 17:21:15 +01:00
Jean-Sébastien Pédron a91bdde06d Update rabbitmq-components.mk 2018-01-23 15:31:06 +01:00
Jean-Sébastien Pédron 51c1c3c527 Update rabbitmq-components.mk 2018-01-23 12:50:19 +01:00
Diana Corbacho ce2b178a18 Update rabbitmq-components.mk 2018-01-22 22:13:15 +00:00