4 Spring Console Extension in WebLogic Server

The Spring console extension is based on RuntimeMBeans registered using the WebLogic Server infrastructure. The console extension displays configuration and runtime information for deployed Spring beans.

Limitation:

To enable the Spring console extension, you must have a Web component as part of your application. This is because most of the applications that use Spring are Web applications.

To use the Spring console extension, you must turn on support for Spring beans and enable the Spring console extension, as explained in steps 1 and 2, below. You only have to do this once. In addition, you must enable your Spring applications to make use of the Spring console extension. This requires making simple changes to your Spring application configuration, as explained in step 3, below. You have to do this for each of your Spring applications.

  1. Deploy WL_HOME/server/lib/weblogic-spring.jar to WebLogic Server, where WL_HOME refers to the main WebLogic Server installation directory, such as Oracle\Middlewar\wlserver_10.3. You only need to perform this step once for your WebLogic Server instance.

    weblogic-spring.jar file is a Java EE optional package used by an application (packaged as an EAR or WAR file). It creates the MBeans for your application during its deployment.

    Deploy weblogic-spring.jar either of the following ways:

    • Use the Administration Console, as described in "Deploy applications and modules" in Oracle WebLogic Server Administration Console Help. The JAR file is located in WL_HOME\server\lib.

    • Issue the following command at the command line:

      java weblogic.Deployer -library -deploy – source
         WL_HOME/server/lib/weblogic-spring.jar – targets
         server_name -adminurl server_URL -user
      user_name -password password
      
  2. Enable the Spring console extension in the Administration Console. (The Spring console extension is disabled by default.) You only need to perform this step once for your domain. Do the following:

    1. Log into the Administration Console.

    2. In the banner toolbar region at the top of the right pane of the Console, click Preferences.

    3. On the Preferences page, click Extensions.

    4. Select the check box next to spring-console, then click Enable.

    5. Stop the server, then restart it for the change to take effect.

  3. Change the manifest of your application (packaged as an EAR or WAR file) so it includes weblogic-spring.jar as a Java EE optional package. Do this to each Spring application you want to make use of the Spring runtime MBeans or the Spring console extension

    Do this by adding the following lines to your META-INF/Manifest.mf:

    Extension-List: WeblogicSpring
    WeblogicSpring-Extension-Name: weblogic-spring
    WeblogicSpring-Specification-Version: 10.3.0.0
    WeblogicSpring-Implementation-Version: 10.3.0.0
    

After you deploy your application, you can monitor it in the Administration Console. The Spring configuration and monitoring pages are under the Spring Framework tab. See "Spring Bean Task Overview" in Oracle WebLogic Server Administration Console Help