[Building Sakai] request for review: KNL-498, get last event time for a user

Nuno Fernandes nuno at ufp.edu.pt
Tue May 18 01:16:19 PDT 2010


+1 patch looks good!

You should check the query on a Sakai db with millions of entries in
SAKAI_EVENT and SAKAI_SESSION (typical on production environments) as it may
have some performance impact !

Great feature!

Thanks,
Nuno

On Tue, May 18, 2010 at 2:30 AM, Steve Swinsburg
<steve.swinsburg at gmail.com>wrote:

> Hi all,
>
> I would like your feedback on two new methods I propose to add to the
> EventTrackingService in order to retrieve the last event time for a user/set
> of users. This is an addition that will be used by the Profile2 connections
> entity provider. Used in conjunction with KNL-497 (see if a user has an
> active session, already committed) you will be able to see if your
> connections are online and if they are active/idle (ie no event in the last
> x minutes = idle).
>
> This entity provider will also be used by the floating chat widget we are
> prototyping.
>
> http://jira.sakaiproject.org/browse/KNL-498
>
> A patch is attached to the JIRA ticket for your perusal, and the methods
> are below:
>
> /**
> * Get last event time for the given user
> *
> * @param userId userId to check
> * @return time of event as Long, null if no event.
> */
> Long getLastEventTimeForUser(String userId);
>
> /**
> * Get last event time for the given list of users
> *
> * @param userIds List of userId's to check
> * @return map of userId and time of last event. If no event, there will be
> no entry in the map for that user.
> */
> Map<String, Long> getLastEventTimeForUsers(List<String> userIds);
>
>
> thanks,
> Steve
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
>



-- 
Nuno Fernandes  .  { Analyst/Programmer }

|| web  . { http://www.ufp.pt  |  http://tinyurl.com/nfgrilo  |  follow_me @
nfgrilo }
|| work . { Universidade Fernando Pessoa  |  Praça 9 de Abril, 349  |
 4249-004 Porto }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20100518/f3e366a7/attachment.html 


More information about the sakai-dev mailing list