Registering Custom MBeans with Weblogic Server

Registering Custom Mbeans with Weblogic Server. Example.java package jmxMbeans; public class Example implements ExampleMBean { public void sayHello(String str) { System.out.println(“Hello ” + str + “‘!”); } } ExampleMbean.java package jmxMbeans; public interface ExampleMBean { void sayHello(String name); } Index.jsp <%@ page import=”javax.management.MBeanServer”%> <%@ page import=”javax.management.ObjectName”%> <%@ page import=”javax.naming.Context”%> <%@

Continue reading »

Plan.xml usage for Message Driven Bean

This post is an illustration of usage of plan.xml for overriding features of Message Driven Bean application dynamically. Administrators use deployment plans to easily change an application’s WebLogic Server configuration for a specific environment without modifying existing Java EE or WebLogic-specific deployment descriptors. Multiple deployment plans can be used to

Continue reading »

Force Shutingdown WLS Using JMX

import java.io.IOException; import java.net.MalformedURLException; import java.util.Hashtable; import javax.management.MBeanServerConnection; import javax.management.MalformedObjectNameException; import javax.management.ObjectName; import javax.management.remote.JMXConnector; import javax.management.remote.JMXConnectorFactory; import javax.management.remote.JMXServiceURL; import weblogic.management.runtime.*; import javax.naming.Context; import java.lang.*; public class ShutdownServerUsingJMX { private static MBeanServerConnection connection; private static JMXConnector connector; private static final ObjectName service; static { try { service=new ObjectName(“com.bea:Name=DomainRuntimeService,Type=weblogic.management.mbeanservers.domainruntime.DomainRuntimeServiceMBean”); } catch (MalformedObjectNameException

Continue reading »