[ejabberd] [PATCH] mod_shared_roster: Teach remove_user_from_group() and add_user_to_group() about special users

Martin Langhoff martin.langhoff at gmail.com
Fri Apr 24 14:15:00 MSD 2009


Thanks for the reply! Notes below...

On Fri, Apr 24, 2009 at 11:58 AM, Badlop <badlop at gmail.com> wrote:
> 2009/2/23 Martin Langhoff <martin.langhoff at gmail.com>:
>>  - @nearby@ - I wish I knew that this does
>
> Maybe it groups user sessions by the client IP address range.
>
>
>> The patch I have today - which could drop lots of superfluous things
>> as only @online@ works:
>> http://dev.laptop.org/git?p=users/martin/ejabberd-xs.git;a=blob;f=mod_shared_roster-simplified-online-patch.patch;h=6d707f75fef8be3a6731e81f0960849eade89153;hb=a4afc81e992fd6716c5061a190f6a5b6064281f2
>
> In http://dev.laptop.org/git/users/martin/ejabberd-xs.git/tree/
> I don't see any mod_shared_roster-simplified-online-patch.patch

Sorry about the gitweb->cgit thing. The patch is not on 'master' but
on a branch that's still unmerged, that's why it didn't turn up. See
http://dev.laptop.org/git/users/martin/ejabberd-xs.git/tree/mod_shared_roster-simplified-online-patch.patch?h=update-2.0.3

> The @recent@ patch was reported here:
> https://support.process-one.net/browse/EJAB-456
> I chatted with Mickael today and commented some ideas.

Thanks for the link -- I wasn't aware of that discussion.

> Conceptually, the directives @all@, @recent@ and @online@
> can be generalized as: @recent?days=X@
> where X is an integer from 0 up to 9999.
> In that case:
>    * @all@ = @recent?days=9999@
>    * @recent@ = @recent?days=7@
>    * @online@ = @recent?days=0@

Hmmm. It seems to me that there are some differences (Will @recent@
hide entries for users that are not online?) and that it makes sense
to implement them differently for performance reasons.

I can also agree w the idea of capping the number of entries

> The requirements that your patch should meet to be applied to ejabberd
> trunk SVN:

> >From what you said, it seems your patch is quite close to this. The
> remaining Tasks are only related to R1:
> T1. Remove support for @nearby@
> T2. Test/improve support for @recent@
> T3. Add support for @recent?days=X@

Ok. I'll see if I can work on @nearby@ and @recent@ -- might take abit
of time ;-)

In the meantime... in case anyone's interested, the patch linked above
supports @online@ nicely on 2.0.3 -

cheers,



martin
-- 
 martin.langhoff at gmail.com
 martin at laptop.org -- School Server Architect
 - ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 - http://wiki.laptop.org/go/User:Martinlanghoff


More information about the ejabberd mailing list