3 Replies Latest reply on Jan 22, 2016 6:07 PM by arnab_ghosh

    RemoteConnectionFactory look up using Standalone client

    arnab_ghosh

      Hi All,

       

      I am trying to look up the remote connection factory, deployed in Wildfly 8.2.0.Final, which I am trying to look up using standalone client. My code looks like below:

       

      Properties properties = new Properties();
      properties.put(Context.INITIAL_CONTEXT_FACTORY, "org.jboss.naming.remote.client.InitialContextFactory");
      properties.put(Context.PROVIDER_URL, "http-remoting://myqueueserver:18080");
      properties.put("jboss.naming.client.connect.timeout", "15000");
      Context context = new InitialContext(properties);
      QueueConnectionFactory qcFactory = (QueueConnectionFactory) context.lookup("jms/RemoteConnectionFactory");
      
      

       

      I am getting the below Exception:

       

      javax.naming.AuthenticationException: Failed to connect to any server. Servers tried: [http-remoting://myqueueserver:18080 (Authentication failed: the server presented no aut

      hentication mechanisms)] [Root exception is javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms]

              at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:238)

              at org.jboss.naming.remote.client.HaRemoteNamingStore.namingStore(HaRemoteNamingStore.java:149)

              at org.jboss.naming.remote.client.HaRemoteNamingStore.namingOperation(HaRemoteNamingStore.java:130)

              at org.jboss.naming.remote.client.HaRemoteNamingStore.lookup(HaRemoteNamingStore.java:272)

              at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:87)

              at org.jboss.naming.remote.client.RemoteContext.lookup(RemoteContext.java:129)

              at javax.naming.InitialContext.lookup(InitialContext.java:411)

              at com.sonymusic.aoma.service.AOMAServiceOocConnectionHandler.queueOutOfContainer(AOMAServiceOocConnectionHandler.java:129)

              at com.sonymusic.aoma.service.AOMAServiceOocConnectionHandler.queueOutOfContainer(AOMAServiceOocConnectionHandler.java:64)

              at com.sonymusic.aoma.asset.registration.AssetRegistrationJobMessenger.enqueueJob(AssetRegistrationJobMessenger.java:125)

              at com.sonymusic.aoma.asset.registration.RegistrationUtil.commitRegistrationJob(RegistrationUtil.java:93)

              at com.sonymusic.aoma.asset.migration.AssetMigrator.commitRegistrationJob(AssetMigrator.java:169)

              at com.sonymusic.aoma.asset.migration.AssetMigrator.execute(AssetMigrator.java:113)

              at com.sonymusic.aoma.asset.migration.MigrationDaemon.submitMigrationTasks(MigrationDaemon.java:845)

              at com.sonymusic.aoma.asset.migration.MigrationDaemon.runOnce(MigrationDaemon.java:799)

              at com.sonymusic.aoma.asset.migration.MigrationDaemon.run(MigrationDaemon.java:775)

              at java.lang.Thread.run(Thread.java:744)

      Caused by: javax.security.sasl.SaslException: Authentication failed: the server presented no authentication mechanisms

              at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:388)

              at org.jboss.remoting3.remote.ClientConnectionOpenListener$Capabilities.handleEvent(ClientConnectionOpenListener.java:242)

              at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

              at org.xnio.channels.TranslatingSuspendableChannel.handleReadable(TranslatingSuspendableChannel.java:199)

              at org.xnio.channels.TranslatingSuspendableChannel$1.handleEvent(TranslatingSuspendableChannel.java:113)

              at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

              at org.xnio.ChannelListeners$DelegatingChannelListener.handleEvent(ChannelListeners.java:1092)

              at org.xnio.ChannelListeners.invokeChannelListener(ChannelListeners.java:92)

              at org.xnio.conduits.ReadReadyHandler$ChannelListenerHandler.readReady(ReadReadyHandler.java:66)

              at org.xnio.nio.NioSocketConduit.handleReady(NioSocketConduit.java:88)

              at org.xnio.nio.WorkerThread.run(WorkerThread.java:539)

              at ...asynchronous invocation...(Unknown Source)

              at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:272)

              at org.jboss.remoting3.EndpointImpl.doConnect(EndpointImpl.java:253)

              at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:351)

              at org.jboss.remoting3.EndpointImpl.connect(EndpointImpl.java:335)

              at org.jboss.naming.remote.client.EndpointCache$EndpointWrapper.connect(EndpointCache.java:111)

              at org.jboss.naming.remote.client.HaRemoteNamingStore.failOverSequence(HaRemoteNamingStore.java:197)

              ... 16 more

       

      Please note I have disabled security on the hotnetQ server configuration:

       

      <hornetq-server>
      <persistence-enabled>true</persistence-enabled>
      <journal-file-size>10485760</journal-file-size>
      <journal-min-files>10</journal-min-files>
      <clustered>false</clustered>
      <security-enabled>false</security-enabled
      
      

       

      Please let me know what I am missing ?

       

      Regards

      Arnab