On Wed, Mar 10, 2010 at 16:44, Marius Dumitru Florea
<mariusdumitru.florea(a)xwiki.com> wrote:
Hi Thomas,
Thomas Mortagne wrote:
Hi dev,
I'm working on
http://jira.xwiki.org/jira/browse/XWIKI-4606 and i
would like to propose the following:
1) add a property than takes a list of users/groups
I only found xwiki.stats.excludedUsers for now,
xwiki.stats.excludedUsersAndGroups is a bit long an groups are meta
users so it's ok, right ? ;)
For each element of the list we get the document to know if it's a
user of a group and recursively get groups users to produce a list of
all users to filter. That means that StatUtils#getFilteredUsers would
return a list of users without any group that would have been
internally "resolved".
I plan to add this resolve tool in
com.xpn.xwiki.plugin.rightsmanager.RightsManager for now, we can see
latter if we want to add this in public apis (RightsManager*PluginApi
classes).
For now i plan to have:
* xwiki.stats.excludedUsers in xwiki.cfg (follow "xwiki.stats" propery naming)
* statistics_excludedUsers in
XWikiPreferencesmyxwiki.org (follow
"statistics" property naming)
2) in all statistics search/get methods we filter theses users
automatically by inserting them in the hql where clauses (all theses
methods are mostly about creating the proper database query to get the
result)
This doesn't work, because document statistics are aggregated for all
users while being recorded. As a consequence, when you query how many
times a document has been viewed you can't filter by user.
This works only with visit statistics (e.g. most active users).