Sha256: 1a45ab44b23bc566d323e3b66e6f23a90fdc209eb53d83973bd5e341ef0b8570

Contents?: true

Size: 361 Bytes

Versions: 2

Compression:

Stored size: 361 Bytes

Contents

#!/usr/bin/env jruby
require 'jmx4r'

#JMX::MBean.establish_connection :host => "localhost", :port => 3000

logging = JMX::MBean.find_by_name "java.util.logging:type=Logging"
logging.logger_names.each do |logger_name|
    logging.set_logger_level logger_name, "INFO"
end

memory = JMX::MBean.find_by_name "java.lang:type=Memory"
memory.verbose = true
memory.gc

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
jmx4r-0.0.1 examples/jvm_mngmt.rb
jmx4r-0.0.2 examples/jvm_mngmt.rb