You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jcs-users@jakarta.apache.org by Chopin hu <hu...@yahoo.com> on 2012/01/13 04:31:22 UTC

Re: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region

My final goal is to get a list of keys in a specified region.    then using that key to get the details of a cache entry.


--- On Thu, 1/12/12, Chopin hu <hu...@yahoo.com> wrote:

From: Chopin hu <hu...@yahoo.com>
Subject: JCSAdminBean buildElementInfo problem
To: jcs-users@jakarta.apache.org
Date: Thursday, January 12, 2012, 8:27 PM

 
I tried to get back some details of a cache entry by the following snippet of code:

JCSAdminBean admin = new JCSAdminBean();
List elements = admin.buildElementInfo(myRegion);
System.out.println("There are a total of " + elements.size() + " items in the region");

I have over 100 cache items in the region "myRegion".    But the elements.size() always returns 0.    WHY?   how can I resolve this?

By the way, I can successfully get back some region info by calling:
         List list = admin.buildCacheInfo(); 
and returns msg as below:

INFO: Cache Region - myRegion1
Cache Name: aerostat
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
Cache Name: myRegion2
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
INFO: There are 2 regions found

Any one has any clue on 2 questions:
1.) why does admin.buildElementInfo(myRegion1) not return any element info.
2.) why does the region info has 0s, even though I have tried to hit the cache many times?

Thanks so much for any insight on it.


RE: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region

Posted by Chopin hu <hu...@yahoo.com>.
Thanks a lot, Tim.   Yeah.  Thomas told me that.  So, I have posted it to users@commons list yesterday.

I'll take a look into that jsp,and see whether that can help in some way.

--- On Fri, 1/13/12, Tim Cronin <Ti...@autonomy.com> wrote:

From: Tim Cronin <Ti...@autonomy.com>
Subject: RE: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region
To: "JCS Users List" <jc...@jakarta.apache.org>
Date: Friday, January 13, 2012, 10:37 AM

You can take a look at the jcs admin jsp it might help

http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/jcs/admin/JCSAdmin.jsp

Also this thread is dormant unfortunately.

It's been consolidated to one uber list for all of commons I think.

-----Original Message-----
From: Chopin hu [mailto:huchopin@yahoo.com] 
Sent: Thursday, January 12, 2012 9:31 PM
To: JCS Users List
Subject: Re: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region

My final goal is to get a list of keys in a specified region.    then using that key to get the details of a cache entry.


--- On Thu, 1/12/12, Chopin hu <hu...@yahoo.com> wrote:

From: Chopin hu <hu...@yahoo.com>
Subject: JCSAdminBean buildElementInfo problem
To: jcs-users@jakarta.apache.org
Date: Thursday, January 12, 2012, 8:27 PM

 
I tried to get back some details of a cache entry by the following snippet of code:

JCSAdminBean admin = new JCSAdminBean();
List elements = admin.buildElementInfo(myRegion);
System.out.println("There are a total of " + elements.size() + " items in the region");

I have over 100 cache items in the region "myRegion".    But the elements.size() always returns 0.    WHY?   how can I resolve this?

By the way, I can successfully get back some region info by calling:
         List list = admin.buildCacheInfo(); 
and returns msg as below:

INFO: Cache Region - myRegion1
Cache Name: aerostat
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
Cache Name: myRegion2
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
INFO: There are 2 regions found

Any one has any clue on 2 questions:
1.) why does admin.buildElementInfo(myRegion1) not return any element info.
2.) why does the region info has 0s, even though I have tried to hit the cache many times?

Thanks so much for any insight on it.


---------------------------------------------------------------------
To unsubscribe, e-mail: jcs-users-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jcs-users-help@jakarta.apache.org


RE: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region

Posted by Tim Cronin <Ti...@autonomy.com>.
You can take a look at the jcs admin jsp it might help

http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/jcs/admin/JCSAdmin.jsp

Also this thread is dormant unfortunately.

It's been consolidated to one uber list for all of commons I think.

-----Original Message-----
From: Chopin hu [mailto:huchopin@yahoo.com] 
Sent: Thursday, January 12, 2012 9:31 PM
To: JCS Users List
Subject: Re: JCSAdminBean buildElementInfo problem -- how to get a list of keys in a region

My final goal is to get a list of keys in a specified region.    then using that key to get the details of a cache entry.


--- On Thu, 1/12/12, Chopin hu <hu...@yahoo.com> wrote:

From: Chopin hu <hu...@yahoo.com>
Subject: JCSAdminBean buildElementInfo problem
To: jcs-users@jakarta.apache.org
Date: Thursday, January 12, 2012, 8:27 PM

 
I tried to get back some details of a cache entry by the following snippet of code:

JCSAdminBean admin = new JCSAdminBean();
List elements = admin.buildElementInfo(myRegion);
System.out.println("There are a total of " + elements.size() + " items in the region");

I have over 100 cache items in the region "myRegion".    But the elements.size() always returns 0.    WHY?   how can I resolve this?

By the way, I can successfully get back some region info by calling:
         List list = admin.buildCacheInfo(); 
and returns msg as below:

INFO: Cache Region - myRegion1
Cache Name: aerostat
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
Cache Name: myRegion2
Cache Type: 1
Cache Size: 0
Cache Misses (not found): 0
Cache Misses (expired): 0
Cache Hits (memory): 0
Cache Updates: 0
INFO: There are 2 regions found

Any one has any clue on 2 questions:
1.) why does admin.buildElementInfo(myRegion1) not return any element info.
2.) why does the region info has 0s, even though I have tried to hit the cache many times?

Thanks so much for any insight on it.


---------------------------------------------------------------------
To unsubscribe, e-mail: jcs-users-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jcs-users-help@jakarta.apache.org