This together with last history message is used by room_unused_* command
to determine for how long room was not used, this change allow us to skip
checking history, and works even when history is disabled.
This required adding hibernation time to data stored for room to be able
determine how old was a room, rooms that aren't stored with that
information will use node start time as timestamp for that.
This caused garbled text in some places in webadmin when using language
that used characters > 128.
Thanks to chengshq for noticing this and providing preliminary patch.
How to reproduce the problems fixed by this commit:
Create temporary room, other account subscribes, and owner leaves
Unsubscribe that account with the command: ejabberdctl unsubscribe_room ...
By calling erlang:get_stacktrace() inside a lager function
we obtain actually a stacktrace of the lager function, not
the one we got during exception. This is not a problem for
newest Erlang versions though.
Now every such string MUST be encapsulated into ?T() macro.
The macro itself is defined in include/translate.hrl.
Example:
-module(foo).
-export([bar/1]).
-include("translate.hrl").
bar(Lang) ->
translate:translate(Lang, ?T("baz")).
The value of monotonic_time/1 may differ significantly between
nodes in a cluster due to different erlang:time_offset/0 values.
Thanks to Christoph Scholz for spotting this
Previously sometimes we tried to post message to all online rooms, and
if that was called from muc room pid, we were not able to process that
message for that room and send response, and this did lead to timeout.
This will store info about non-persistant rooms in db, but rooms with that
that option enabled will not be restored on server restart.
This will save info about room only on subscribers change.
This option disable storing separate mucsub message for each individual
subscriber but instead when user fetches archive virtual mucsub messages
are generated from muc archives.