-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Shanti,
On 9/24/12 12:07 PM, Shanti Suresh wrote: > I would like to query the CurrentThreadsBusy MBean and am running > into issues creating a JSP page for that query. > > The questions I have are: > > (1) when does one use "get" vs "qry". "qry" is a search operation, while "get" queries a specific MBean and has other options (like going into a compound value and pulling-out some data). > For e.g., the following URLs work: CurrentThreadsBusy -> > http://localhost:8090/manager/jmxproxy?qry=Catalina:type=ThreadPool%2Cname=%22http-apr-8453%22 > > CurrentThreadsBusy -> > http://localhost:8090/manager/jmxproxy?qry=Catalina:type=ThreadPool,name=%22http-apr-8453%22 > > HeapUsed -> > http://localhost:8090/manager/jmxproxy/?get=java.lang:type=Memory&att=HeapMemoryUsage&key=used > > But these ones do not: CurrentThreadsBusy (using get) -> > http://localhost:8090/manager/jmxproxy?get=Catalina:type=ThreadPool%2Cname=%22http-apr-8453%22 > > CurrentThreadsBusy (using get) -> > http://localhost:8090/manager/jmxproxy?get=Catalina:type=ThreadPool&name=%22http-apr-8453%22 You > aren't providing the required "att" parameter in any of these queries, so it's not a surprise that you are getting errors. > (2) The following manager/busythreads.jsp does not work: > > ----------busythreads.jsp:--- <jsp:forward page="/jmxproxy/"> > <jsp:param name="qry" value="Catalina:type=ThreadPool" /> > <jsp:param name="name" value="%22http-apr-8453%22" /> > </jsp:forward> ----end of busythreads.jsp---- > > I get: ---- OK - Number of results: 0 ---- Your query is not correct: there is no 'name' parameter. Instead, you need to package everything up in the 'qry' parameter: <jsp:forward page="/jmxproxy/"> <jsp:param name="qry" value="Catalina:type=ThreadPool,\"http-apr-8453\"" /> </jsp:forward> > while this one, heapused.jsp, works fine: > -------heapused.jsp:----- <jsp:forward page="/jmxproxy/"> > <jsp:param name="get" value="java.lang:type=Memory" /> <jsp:param > name="att" value="HeapMemoryUsage" /> <jsp:param name="key" > value="used" /> </jsp:forward> ------end of heapused.jsp------ This works because you provided the proper parameters. - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Mozilla - http://www.enigmail.net/ iEYEARECAAYFAlBgjfoACgkQ9CaO5/Lv0PAz7QCeOaR0bXtA/xW+Oz3lIZKNJ0K/ JXIAnjDd+zusgXc8Bb1jI+fRAkH+H6bn =A2J+ -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org