diff options
| author | Simon MacMullen <simon@rabbitmq.com> | 2010-08-04 17:58:48 +0100 |
|---|---|---|
| committer | Simon MacMullen <simon@rabbitmq.com> | 2010-08-04 17:58:48 +0100 |
| commit | 3de7fe14067d7af23a52767efead5f6fe82c8451 (patch) | |
| tree | e0ae072f938e90c147f53749ef51ead5168b5135 /src | |
| parent | caff9aeb51595415d98061d24056360d674e0166 (diff) | |
| download | rabbitmq-server-git-3de7fe14067d7af23a52767efead5f6fe82c8451.tar.gz | |
Use now() instead of os:timestamp() for compatibility. now() uses a per-node lock, which is not great, but this is only invoked on lifecycle events, plus every few seconds per queue / channel / connection when the stats level is > none.
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_event.erl | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rabbit_event.erl b/src/rabbit_event.erl index 07027cd5c6..e654b34a6e 100644 --- a/src/rabbit_event.erl +++ b/src/rabbit_event.erl @@ -120,9 +120,10 @@ stats_level(#state{level = Level}) -> notify(Type, Props) -> try + %% TODO: when we no longer support 12B3, switch to os:timestamp() gen_event:notify(rabbit_event, #event{type = Type, props = Props, - timestamp = os:timestamp()}) + timestamp = now()}) catch error:badarg -> %% badarg means rabbit_event is no longer registered. We never %% unregister it so the great likelihood is that we're shutting |
