From portal-commits at lists.jboss.org Wed Mar 10 22:51:54 2010
Content-Type: multipart/mixed; boundary="===============8183306438128768360=="
MIME-Version: 1.0
From: portal-commits at lists.jboss.org
To: portal-commits at lists.jboss.org
Subject: [portal-commits] JBoss Portal SVN: r13902 -
branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/core/identity.
Date: Wed, 10 Mar 2010 22:51:54 -0500
Message-ID: <201003110351.o2B3psdu009291@svn01.web.mwc.hst.phx2.redhat.com>
--===============8183306438128768360==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Author: ghjboss
Date: 2010-03-10 22:51:54 -0500 (Wed, 10 Mar 2010)
New Revision: 13902
Modified:
branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/c=
ore/identity/UserActivity.java
branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/c=
ore/identity/UsersActivityStatsServiceImpl.java
Log:
fix for JBEPP-159
Modified: branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/p=
ortal/core/identity/UserActivity.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/=
core/identity/UserActivity.java 2010-03-05 16:56:23 UTC (rev 13901)
+++ branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/=
core/identity/UserActivity.java 2010-03-11 03:51:54 UTC (rev 13902)
@@ -24,6 +24,8 @@
=
import javax.management.Notification;
=
+import org.jboss.portal.core.identity.UsersActivityStatsServiceImpl;
+
/**
* @author Boleslaw Dawidowicz
* @author Luca Stancapiano
@@ -70,8 +72,10 @@
{
throw new IllegalArgumentException("Id (notification message) can=
not be null");
}
- this.id =3D notification.getMessage().substring(0, notification.getM=
essage().indexOf("_"));
- this.sessionId =3D notification.getMessage().substring(notification.=
getMessage().indexOf("_"));
+ /************************ JBEPP-159 ********************************=
***************************************************************************=
***************************************************************************=
**/
+ this.id =3D notification.getMessage().substring(0, notification.getM=
essage().indexOf(UsersActivityStatsServiceImpl.USERS_ACTIVITY_STATS_SEPARAT=
OR));
+ this.sessionId =3D notification.getMessage().substring(notification.=
getMessage().indexOf(UsersActivityStatsServiceImpl.USERS_ACTIVITY_STATS_SEP=
ARATOR)+UsersActivityStatsServiceImpl.USERS_ACTIVITY_STATS_SEPARATOR.length=
());
+ /*******************************************************************=
***************************************************************************=
***************************************************************************=
**/
this.timestamp =3D notification.getTimeStamp();
this.type =3D Integer.parseInt(notification.getType());
}
Modified: branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/p=
ortal/core/identity/UsersActivityStatsServiceImpl.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/=
core/identity/UsersActivityStatsServiceImpl.java 2010-03-05 16:56:23 UTC (r=
ev 13901)
+++ branches/Enterprise_Portal_Platform_4_3/core/src/main/org/jboss/portal/=
core/identity/UsersActivityStatsServiceImpl.java 2010-03-11 03:51:54 UTC (r=
ev 13902)
@@ -54,7 +54,9 @@
{
/** Our logger. */
private static final Logger log =3D Logger.getLogger(UsersActivityStats=
ServiceImpl.class);
-
+ /***************************** JBEPP-159 ******************************=
*****/
+ public static final String USERS_ACTIVITY_STATS_SEPARATOR =3D "__SEPARA=
TOR__";
+ /**********************************************************************=
*****/
// TODO: some value just to begin - find some good default
private int userTrackerThreadsNumber =3D 10;
=
@@ -177,10 +179,11 @@
{
try
{
- Notification notification =3D new Notification(Integer.toString(u=
serActivity.getType()), this.getServiceName(),
- userActivity.getTimestamp(), userActivity.getTimestamp(), u=
serActivity.getId() + "_"
- + userActivity.getSessionId());
-
+ /****************** JBEPP-159 *************************************=
**************************************************/
+ Notification notification =3D new Notification(Integer.toString(=
userActivity.getType()), this.getServiceName(),
+ userActivity.getTimestamp(), userActivity.getTimestamp(),=
userActivity.getId() + USERS_ACTIVITY_STATS_SEPARATOR
+ + userActivity.getSessionId());
+ /***************************************************************=
*****************************************************/
if (activityBroadcasterName !=3D null)
{
log.debug("Broadcasting user activity notification ");
--===============8183306438128768360==--