Commit Graph

14515 Commits

Author SHA1 Message Date
Diana Corbacho 33ce3f8d9c Rename runtime parameter to exchange-delete-in-progress 2016-01-08 18:53:34 +01:00
Daniil Fedotov cc2f0d2951 Ignore duplicate down_from_ch 2016-01-08 17:53:14 +00:00
Michael Klishin 03fd0c2d35 Merge pull request #532 from bogdando/bug/1529897
Remove unneeded sleep for a graceful stop by PID
2016-01-07 12:45:28 -08:00
Bogdan Dobrelya 0f77ae3f47 Remove unneeded sleep for a graceful stop by PID
The sleep in not needed according to the
https://www.rabbitmq.com/man/rabbitmqctl.1.man.html
"If a pid_file is specified, also waits for the process
specified there to terminate."

Related Fuel bug https://launchpad.net/bugs/1529897
Related PR
https://github.com/rabbitmq/rabbitmq-server/pull/523

Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
2016-01-07 13:51:40 +01:00
Diana Corbacho 203ac917ab Set deleting exchange status
* Avoids race condition between declare and delete
2016-01-07 11:03:27 +01:00
Michael Klishin 0c4d9a0d88 Didn't mean to delete this behaviour 2016-01-06 13:32:36 +03:00
Michael Klishin 74f312a88e Docs 2016-01-06 09:45:42 +03:00
Michael Klishin 2db3ca9aeb Docs 2016-01-06 09:41:46 +03:00
Michael Klishin ef7a7f32a6 Essay doco for rabbit_runtime_parameters 2016-01-05 18:39:00 +03:00
Michael Klishin 87ff2128d6 Merge pull request #529 from rabbitmq/rabbitmq-server-521
Adds handling for bindings not of type 'queue'
2016-01-05 17:16:11 +03:00
Ayanda Dube 0d8bef07ed Adds get_queue_master_per_binding/3 handle all clause, to handle
exchange type bindings, for example.

References #521
2016-01-05 10:40:47 +00:00
Michael Klishin 21e4b2d189 Update (c) info 2016-01-01 12:59:15 +03:00
Alexey Lebedeff fe243c2e71 Improve diagnostics in 'rabbitmq-server' script
While errors are detected with '-e' shell option in this script,
diagnostics messages leave a lot to be desired.

E.g. when trying to write pid file to full partition, the only message
in log is:

    sh: echo: I/O error

Which is definitely insufficient
2015-12-31 15:38:06 +03:00
Michael Klishin 4f1483b3d9 Merge pull request #525 from bogdando/bug/1530150
Ensure rabbit node uptime is reset in the CIB for OCF resource
2015-12-31 13:58:00 +03:00
Bogdan Dobrelya 923ca23799 Ensure rabbit node uptime is reset in the CIB for OCF resource
* Add ocf_run wrappers and info log messages for CIB attribute events
* Move "fast" CIB attribute updates before "heavy" operations like
  start/stop/wait to ensure CIB consistent even if the timeouts
  exceeded for the ops
* Delete master and start time attributes from CIB on action_start
  to ensure the correct rabbit nodes uptime evaluation for new
  master elections for corresponding pacemaker resources
* For post-demote notify and action_demote() delete the master
  attribute from CIB as well.
* For post-start notify, update the start time in the CIB even when
  the node is already clustered. Otherwise it would remain running
  in cluster w/o the start time registered, which affects the new
  master elections badly.
* fix wrong log message when joining by a node

Related Fuel bug https://bugs.launchpad.net/fuel/+bug/1530150
https://bugs.launchpad.net/fuel/+bug/1530296

Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
2015-12-31 10:46:44 +01:00
Michael Klishin 852176c5c5 Merge pull request #523 from bogdando/bug/1529897
Fix stop conditions for the rabbit OCF resource
2015-12-30 17:02:15 +03:00
Bogdan Dobrelya b8a554e5b9 Fix stop conditions for the rabbit OCF resource
* Fix the get_status() unexpectedly reports generic error
  instead of "not running"
* Add proc_stop and proc_kill functions
  (TODO these shall go as external common ocf heplers, eventually)
* Rework stop_server_process()
  - make it to return SUCCESS/ERROR as expected
  - grant the "rabbitmqctl stop" a graceful termintation window and only
    then ensure the beam process termination and pidfile removal as well
  - return the actual status with get_status()
* Rework kill_rmq_and_remove_pid()
  - use proc_stop to try to kill by pgrp with -TERM, then -KILL, or
    by the beam process name match, if there is no PID.
  - make it to returns SUCCESS/ERROR
* Fix action_stop()
  - fail early by the stop_server_process() results without additional
    rabbitmqctl invocations in the get_status() call
  - rework hard-coded sleep 10 to use the gracefull stop windows in the
    stop_server_process() instead
  - ensure the rabbit-start-time removal from CIB before to try to stop
    the server process
  - issue the "stop: action end" log record before the actual end
* Add comments and make logs to be more informational

Related Fuel bug https://bugs.launchpad.net/fuel/+bug/1529897

Signed-off-by: Bogdan Dobrelya <bdobrelia@mirantis.com>
Co-authored-by: Alex Schultz <aschultz@mirantis.com>
2015-12-30 14:39:08 +01:00
Michael Klishin 29af23b74d Wording 2015-12-30 09:01:45 +03:00
Daniil Fedotov 3c0229f065 indent with emacs 2015-12-30 09:01:29 +03:00
Daniil Fedotov ab194855e9 Hint to stop_app if mnesia is running but should not 2015-12-30 09:01:23 +03:00
Daniil Fedotov 6f166ebc5a Proper error report 2015-12-30 09:01:18 +03:00
Daniil Fedotov 1ba9534de1 Hint to stop_app when running rabbitmqctl reset 2015-12-30 09:01:11 +03:00
Michael Klishin e0c8ceda91 Merge pull request #516 from rabbitmq/rabbitmq-server-328
Adds exception handling to rabbit_vm:bytes/1
2015-12-30 06:59:20 +03:00
Pierre Fenoll bdc3455559 .gitignore: make absolute paths relative 2015-12-28 17:51:12 +03:00
Ayanda Dube 747552dbd2 Changes rabbit_vm:bytes/1 to return 0 on exception
References #328
2015-12-24 10:53:50 +00:00
Ayanda Dube ef111e2d22 Adds try-catch block and returns error on exception
Fixes #328
2015-12-24 10:09:09 +00:00
Michael Klishin 0e2dccc019 Merge branch 'stable' into rabbitmq-server-485 2015-12-24 00:18:14 +03:00
shawnsli 447e549860 purge may crash in lazy queue(3.6.0) 2015-12-23 15:51:55 +01:00
Michael Klishin 5d617bac40 Sync RPM package description with Debian 2015-12-23 16:44:05 +03:00
Ayanda Dube b2cf1238ee Moves Erlang and OTP functions from rabbit_mnesia
to rabbit_version.

References #485
2015-12-22 16:17:41 +00:00
Jean-Sébastien Pédron 3d478460a3 packaging: Always use xzcat(1) to decompress xz archive
Do not rely on tar's behaviour. It was already done everywhere except in
those three places.
2015-12-22 15:17:25 +01:00
Jean-Sébastien Pédron 203fb23c10 packaging: tar `-n` is not portable, use --no-recursion instead 2015-12-22 15:15:33 +01:00
Michael Klishin d70105e0ec Commit Debian and RPM change log entries 2015-12-22 13:36:22 +00:00
Jean-Sébastien Pédron 515ad3a112 packaging: Deorbit macports package 2015-12-22 14:14:28 +01:00
Jean-Sébastien Pédron b96d5b05e1 packaging/debian: Update list of files removed in `make clean` 2015-12-22 14:13:03 +01:00
Jean-Sébastien Pédron e5d577d281 Fix build: the produced archive is now compressed with xz(1) 2015-12-22 14:04:01 +01:00
Jean-Sébastien Pédron 286563d400 packaging/generic-unix: Produce tar.xz archive
Also, files are sorted in the tar. This is now consistent with other
produced archives.
2015-12-22 08:49:29 +01:00
Michael Klishin 0bd1600253 Merge pull request #509 from rabbitmq/rabbitmq-server-508
Distribute event-exchange, recent-history-exchange and sharding
2015-12-21 19:40:08 +03:00
Jean-Sébastien Pédron 39b5b6458a Distribute event-exchange, recent-history-exchange and sharding
Fixes #508.
2015-12-21 17:22:54 +01:00
Jean-Sébastien Pédron 41dfed3667 packaging/generic-unix: Create web manpages
They are not used by the generic Unix archive, but by `make release` in
the Umbrella: they are needed by the website.
2015-12-21 17:04:30 +01:00
Michael Klishin b984fc2ba7 Merge pull request #507 from rabbitmq/rabbitmq-server-506
Datetime in rabbit_diagnostics
2015-12-21 18:59:53 +03:00
Daniil Fedotov 2e55211eb6 Datetime in rabbit_diagnostics 2015-12-21 14:40:58 +00:00
Jean-Sébastien Pédron ab42bc257b Update erlang.mk 2015-12-18 20:33:28 +01:00
Jean-Sébastien Pédron e0dbf3b3cb Sync with upstream build.config 2015-12-18 20:33:03 +01:00
Jean-Sébastien Pédron f36353b704 Update rabbitmq-components.mk 2015-12-18 19:08:06 +01:00
Michael Klishin 7f1b753669 Update rabbitmq-components.mk 2015-12-18 19:47:09 +03:00
Daniil Fedotov 4c1e9d2a7c Tell travis to wait for long-running tests. 2015-12-18 10:53:11 +00:00
Michael Klishin cc0f7ce7f1 Merge pull request #503 from rabbitmq/rabbitmq-server-368
GM: Ignore 'DOWN' when the ring is going down
2015-12-17 16:34:02 +03:00
Jean-Sébastien Pédron b8145384b2 GM: Ignore 'DOWN' when the ring is going down
This is a follow-up commit to ed276656. This fixes the following crash:

=ERROR REPORT==== 18-Oct-2015::00:51:30 ===
** Generic server <0.966.0> terminating
** Last message in was {'DOWN',#Ref<0.0.3.4250>,process,<21148.716.0>,
                               shutdown}
** When Server state == {state,
                            ...
                            {true,{shutdown,ring_shutdown}}}
** Reason for termination ==
** {function_clause,[{orddict,fetch,
                              [{1,<0.966.0>},[]],
                              [{file,"orddict.erl"},{line,80}]},
                     {gm,check_neighbours,1,[{file,"src/gm.erl"},{line,1243}]},

Submitted by Alvaro Videla (@videlalvaro).
Fixes #368.
2015-12-17 12:11:52 +01:00
Michael Klishin 8fddefcf6e Trigger a new Travis build 2015-12-16 00:59:08 +03:00