Bug 1045311 - org.jboss.remoting-jmx.timeout is not used when connecting the first time
Summary: org.jboss.remoting-jmx.timeout is not used when connecting the first time
Keywords:
Status: CLOSED DUPLICATE of bug 1113242
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: JMX
Version: 6.1.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Darran Lofthouse
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-20 06:46 UTC by Osamu Nagano
Modified: 2018-12-06 15:37 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-07-08 13:31:11 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1113242 0 unspecified CLOSED [GSS] (6.4.0) RemotingConnector & VersionedConectionFactory need configurable connection, channel & versioned connection... 2021-02-22 00:41:40 UTC
Red Hat Issue Tracker REMJMX-77 0 Major Resolved org.jboss.remoting-jmx.timeout is not used when connecting the first time 2017-07-31 06:36:35 UTC

Description Osamu Nagano 2013-12-20 06:46:05 UTC
Description of problem:
Timeout second is fixed at 5 seconds as on line 209 below and not configurable when a client is trying to connect to the server first time. There is a constant "org.jboss.remoting-jmx.timeout" but it is not used here.

https://github.com/jbossas/remoting-jmx/blob/1.1.0.Final/src/main/java/org/jboss/remotingjmx/RemotingConnector.java#L185
~~~
    207         // open a connection
    208         final IoFuture<Connection> futureConnection = endpoint.connect(convert(serviceUrl), getOptionMap(), handler);
    209         IoFuture.Status result = futureConnection.await(5, TimeUnit.SECONDS);
~~~


Version-Release number of selected component (if applicable):
remoting-jmx 1.1.0.Final

Comment 1 Osamu Nagano 2013-12-20 06:51:10 UTC
Sample JMX client can be found in https://access.redhat.com/site/solutions/125473 like this.

~~~
import javax.management.MBeanServerConnection;
import javax.management.remote.JMXConnector;
import javax.management.remote.JMXConnectorFactory;
import javax.management.remote.JMXServiceURL;

public class JMXExample { 
    public static void main(String[] args) throws Exception {
        String host = "remote-host";
        int port = 9999;  // management-native port
        String urlString ="service:jmx:remoting-jmx://" + host + ":" + port;
        System.out.println("\n\n\t****  urlString: "+urlString);;
        JMXServiceURL serviceURL = new JMXServiceURL(urlString);
        JMXConnector jmxConnector = JMXConnectorFactory.connect(serviceURL, null);
        MBeanServerConnection connection = jmxConnector.getMBeanServerConnection();

        //Invoke on the JBoss AS MBean server
        int count = connection.getMBeanCount();
        System.out.println(count);
        jmxConnector.close();
    }
}
~~~

Where "JMXConnectorFactory.connect(serviceURL, null)" passing null, it should be a configuration map like "org.jboss.remoting-jmx.timeout":"1000".

Comment 2 Darran Lofthouse 2014-07-08 13:31:11 UTC

*** This bug has been marked as a duplicate of bug 1113242 ***

Comment 3 JBoss JIRA Server 2015-04-01 16:56:40 UTC
Darran Lofthouse <darran.lofthouse> updated the status of jira REMJMX-77 to Resolved


Note You need to log in before you can comment on or make changes to this bug.