0

I am using windows 7 and i want to enable twiddle on jboss 7.1.1. Which are the steps to do that?

Thanks.

pbal
  • 531
  • 1
  • 7
  • 19

2 Answers2

3

Twiddle was a tool/script included in previous versions of JBoss, up to community version 6, to access to the JMX Services of JBoss (MBeans) through command line. Since JBoss 7 is not based any more on Managed Beans, it doesn't include this tool nor the JMX Console. That said, the management operations exposed through Managed Beans in JBoss 7 can be, of course, accessed with the JConsole tool, included with the JDK.

So don't expect there will be an official twiddle command for JBoss 7, though some independent developers have created their own versions.

Toni
  • 1,381
  • 10
  • 16
  • Thanks for your answer! I have seen this link (own versions) but this version is intended for linux operation system. Is there for windows.? Also, in the following link (http://www.mastertheboss.com/jboss-as-7/jboss-as-7-introduction) is declared that the twiddle has been replaced by Command Line Interface (CLI), which can be found in the JBOSS_HOME/bin folder. Is this correct??And if it is correct how can i use CLI to execute FreeMemory – pbal Dec 03 '12 at 09:35
  • What do you mean with FreeMemory? A metrics commands to retrieve memory usage? On the other hand, the commands line interface is placed in bin\jboss-admin.bat – Toni Dec 03 '12 at 10:05
  • 2
    Yes i want a metrics command to retrieve memory usage. With twiddle i can execute: /twiddle.sh -s localhost:1099 get "jboss.system:type=ServerInfo" FreeMemory. Is there any way to do this with CLI? – pbal Dec 03 '12 at 10:17
0

You have to navigate to the platform-mbean and read the memory-attributes:

/core-service=platform-mbean/type=memory:read-attribute(name=heap-memory-usage) 

You can find the full resource description by using that expression:

/core-service=platform-mbean/type=memory:read-resource-description