Commit Graph

1223 Commits

Author SHA1 Message Date
Jean-Sébastien Pédron 2e8cdd5ba6 exchange_SUITE: Throw an exception if wait_for_federation() times out
While here, increase two timers in the `binding_recovery` testcase.
Hopefully this will help in Concourse.
2020-03-26 17:32:42 +01:00
Jean-Sébastien Pédron c278947717 Update copyright (year 2020) 2020-03-10 16:10:02 +01:00
Gerhard Lazu d2a72bba64 Update rabbitmq-components.mk 2020-03-06 09:19:15 +00:00
Gerhard Lazu bfe5c1108c Update erlang.mk 2020-03-06 09:17:40 +00:00
Jean-Sébastien Pédron 0858bdff4a Travis CI: Update config from rabbitmq-common 2020-03-04 14:24:28 +01:00
Jean-Sébastien Pédron 3ef26b5b30 Travis CI: Update config from rabbitmq-common 2020-03-04 11:17:15 +01:00
Michael Klishin 1c7bf496c7 Transitionary step for OTP 23 [master] compatibility 2020-02-11 21:16:24 +03:00
Michael Klishin a07c6f49ad Transitionary step for OTP 23 [master] compatibility 2020-02-11 21:11:26 +03:00
Gerhard Lazu 346c7435da Update rabbitmq-components.mk 2020-02-11 15:31:44 +00:00
Michael Klishin 8b5bd10c43 (c) bump 2019-12-29 05:50:28 +03:00
Michael Klishin 407f095955 Error handling around command channel 2019-12-22 08:31:31 +03:00
Michael Klishin c0e73759e9 Merge branch 'cmd-channel' of https://github.com/velimir/rabbitmq-federation into velimir-cmd-channel 2019-12-22 04:23:30 +03:00
Luke Bakken aba6f430ab Merge branch 'lrb-delete-federation-exchange' 2019-12-12 11:58:03 -08:00
Michael Klishin d196789164 Merge pull request #99 from rabbitmq/delete-federation-exchange
Use vhost to delete federated exchange
2019-12-12 20:17:16 +03:00
Jean-Sébastien Pédron 5e566144ce Git: Ignore copied CLI 2019-12-12 13:30:17 +01:00
Jean-Sébastien Pédron ce7c0a5ac6 Update rabbitmq-components.mk 2019-12-12 13:14:54 +01:00
Luke Bakken d9183e1372 Filter by vhost for federated queues 2019-12-11 17:05:20 -08:00
Luke Bakken 1f123eed05 add test that fails for queue 2019-12-11 16:18:42 -08:00
Michael Klishin 1629d2ae1e Clarify the intent 2019-12-10 23:23:06 +03:00
dcorbacho db2ab26930 Use vhost to delete federated exchange
Avoids deleting several links with the same upstream, but on different vhosts
[#169936237]
2019-12-10 17:08:58 +01:00
Grigory Starinkin 7eacec1497 use separate channel for command operations
using `bind-nowait` and separate channel for bindings operations allows
to avoid message forwarding delays on the federation link
2019-11-07 07:21:07 +00:00
kjnilsson e59df101df Update rabbitmq-components.mk 2019-09-13 10:24:20 +01:00
kjnilsson 7326faf205 Update rabbitmq-components.mk 2019-09-04 10:30:57 +01:00
Jean-Sébastien Pédron 0af17a2333 Update erlang.mk 2019-08-29 20:45:08 +02:00
Diana Corbacho 69af5dfb02 Obfuscate credentials for federated queues and exchanges.
Credentials are also obfuscated in the ETS table of rabbit_federation_status
so they are not shown in plain text in a crash dump

[#167070941]
2019-08-16 13:35:00 +01:00
Arnaud Cogoluègnes c1b5812cee Start obfuscating credentials for federated queue
WIP

[#167070941]

References rabbitmq/rabbitmq-erlang-client#123
2019-08-14 16:53:04 +02:00
Michael Klishin fab7c2c969 Update rabbitmq-components.mk 2019-08-11 01:47:54 +10:00
Jean-Sébastien Pédron d68e8cb578 Update erlang.mk 2019-08-02 09:53:55 +02:00
Michael Klishin 20a0ea61e7 Update rabbitmq-components.mk 2019-08-01 17:13:15 +03:00
Arnaud Cogoluègnes 355217ba97 Update rabbitmq-components.mk 2019-07-09 16:05:56 +02:00
Jean-Sébastien Pédron 692c91d3c5 Update rabbitmq-components.mk 2019-06-28 16:05:30 +02:00
Jean-Sébastien Pédron 1d854fdcd8 Update erlang.mk 2019-06-28 16:02:02 +02:00
Gerhard Lazu 6839d73a96 Update rabbitmq-components.mk 2019-06-03 02:23:36 +01:00
Jean-Sébastien Pédron 2f6b51046a Update rabbitmq-components.mk 2019-05-17 15:17:18 +02:00
Michael Klishin 6ffd956072 Update rabbitmq-components.mk 2019-05-17 08:36:38 +03:00
Michael Klishin ad13fb97de Update rabbitmq-components.mk 2019-05-16 23:22:49 +03:00
Michael Klishin b39000b716 Update rabbitmq-components.mk 2019-05-14 11:50:47 +03:00
Michael Klishin 36912b6418 Update rabbitmq-components.mk 2019-05-13 16:40:31 +03:00
Gerhard Lazu 0c62a98142 Update rabbitmq-components.mk 2019-05-01 13:18:13 +01:00
Luke Bakken 5aca057fec Update rabbitmq-components.mk 2019-04-30 16:20:56 -07:00
Jean-Sébastien Pédron 99400a53da Update rabbitmq-components.mk 2019-04-30 14:47:29 +02:00
Daniil Fedotov 04adb8fa6a Custom consumer tag for federaion.
Consumer tag is currently generated from the upstream name.
Consumer tag serves to identify a downsream from the upstream queue,
while upsream name identifies upstream from the downstream node.
It would be more convenient to use different values.

Addresses #66
2019-04-26 16:07:59 -04:00
Daniil Fedotov a90b709548 Chenge federation consumer name from "consumer" to "federation-link-<upstream_name>".
This would make it easier to distinguish federation links from other
consumers and from each other (if configured with different names)

Adresses #66 in a way
2019-04-26 13:02:19 -04:00
Gerhard Lazu cb94ce1506 Update rabbitmq-components.mk 2019-04-22 21:55:04 +01:00
Michael Klishin 5e3affdcec CLI commands: provide more information to the new help command 2019-03-26 19:50:16 +03:00
Michael Klishin ce6e4b79af Error message wording 2019-03-22 15:07:22 +03:00
Michael Klishin 05c89aae39 Minor test improvements 2019-03-22 14:59:52 +03:00
Luke Bakken dd10964e48 Change regex to pattern 2019-03-21 12:03:35 -07:00
Diego Herrera Celedón 1ab3c5071c Implement some tests 2019-03-20 19:11:07 -03:00
Diego Herrera Celedón 4522305d98 Implement federation-upstream-regex upstream parameter 2019-03-20 19:11:07 -03:00
Spring Operator ef766e32f0 URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# HTTP URLs that Could Not Be Fixed
These URLs were unable to be fixed. Please review them to see if they can be manually resolved.

* http://blog.listincomprehension.com/search/label/procket (200) with 1 occurrences could not be migrated:
   ([https](https://blog.listincomprehension.com/search/label/procket) result ClosedChannelException).
* http://dozzie.jarowit.net/trac/wiki/TOML (200) with 1 occurrences could not be migrated:
   ([https](https://dozzie.jarowit.net/trac/wiki/TOML) result SSLHandshakeException).
* http://dozzie.jarowit.net/trac/wiki/subproc (200) with 1 occurrences could not be migrated:
   ([https](https://dozzie.jarowit.net/trac/wiki/subproc) result SSLHandshakeException).
* http://e2project.org (200) with 1 occurrences could not be migrated:
   ([https](https://e2project.org) result AnnotatedConnectException).
* http://erlang.2086793.n4.nabble.com/initializing-library-applications-without-processes-td2094473.html (200) with 1 occurrences could not be migrated:
   ([https](https://erlang.2086793.n4.nabble.com/initializing-library-applications-without-processes-td2094473.html) result SSLHandshakeException).
* http://nitrogenproject.com/ (200) with 2 occurrences could not be migrated:
   ([https](https://nitrogenproject.com/) result ConnectTimeoutException).
* http://proper.softlab.ntua.gr (200) with 1 occurrences could not be migrated:
   ([https](https://proper.softlab.ntua.gr) result SSLHandshakeException).
* http://yaws.hyber.org (200) with 1 occurrences could not be migrated:
   ([https](https://yaws.hyber.org) result AnnotatedConnectException).
* http://choven.ca (503) with 1 occurrences could not be migrated:
   ([https](https://choven.ca) result ConnectTimeoutException).

# Fixed URLs

## Fixed But Review Recommended
These URLs were fixed, but the https status was not OK. However, the https status was the same as the http request or http redirected to an https URL, so they were migrated. Your review is recommended.

* http://fixprotocol.org/ (301) with 1 occurrences migrated to:
  https://fixtrading.org ([https](https://fixprotocol.org/) result SSLHandshakeException).
* http://erldb.org (UnknownHostException) with 1 occurrences migrated to:
  https://erldb.org ([https](https://erldb.org) result UnknownHostException).

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* http://cloudi.org/ with 27 occurrences migrated to:
  https://cloudi.org/ ([https](https://cloudi.org/) result 200).
* http://erlware.org/ with 1 occurrences migrated to:
  https://erlware.org/ ([https](https://erlware.org/) result 200).
* http://inaka.github.io/cowboy-trails/ with 1 occurrences migrated to:
  https://inaka.github.io/cowboy-trails/ ([https](https://inaka.github.io/cowboy-trails/) result 200).
* http://ninenines.eu with 6 occurrences migrated to:
  https://ninenines.eu ([https](https://ninenines.eu) result 200).
* http://www.actordb.com/ with 2 occurrences migrated to:
  https://www.actordb.com/ ([https](https://www.actordb.com/) result 200).
* http://www.cs.kent.ac.uk/projects/wrangler/Home.html with 1 occurrences migrated to:
  https://www.cs.kent.ac.uk/projects/wrangler/Home.html ([https](https://www.cs.kent.ac.uk/projects/wrangler/Home.html) result 200).
* http://www.rabbitmq.com/federation.html with 1 occurrences migrated to:
  https://www.rabbitmq.com/federation.html ([https](https://www.rabbitmq.com/federation.html) result 200).
* http://www.rebar3.org with 1 occurrences migrated to:
  https://www.rebar3.org ([https](https://www.rebar3.org) result 200).
* http://contributor-covenant.org with 1 occurrences migrated to:
  https://contributor-covenant.org ([https](https://contributor-covenant.org) result 301).
* http://contributor-covenant.org/version/1/3/0/ with 1 occurrences migrated to:
  https://contributor-covenant.org/version/1/3/0/ ([https](https://contributor-covenant.org/version/1/3/0/) result 301).
* http://inaka.github.com/apns4erl with 1 occurrences migrated to:
  https://inaka.github.com/apns4erl ([https](https://inaka.github.com/apns4erl) result 301).
* http://inaka.github.com/edis/ with 1 occurrences migrated to:
  https://inaka.github.com/edis/ ([https](https://inaka.github.com/edis/) result 301).
* http://lasp-lang.org/ with 1 occurrences migrated to:
  https://lasp-lang.org/ ([https](https://lasp-lang.org/) result 301).
* http://saleyn.github.com/erlexec with 1 occurrences migrated to:
  https://saleyn.github.com/erlexec ([https](https://saleyn.github.com/erlexec) result 301).
* http://www.mozilla.org/MPL/ with 27 occurrences migrated to:
  https://www.mozilla.org/MPL/ ([https](https://www.mozilla.org/MPL/) result 301).
* http://zhongwencool.github.io/observer_cli with 1 occurrences migrated to:
  https://zhongwencool.github.io/observer_cli ([https](https://zhongwencool.github.io/observer_cli) result 301).
2019-03-20 08:16:24 -05:00
Michael Klishin 56dc9cb59e Travis: use Erlang 21.3, Elixir 1.8.1 2019-03-20 10:33:14 +03:00
Michael Klishin bb39dc0fa1 Help section improvements for CLI commands
To go with rabbitmq/rabbitmq-cli#332.

(cherry picked from commit 6fba7b7d92e35515da3747f5f53e06803af2a4fd)

Conflicts:
	src/Elixir.RabbitMQ.CLI.Ctl.Commands.FederationStatusCommand.erl
	src/Elixir.RabbitMQ.CLI.Ctl.Commands.RestartFederationLinkCommand.erl
2019-03-19 18:22:12 +03:00
Michael Klishin 99b1b97b5d Add a spec for rabbit_federation_util:fail/2 2019-03-15 22:24:14 +03:00
Michael Klishin 1fa5c9e7ff One less Dialyzer warning 2019-03-15 22:24:04 +03:00
Luke Bakken 010532b449 Correctly handle already_started case
Follow-up to #85 and #86
2019-03-15 10:33:07 -07:00
Michael Klishin 3b3f9be386 Update rabbitmq-components.mk 2019-03-15 05:32:54 +03:00
Michael Klishin c09397b251 Update rabbitmq-components.mk 2019-03-15 05:05:44 +03:00
Michael Klishin 1e511044a0 Make link sup sup startup idempotent
By handling `{error, already_started}` which can be seen in the wild
due to distributed race conditions.

Per discussion with @lukebakken.
2019-03-06 23:14:42 +03:00
Michael Klishin 3bdc83d6be Drive by change: format this message as one line 2019-03-06 22:34:27 +03:00
Michael Klishin eb3b0183ca Wording 2019-02-21 20:13:42 +03:00
Daniil Fedotov 1545cd67c1 Description for help command.
Requires https://github.com/rabbitmq/rabbitmq-cli/pull/316
2019-02-20 14:23:27 -05:00
Michael Klishin 5f91a3377c Update rabbitmq-components.mk 2019-02-12 23:23:53 +03:00
Jean-Sébastien Pédron 269dcb6699 unit_inbroker_SUITE: Create `#amqqueue{}` on the broker
... and use it locally in the `get_connection_name()` testcase. With
this, we don't need to query the feature flag file and initialize the
registry locally.

This works because the feature flags are only checked when the
`#amqqueue{}` record is created. When we use it afterwards, the
`amqqueue` module doesn't care: the argument determines the version of
the record to use.
2019-02-08 16:44:18 +01:00
Daniil Fedotov c1c3660c98 Update unit_inbroker suite to support amqqeueue module. 2019-02-07 17:41:37 -05:00
Jean-Sébastien Pédron b7221e4fef Make #amqqueue{} a private record
See the corresponding commit in rabbitmq-server for all the
explanations.

Now, all accesses to the #amqqueue{} record are made through the
`amqqueue` module (available in rabbitmq-server). The new type name is
`amqqueue:amqqueue()`.

The `amqqueue.hrl` header also provides some macros to help with pattern
matching and guard expressions.

[#159298729]
2019-01-23 14:18:48 +01:00
Michael Klishin fe090d41c5 .travis.yml: use 21.2 as 21.2.2 builds are no available 2019-01-14 01:20:20 +03:00
Michael Klishin 93dd31d031 .travis.yml: sync Erlang and Elixir versions, require Erlang/OTP 21.2 2019-01-13 05:49:59 +03:00
Luke Bakken 29e73ba8fc Update rabbitmq-components.mk 2019-01-09 12:55:03 -08:00
Luke Bakken 040d475e59 Update rabbitmq-components.mk 2019-01-08 11:58:27 -08:00
Jean-Sébastien Pédron 1b74ff9ff6 Travis CI: Update config from rabbitmq-common 2019-01-08 15:44:23 +01:00
Michael Klishin 5f765689ae Update rabbitmq-components.mk 2018-12-06 18:28:46 +03:00
Michael Klishin 3e965c94dc Update rabbitmq-components.mk 2018-12-06 03:15:12 +03:00
Jean-Sébastien Pédron 58979bb5e2 Update rabbitmq-components.mk 2018-11-30 14:56:49 +01:00
Jean-Sébastien Pédron 17251fad30 Update rabbitmq-components.mk 2018-11-22 09:19:34 +01:00
kjnilsson e86e9cad8e Update rabbitmq-components.mk 2018-10-29 12:43:19 +00:00
Jean-Sébastien Pédron 06b917c1a2 Update rabbitmq-components.mk 2018-09-19 10:38:15 +02:00
Jean-Sébastien Pédron c28efc9326 Update rabbitmq-components.mk 2018-09-11 14:22:29 +02:00
Luke Bakken 4330755d17 Update git-commit-msgs link 2018-08-28 16:18:46 -07:00
Jean-Sébastien Pédron 2122142e74 Update rabbitmq-components.mk 2018-08-09 17:44:14 +02:00
Jean-Sébastien Pédron 1c8281618e Update rabbitmq-components.mk 2018-08-09 12:17:00 +02:00
Ayanda Dube 91953d93e6 avoid multiple creation of upstream queue name
when defining upstream exchange name. Use that
already held in the link state.
2018-07-20 19:15:11 +01:00
Ayanda Dube 0c6fec525f acquire upstream & downstream connection names once
per exchange or queue link initialization
2018-07-13 11:41:30 +01:00
Ayanda Dube 1b86aed04a make federation util name/1 helper for resource
translation more explicit (it translates both
exchange and queue resources, from both links)
2018-07-13 11:38:57 +01:00
Ayanda Dube 6aca39fc56 fix exchange link child-spec release handling module 2018-07-12 11:39:46 +01:00
Michael Klishin ce582ec250 Wording 2018-06-25 20:53:47 +03:00
Ricardo Goncalves 665271f8b1 When trying to open a channel, don't expect that the connection is up and running.
Protect against connection being down or closing.

This happened when upstream federation links were forcibly closed, crashing the downstream federated exchange process when calling the following 2 lines on terminate/2:
```
    %% Cleanup of internal queue and exchange
    delete_upstream_queue(Conn, Queue),
    delete_upstream_exchange(Conn, IntExchange),
```
2018-06-25 13:38:35 +01:00
Ricardo Goncalves 5b9311b846 Fixes the "zombie" direct connections, when using Federated Exchanges and forcibly closing the upstream connections. This happens deterministically 100% of the time.
The fact that direct connections do not close, causes a process and memory leak on RabbitMQ.

If the exchange_link process first closes the direct connection, before dealing with the remote TCP connection, the issue completely disappears.
2018-06-25 10:50:32 +01:00
Jean-Sébastien Pédron db15d39738 Update rabbitmq-components.mk 2018-06-07 11:31:35 +02:00
Michael Klishin 50a6a64ea1 Coerce upstream set element to a proplist
Closes #75, references #67, #70, #73.
2018-04-30 13:41:32 -05:00
Jean-Sébastien Pédron cec3c373ec Update erlang.mk 2018-04-11 10:53:12 +02:00
Jean-Sébastien Pédron 4a9e826492 Update rabbitmq-components.mk 2018-04-11 10:51:20 +02:00
Jean-Sébastien Pédron 6d442974e7 Update rabbitmq-components.mk 2018-04-11 10:10:03 +02:00
Michael Klishin a4cac21e5a Be more defensive when operating on proplists
They can be passed from the outside as maps.

References #67, #70.
Closes #73.
2018-04-09 15:00:25 +02:00
Jean-Sébastien Pédron c225e7cc81 Travis CI: Update config from rabbitmq-common 2018-04-09 14:30:46 +02:00
Jean-Sébastien Pédron fca2c44812 Travis CI: Update config from rabbitmq-common 2018-04-09 11:59:12 +02:00
Michael Klishin 5e2145b090 Merge branch 'v3.7.x'
Conflicts:
	.travis.yml
2018-03-08 04:14:49 +03:00
Michael Klishin 46f257b0ae Swap these tests
Troubleshooting a Concourse failure.
2018-03-07 04:54:15 +03:00
Jean-Sébastien Pédron c1c1b5ea29 Update erlang.mk 2018-03-02 19:05:49 +01:00
Jean-Sébastien Pédron f1cc1de7b2 Update erlang.mk 2018-03-02 18:38:02 +01:00
Michael Klishin c4835ae646 Coerce upstream definition to a proplist
So that maps do not fail validation.

References #68.
Closes #70.

(cherry picked from commit 8b0c5dbbd99df79045e766033f47dd74a98707a2)
2018-02-06 17:57:06 +01:00
Michael Klishin 4e42529af4 Coerce upstream definition to a proplist
So that maps do not fail validation.

References #68.
Closes #70.
2018-02-06 17:54:49 +01:00
Michael Klishin 3ea21a6e65 Coerce upstream set definition to proplists
So that it passes validation.

Closes #67.

[#154751618]
2018-01-31 15:50:52 +03:00
Michael Klishin dcc78781b7 Coerce upstream set definition to proplists
So that it passes validation.

Closes #67.

[#154751618]
2018-01-31 15:49:42 +03:00
Jean-Sébastien Pédron a9d99070c9 Update rabbitmq-components.mk 2018-01-30 16:37:27 +01:00
Jean-Sébastien Pédron b0666f47bc Update rabbitmq-components.mk 2018-01-30 15:23:38 +01:00
Luke Bakken 2d9c673dfc Update rabbitmq-components.mk 2018-01-29 16:22:13 -08:00
Jean-Sébastien Pédron 39146af95a Update rabbitmq-components.mk 2018-01-23 18:02:50 +01:00
Jean-Sébastien Pédron 79b37e2646 Update rabbitmq-components.mk 2018-01-23 17:21:28 +01:00
Jean-Sébastien Pédron 8a72acd8c6 Update rabbitmq-components.mk 2018-01-23 15:31:17 +01:00
Diana Corbacho 35fe9908eb Update rabbitmq-components.mk 2018-01-22 22:13:22 +00:00
Jean-Sébastien Pédron c865289bbd Travis CI: Update config from rabbitmq-common 2017-12-15 15:12:14 +01:00
Jean-Sébastien Pédron a5d37f30d2 Travis CI: Update config from rabbitmq-common 2017-12-15 14:53:05 +01:00
Jean-Sébastien Pédron 5f14a780a2 Update rabbitmq-components.mk 2017-12-01 15:16:27 +01:00
Jean-Sébastien Pédron bf7b2efc16 Update rabbitmq-components.mk 2017-12-01 11:06:29 +01:00
Jean-Sébastien Pédron 65432bfcd0 Merge branch 'rabbitmq-federation-63' into v3.7.x 2017-11-29 12:35:07 +01:00
Jean-Sébastien Pédron 5348c433fb Merge pull request #64 from rabbitmq/rabbitmq-federation-63
Cleanup internal exchanges and queues when links are removed
2017-11-29 12:33:21 +01:00
Diana Corbacho 44d2f3895c Use assert macros. Wait for link to be recreated
rabbitmq-federation#63
[#153011041]
2017-11-29 10:33:38 +00:00
Jean-Sébastien Pédron 8145fea83a Update rabbitmq-components.mk 2017-11-28 14:00:49 +01:00
Jean-Sébastien Pédron 9c1261338f Update rabbitmq-components.mk 2017-11-28 13:28:51 +01:00
Diana Corbacho a8953cd6ce Cleanup internal exchanges and queues after plugin is disabled or policy removed
rabbitmq-federation#63
[#153011041]
2017-11-27 11:24:14 +00:00
Jean-Sébastien Pédron f6949e37e8 Travis CI: Update config from rabbitmq-common 2017-11-07 18:54:45 +01:00
Luke Bakken f8e2121fc0 Add GitHub templates and contributing doc 2017-10-13 15:55:50 -07:00
Jean-Sébastien Pédron 21cc1449a8 Merge branch 'stable' 2017-10-13 15:08:05 +02:00
Jean-Sébastien Pédron 0673533894 Update rabbitmq-components.mk 2017-10-13 14:33:08 +02:00
Jean-Sébastien Pédron b8e75fd6b3 Update rabbitmq-components.mk 2017-10-13 14:13:07 +02:00
Jean-Sébastien Pédron ee366396b1 Update rabbitmq-components.mk 2017-10-13 12:15:43 +02:00
Michael Klishin 67531af421 Update rabbitmq-components.mk 2017-09-13 17:54:19 -04:00
Michael Klishin acabc37eb3 Update rabbitmq-components.mk 2017-09-13 17:45:30 -04:00
Michael Klishin bba2eafb11 Update rabbitmq-components.mk 2017-09-12 19:53:10 -04:00
Michael Klishin 66dcb2c834 Update rabbitmq-components.mk 2017-09-12 12:41:51 -04:00
Daniil Fedotov 247f58317f Merge branch 'stable' 2017-08-30 19:20:34 +01:00
Daniil Fedotov 5a9ec72c9f Update erlang.mk 2017-08-30 18:46:44 +01:00
Daniil Fedotov c90d9cf13f Use lager sink API for logs.
Lager sink parse-transform allows us to use a fake module name
to select sinks.
The parse-transform will fail if a sink is not defined, making sure
log is working.

[#149634975]
2017-08-07 14:47:19 +01:00
Jean-Sébastien Pédron f80c8e2db6 Merge branch 'stable' 2017-07-31 10:12:08 +02:00
Jean-Sébastien Pédron 3e3ebdf081 exchange_SUITE: Cleanup policies at the end of `restart_upstream` testcase
Without this cleanup, the `cycle_detection` testcase which follows fails
with the following error:

    ** Reason for termination ==
    ** {function_clause,
           [{rabbit_federation_exchange_link,
                '-ensure_internal_exchange/2-fun-0-',
                [406,
                 <<"PRECONDITION_FAILED - inequivalent arg 'x-max-hops' for exchange 'federation: cycle -> rmq-ct-with_disambiguate-cluster_size_2-1-21000@localhost B' in vhost '/': received '1' but current is '10'">>],
                [{file,"src/rabbit_federation_exchange_link.erl"},{line,540}]},
            {rabbit_federation_link_util,disposable_connection_call,3,
                [{file,"src/rabbit_federation_link_util.erl"},{line,305}]},
            {rabbit_federation_exchange_link,ensure_upstream_bindings,2,
                [{file,"src/rabbit_federation_exchange_link.erl"},{line,489}]},
            {rabbit_federation_exchange_link,'-go/1-fun-1-',8,
                [{file,"src/rabbit_federation_exchange_link.erl"},{line,423}]},
            {rabbit_federation_link_util,start_conn_ch,5,
                [{file,"src/rabbit_federation_link_util.erl"},{line,58}]},
            {gen_server2,handle_msg,2,[{file,"src/gen_server2.erl"},{line,1048}]},
            {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,240}]}]}

[#149584741]
2017-07-27 17:50:45 +02:00
Michael Klishin 88287acbf5 Erlang/OTP 19.2 is now the minimum supported version.
Part of rabbitmq/rabbitmq-server#1305.

[#149563549]
2017-07-26 19:02:50 +03:00
Jean-Sébastien Pédron 96230a39a7 exchange_SUITE: Use a dedicated key in `cycle_detection`
The testcase is affected by other testcases not cleaning what they
created or not waiting for those resources to disappear.

By using a dedicated binding key (instead of the same `key` as all other
testcases), it seems to improve the success rate of the testcase.
2017-07-26 15:26:41 +02:00
Jean-Sébastien Pédron d4c33e11dc exchange_SUITE: No need to import rabbit_federation_test_util:no_plugins() 2017-07-26 15:25:57 +02:00
Michael Klishin 42e916d8e4 Update rabbitmq-components.mk 2017-07-26 03:48:24 +03:00
Michael Klishin 1a94d68983 Update rabbitmq-components.mk 2017-07-26 02:27:05 +03:00
Michael Klishin c1d9733e12 Merge branch 'stable' 2017-07-24 18:07:54 +03:00
Diana Corbacho 0bd9a9f5c0 Detect internal upstream exchange deletion and restart the link
When network partitions happen, two nodes might connect to the upstream
swapping the exchange (A -> B, B -> A). The last surviving link
after healing might have lost its exchange. The periodic check using
a passive declare allows to detect the situation and restart the link,
restoring the connectivity.

Related to rabbitmq-federation#43
rabbitmq-federation#59
2017-07-21 17:37:21 +01:00
Michael Klishin d29bef40c8 Merge pull request #58 from rabbitmq/rabbitmq-server-1246-master
Change algorithm for federation link ID generation from term_to_binary to phash2.
2017-06-13 18:36:07 +03:00
Daniil Fedotov a57c5187e9 Change algorithm for federation link ID generation from term_to_binary to phash2.
term_to_binary can change in defferent OTP versions.
2017-06-13 15:37:47 +01:00
Michael Klishin f3a8a697cd Update rabbitmq-components.mk 2017-06-12 20:14:32 +03:00
Michael Klishin 54887f3b79 Update rabbitmq-components.mk 2017-06-12 18:35:39 +03:00
Daniil Fedotov 7d98bb20da Less compile warnings 2017-06-12 14:18:00 +01:00
Michael Klishin 2d7d48489d Merge branch 'stable' 2017-06-02 18:10:20 +03:00
Michael Klishin 7fbc5d5f5c Update rabbitmq-components.mk 2017-06-02 17:51:27 +03:00
Daniil Fedotov ba8eedd382 New CLI helpers API. Better federation_status banner message 2017-06-02 10:14:40 +01:00
Michael Klishin 7cb5622b86 Update rabbitmq-components.mk 2017-06-02 00:43:22 +03:00
Michael Klishin 5786263c23 Update rabbitmq-components.mk 2017-06-01 18:01:36 +03:00
Jean-Sébastien Pédron 3a86ae1ccf Merge branch 'stable' 2017-05-16 18:08:17 +02:00
Jean-Sébastien Pédron dcaefec03e Makefile: Load the new `rabbitmq-early-plugin.mk` early-stage plugin
See the corresponding commit in rabbitmq-common for an explanation.

[#144697185]
2017-05-16 17:32:56 +02:00
Jean-Sébastien Pédron a833d5ba16 Update erlang.mk 2017-05-16 17:32:56 +02:00
Daniil Fedotov 9c152516b5 Replace dicts to maps for internal structures 2017-04-24 14:13:00 +01:00
Jean-Sébastien Pédron 124a18c571 Merge branch 'stable' 2017-04-19 12:45:24 +02:00
Jean-Sébastien Pédron a177aeef2b Update erlang.mk 2017-04-19 12:02:06 +02:00
Michael Klishin 898cf32100 Merge branch 'stable' 2017-04-02 21:57:33 +03:00
Michael Klishin ab6ccc5f1f (c) year 2017-04-02 21:47:58 +03:00
Michael Klishin 2b7d5d6519 Merge branch 'stable' 2017-03-29 13:02:58 +03:00
Michael Klishin 8935d0ad48 Handle more numerical types for the "hops" property
Semantically a {short, N} value is the same as {long, N}
or even {signedint, N}.

Fixes #56.
2017-03-29 12:40:06 +03:00
Jean-Sébastien Pedron 699a7ce01e Change cluster_size_2 test ordering to fix failing test
Signed-off-by: Gerhard Lazu <gerhard@rabbitmq.com>
2017-03-13 12:13:21 +00:00
Michael Klishin 01deec9830 Update rabbitmq-components.mk 2017-02-11 23:29:26 +03:00
Michael Klishin 04a1d4f1f7 Update rabbitmq-components.mk 2017-02-10 11:16:28 +03:00
Michael Klishin 24f56e71f7 Update rabbitmq-components.mk 2017-02-10 03:06:21 +03:00
Michael Klishin 7fbadf25af merge branch 'stable' 2017-02-08 16:54:32 +03:00
Michael Klishin 80d2a3fdbf Update rabbitmq-components.mk 2017-02-08 16:38:14 +03:00
Michael Klishin 3972f75efa merge branch 'stable' 2017-02-06 19:50:39 +03:00
Michael Klishin 70a6156cfb Update rabbitmq-components.mk 2017-02-06 19:23:53 +03:00
Jean-Sébastien Pédron 7055fb50e2 Update rabbitmq-components.mk 2017-02-02 17:17:01 +01:00
Michael Klishin e03a0ec91f merge branch 'stable' 2017-01-31 18:18:41 +03:00
Michael Klishin 60ef104db7 Update rabbitmq-components.mk 2017-01-31 18:06:27 +03:00
Diana Corbacho 69ee21591d Improve logging when the upstream exchange changes while adding bindings 2017-01-23 22:35:01 +03:00
Diana Corbacho 03dae269ab Improve logging when the upstream exchange changes while adding bindings 2017-01-23 14:52:51 +00:00
Michael Klishin 72774bc805 Merge pull request #51 from rabbitmq/rabbitmq-event-exchange-10
Extend notify and notify_clear to support usernames
2017-01-21 02:06:16 +03:00
Michael Klishin b168031629 Merge branch 'stable' 2017-01-18 12:00:08 +03:00
Diana Corbacho c63e4ef322 Log when a link stops on init 2017-01-18 07:59:03 +00:00
Diana Corbacho eb3f004280 Extend notify and notify_clear to support usernames 2017-01-13 15:48:45 +01:00
Michael Klishin b5db85e3e0 federation_link_restart => restart_federation_link
while at it, provide a more user friendly error message
2017-01-04 02:27:15 +08:00
Diana Corbacho b1b07fbfaa CLI command to restart a link 2017-01-03 15:26:11 +01:00
Diana Corbacho 9139e8e43f Merge branch 'stable' 2017-01-03 15:11:37 +01:00
Michael Klishin 0469d84899 Merge pull request #49 from rabbitmq/rabbitmq-federation-management-17
Link restart
2016-12-31 01:34:44 +08:00
Diana Corbacho c8252f2c53 Internal rename of only-down to only_down to satisfy parser 2016-12-30 16:07:33 +01:00
Diana Corbacho 62b7eba56b Use the hex value of the key's sha to avoid encoding/decoding in URLs 2016-12-30 09:54:05 +01:00
Michael Klishin 6330503015 Merge branch 'stable' 2016-12-30 14:38:51 +08:00
Michael Klishin 78423240fd Use the same max restart intensity across link supervision tree
A follow-up to 9d18974a35.
We really should use the same values everywhere.

References #43.
2016-12-30 14:36:50 +08:00
Diana Corbacho 600b29df43 Add tests for federation status/lookup 2016-12-29 10:06:56 +01:00
Diana Corbacho 951f00f1d0 Introduce callbacks that allow to restart a link, listing returns an id 2016-12-28 16:28:33 +01:00
Diana Corbacho 46e5cddeaf Rename option 2016-12-28 13:23:33 +01:00
Diana Corbacho 4e97240c29 Cosmetic changes 2016-12-28 13:12:25 +01:00
Diana Corbacho 221de38065 CLI command option to list down links 2016-12-28 11:32:12 +01:00
Diana Corbacho b3d0efb4fb Introduce id 2016-12-27 19:48:04 +01:00
Diana Corbacho 6567dcae04 Merge remote-tracking branch 'origin/stable' 2016-12-23 12:20:01 +01:00
Michael Klishin 9d18974a35 Increase tolerated restart intensity of rabbit_federation_sup children
The intensity depends on the number of links and configured
reconnect-delay. This number is not particularly scientific but
supports 100 links failing a minute with default settings, which
should be sufficient for most environments.

Increasing reconnect-delay would allow for an even higher
failure rate.

Per discussion with @dcorbacho.
2016-12-23 12:28:51 +03:00
Jean-Sébastien Pédron 3ea6688dcc Travis CI: Import changes from rabbitmq-auth-backend-amqp 2016-12-12 13:37:52 +01:00
Jean-Sébastien Pédron 1a9a68632a Merge branch 'stable' 2016-12-09 19:20:34 +01:00
Jean-Sébastien Pédron d62d3e0cb8 Update rabbitmq-components.mk 2016-12-08 19:14:46 +01:00
Jean-Sébastien Pédron 1b35ae4978 Travis CI: Use Ubuntu Trusty image to have access to Elixir
Also, required `sudo` so a VM is used instead of a container. This makes
the test much longer, but allows us to install non-whitelisted packages
such as xsltproc.
2016-12-08 17:20:25 +01:00
Jean-Sébastien Pédron 2e44351f16 Merge branch 'stable' 2016-12-07 15:37:31 +01:00
Jean-Sébastien Pédron d18c5f46e8 Move from .app.src to Makefile variables
This is the recommended way with Erlang.mk.

By default, the version is inherited from rabbitmq-server-release when
the source archive is created, or computed from git-describe(1) (see
`rabbitmq-components.mk`). One can override the version from the command
line by setting the `PROJECT_VERSION` variable.

[#130992027]
2016-12-06 16:01:45 +01:00
Michael Klishin c04c0cc853 Merge branch 'stable' 2016-11-29 21:15:43 +03:00
Michael Klishin f5b2cc8650 Update rabbitmq-components.mk 2016-11-29 20:59:30 +03:00
Jean-Sébastien Pédron 63fdecda9a Merge branch 'stable' 2016-11-25 10:59:17 +01:00
Jean-Sébastien Pédron 8eb402e15e Update rabbitmq-components.mk 2016-11-25 10:50:56 +01:00
Jean-Sébastien Pédron 883f5d83f1 Merge branch 'stable' 2016-11-25 10:33:01 +01:00
Jean-Sébastien Pédron eb0c81ea2b Update rabbitmq-components.mk 2016-11-25 10:08:17 +01:00
Jean-Sébastien Pédron ae9ddb585f Merge branch 'stable' 2016-11-24 10:18:20 +01:00
Jean-Sébastien Pédron 870b1f8a31 Add rabbitmq_ct_client_helpers to TEST_DEPS 2016-11-24 10:18:16 +01:00
Jean-Sébastien Pédron acb59e473b Update rabbitmq-components.mk 2016-11-23 18:06:01 +01:00
Gerhard Lazu 7f461a8983 Merge branch 'stable' 2016-11-22 16:49:05 +00:00
Gerhard Lazu 169ba90c84 Update erlang.mk 2016-11-22 16:19:02 +00:00
Gerhard Lazu ca49672f5e Update rabbitmq-components.mk 2016-11-22 16:16:32 +00:00
Michael Klishin 3d5d080c1e Revert "Remove flags, switches and aliases from CLI command"
This reverts commit 7e90ee2690.

I am about to revert some recent CLI changes, so this is again
required.
2016-11-22 14:06:50 +03:00
Diana Corbacho 7e90ee2690 Remove flags, switches and aliases from CLI command 2016-11-21 16:14:29 +00:00
Diana Corbacho 12ad37f1f3 Include empty fields for csv and table formatters 2016-11-21 11:21:34 +00:00
Diana Corbacho 6fb03876c1 Tests for CLI extension for federation status 2016-11-21 10:06:04 +00:00
Diana Corbacho 9b70d870b8 Test refactor 2016-11-21 10:06:04 +00:00
Diana Corbacho 9a1f4395ac CLI extension for federation status 2016-11-18 22:40:53 +00:00
Jean-Sébastien Pédron 4280eb27ed Update erlang.mk 2016-11-14 11:55:28 +01:00
Jean-Sébastien Pédron 10d79ca6d4 Update rabbitmq-components.mk 2016-11-10 16:56:34 +01:00
Michael Klishin 1465ba9064 Merge branch 'stable' 2016-10-19 17:26:57 +08:00
Michael Klishin 548f65eb6e Merge branch 'stable' into rabbitmq-federation-39 2016-10-19 17:12:48 +08:00
Arnaud Cogoluègnes 174b6134b4 Improve Federation link connection name
Fixes #39
2016-10-19 09:38:47 +02:00
Daniil Fedotov f88b7a647d Merge branch 'stable' 2016-10-14 14:46:01 +01:00
Daniil Fedotov a4c514f39a Test cleanup 2016-10-14 14:44:53 +01:00
Arnaud Cogoluègnes b180f575a1 Make Federation connections (links) specify a name
Fixes #39
2016-10-13 18:01:36 +02:00
Michael Klishin 4593851913 Merge branch 'stable' 2016-09-30 00:16:32 +03:00
Jean-Sébastien Pédron 865f75c419 rabbit_federation_*_link: Use the standard `pg2` module
References rabbitmq/rabbitmq-server#980.
[#131354699]
2016-09-29 17:01:36 +02:00
Jean-Sébastien Pédron c19d9bebad Merge branch 'stable' 2016-09-23 16:02:48 +02:00
Jean-Sébastien Pédron 8c61162f94 Update rabbitmq-components.mk 2016-09-23 11:23:04 +02:00
Jean-Sébastien Pédron 3bcec93221 Update erlang.mk 2016-09-22 17:56:26 +02:00
Jean-Sébastien Pédron 7062340927 rabbitmq_federation.app: Depend on rabbit_common 2016-09-19 13:55:45 +02:00
Jean-Sébastien Pédron 71dff3a5c4 Makefile: Explicitely list all DEPS
Sync rabbitmq-components.mk with rabbitmq-common to remove automatic
DEPS handling.

[#130086871]
2016-09-19 13:55:33 +02:00
Jean-Sébastien Pédron 54d4c2eb78 Update erlang.mk 2016-09-19 13:54:00 +02:00
Jean-Sébastien Pédron b39c358477 Merge branch 'stable' 2016-09-15 16:39:44 +02:00
Jean-Sébastien Pédron 1b912c73e9 Update rabbitmq-components.mk 2016-09-15 15:46:16 +02:00
Jean-Sébastien Pédron f00c267586 Merge branch 'stable' 2016-09-02 16:02:50 +02:00
Jean-Sébastien Pédron 0c803b61ce Update rabbitmq-components.mk 2016-09-02 13:22:25 +02:00
Jean-Sébastien Pédron 22a7a0ec3c Makefile: No need to filter out rabbitmq_test from TEST_DEPS anymore
[#127356157]
2016-09-02 12:26:41 +02:00
Jean-Sébastien Pédron 5b71ffba59 Update rabbitmq-components.mk 2016-09-02 12:03:30 +02:00
Michael Klishin 0b536b7050 Update rabbitmq-components.mk 2016-07-14 15:44:10 +03:00
Michael Klishin 7c9bfe682b Update rabbitmq-components.mk 2016-07-14 15:37:30 +03:00
Michael Klishin 97520bd5fe Update rabbitmq-components.mk 2016-07-14 13:39:13 +03:00
Michael Klishin da568d1da2 Update rabbitmq-components.mk 2016-07-14 13:19:59 +03:00
Jean-Sébastien Pédron b041cba2ad Merge branch 'stable' 2016-07-07 10:18:59 +02:00
Jean-Sébastien Pédron 68d97fa638 Travis CI: Test against Erlang 18.3 and 19.0 2016-07-06 14:54:16 +02:00
Jean-Sébastien Pédron dc14525cf4 exchange_SUITE: Increase timetrap to 5 minutes
Hopefully this should fix timeouts on CI.
2016-07-06 14:53:00 +02:00
Jean-Sébastien Pédron c129dbdfd6 Use `rand` directly in master because we require Erlang 18.3
References rabbitmq/rabbitmq-server#860.
[#122335241]
2016-06-29 16:36:19 +02:00