Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7046499
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:39:28+00:00 2026-05-28T02:39:28+00:00

From the documentation of oracle : Domain Runtime MBean Server : This MBean server

  • 0

From the documentation of oracle :

Domain Runtime MBean Server : This MBean server also acts as a single
point of access for MBeans that reside on Managed Servers.

what i want to do is to use this fact to access all my custom mBeans scattered in several managed servers.
for example assume that i have two nodes server-1 server-2 .
how can i access all of the custom mBeans on both server-1 server-2 by connecting to the administrator node ?

i dont want to remotly access each node to return the result i want a single entry point
i managed to get the names of the servers and the states and other information by doing this

    JMXConnector connector;
            ObjectName service;
            MBeanServerConnection connection;
            String protocol = "t3"; 
        Integer portInteger = Integer.valueOf(<admin server port>);

      int port = portInteger.intValue();
      String jndiroot = "/jndi/";
      String mserver = "weblogic.management.mbeanservers.runtime"; 

      JMXServiceURL serviceURL = new JMXServiceURL(protocol, "<serverName>", port,
      jndiroot + mserver);  

      Hashtable h = new Hashtable();
      h.put(Context.SECURITY_PRINCIPAL, "weblogic");
      h.put(Context.SECURITY_CREDENTIALS, "weblogicpass");
      h.put(JMXConnectorFactory.PROTOCOL_PROVIDER_PACKAGES,
         "weblogic.management.remote");
      h.put("jmx.remote.x.request.waiting.timeout", new Long(10000));
      connector = JMXConnectorFactory.connect(serviceURL, h);
      connection = connector.getMBeanServerConnection();  service = new ObjectName("com.bea:Name=DomainRuntimeService,Type=weblogic.management.mbeanservers.domainruntime.DomainRuntimeServiceMBean");
      ObjectName[] ons = (ObjectName[]) connection.getAttribute(service, "ServerRuntimes");
       int length = (int) ons.length;

      for (int i = 0; i < length; i++) {
         String name = (String) connection.getAttribute(ons[i],
            "Name");
         String state = (String) connection.getAttribute(ons[i],
            "State");
          String internalPort = (String) connection.getAttribute(ons[i],"ListenPort");
         System.out.println("Server name: " + name + ".   Server state: "
            + state);

but i need to access the custom Mbeans created on each server and not only the information

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T02:39:28+00:00Added an answer on May 28, 2026 at 2:39 am

    maybe my question wasnt clear but i found an answer and i will share it here now :
    Question summary : i need to access custom mBeans exists in a managed server by connecting to the administration server from a client application.

    Answer :
    to do that you need to deploy your application to the administrator server (i tried remote but it didn’t work )

    you need to connect to the DomainRuntimeServiceMBean because it provide a common access point for navigating to all runtime and configuration MBeans in the domain .

    when searching for the Object name add Location=

    here is the code:

        Hashtable props = new Hashtable();
              props.put(Context.INITIAL_CONTEXT_FACTORY,
                        "weblogic.jndi.WLInitialContextFactory");
    
              props.put(Context.SECURITY_PRINCIPAL,   "<userName>");
              props.put(Context.SECURITY_CREDENTIALS, "<password>");
              Context ctx = new InitialContext(props);
      MBeanServer    server = (MBeanServer)ctx.lookup("java:comp/env/jmx/domainRuntime");
    
    
             ObjectName on =new ObjectName("com.<companyName>:Name=<Name>,Type=<Type>,Location=<managed_server_name>");
             boolean boolresult=(Boolean)server.invoke(on, "<method_Name>",
             new Object[]{"<ARG1>","<ARG2>","<ARG3>"}
             ,new String[]{"java.lang.String","java.lang.String","java.lang.String"}); 
             out.print(boolresult);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I'm working on this class that's supposed to request help documentation from a
Oracle's Http Authentication page from the Java SE 6 documentation says that if you
Oracle's documentation on atomic access (at http://docs.oracle.com/javase/tutorial/essential/concurrency/atomic.html ) says this: a volatile variable establishes
I couldn't figure out that from SASS documentation. For example I would like to
Sorry if this is a dead simple question but I'm confused from the documentation
From the MSDN documentation: Synchronized supports multiple writing threads, provided that no threads are
Here's the documentation: http://download-east.oracle.com/docs/cd/B12037_01/server.101/b10759/queries003.htm Here's the execution order it describes: A join, if present,
I have downloaded Java API documentation from http://www.oracle.com/technetwork/java/javase/downloads/index.html#docs and have supposedly attached it to
As you can see in the Oracle Documentation for java.awt.Point , x and y
From the documentation of UITableView / UITableViewController: If you decide to use a UIViewController

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.