Uploaded image for project: 'ActiveMQ Classic'
  1. ActiveMQ Classic
  2. AMQ-4957

LDAP Network Connector does not allow port number in uri

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Abandoned
    • 5.9.0
    • None
    • Connector
    • None
    • Centos 6.4, OpenLDAP 2.4

    Description

      When using the LDAP discovery agent, if a non-failover URI containing a port number is specified in the ldapNetworkConnector for example:

      <networkConnectors>
      <ldapNetworkConnector uri="ldap://172.31.67.192:389"
      base="dc=tmts,dc=net"
      anonymousAuthentication="true"
      searchFilter="(!(cn=esb1))"
      searchScope="SUBTREE_SCOPE"
      dynamicOnly="true"
      networkTTL="2"
      prefetchSize="1"
      conduitSubscriptions="true"
      decreaseNetworkConsumerPriority="false"
      />
      </networkConnectors>

      The following Java exception is seen in the log on startup and the broker never initialises:

      2013-12-26 13:40:40,919 | INFO | Refreshing org.apache.activemq.xbean.XBeanBrokerFactory$1@2919c2af: startup date [Thu Dec 26 13:40:40 UTC 2013]; root of context hierarchy | org.apache.activemq.xbean.XBeanBrokerFactory$1 | main
      2013-12-26 13:40:44,231 | ERROR | Failed to load: class path resource [activemq.xml], reason: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in class path resource [activemq.xml]: Cannot create inner bean 'ldapNetworkConnector#4e2cb9f0' of type [org.apache.activemq.network.LdapNetworkConnector] while setting bean property 'networkConnectors' with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ldapNetworkConnector#4e2cb9f0' defined in class path resource [activemq.xml]: Error setting property values; nested exception is org.springframework.beans.PropertyBatchUpdateException; nested PropertyAccessExceptions (1) are:
      PropertyAccessException 1: org.springframework.beans.MethodInvocationException: Property 'uri' threw exception; nested exception is java.net.URISyntaxException: Illegal character in scheme name at index 0: 172.31.67.192:389 | org.apache.activemq.xbean.XBeanBrokerFactory | main

      If the URI is changed to remove the port number the broker works fine. If the URI containing a port number is used in a failover transport specification, the broker also works fine.

      Attachments

        Activity

          People

            Unassigned Unassigned
            mpwestern Matthew Western
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: