8 Replies Latest reply on Feb 7, 2012 11:34 AM by Prasad Deshpande

    Invalid option 'org.xnio.Options.SSL_ENABLED'

    Sanjeev Singh Newbie

      Hi,

       

      I am getting following error ( With  JBoss Modules version 1.1.0.CR8) while invoking the create() method of EJB Home interface. 

       

      15:27:30,295 DEBUG [org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration] (Timer-2) endpoint.create.options. has the following options {}

      15:27:30,295 WARN  [org.xnio.option.parse] (Timer-2) Invalid option 'org.xnio.Options.SSL_ENABLED' in property 'remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED': java.lang.IllegalArgumentException: Class 'org.xnio.Options' not found

      15:27:30,296 DEBUG [org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration] (Timer-2) remote.connectionprovider.create.options. has the following options {}

      15:27:30,296 WARN  [org.xnio.option.parse] (Timer-2) Invalid option 'org.xnio.Options.SASL_POLICY_NOANONYMOUS' in property 'remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS': java.lang.IllegalArgumentException: Class 'org.xnio.Options' not found

      15:27:30,298 DEBUG [org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration] (Timer-2) remote.connection.default.connect.options. has the following options {}

      15:27:30,298 DEBUG [org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration] (Timer-2) Connection org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration$RemotingConnectionConfigurationImpl@740505 successfully created for connection named default

      15:27:30,298 DEBUG [org.jboss.ejb.client.PropertiesBasedEJBClientConfiguration] (Timer-2) No clusters configured in properties

      15:27:30,302 DEBUG [org.xnio.nio] (Remoting "client-endpoint" read-1) Started channel thread 'Remoting "client-endpoint" read-1', selector sun.nio.ch.WindowsSelectorImpl@3565f0

      15:27:30,302 DEBUG [org.xnio.nio] (Remoting "client-endpoint" write-1) Started channel thread 'Remoting "client-endpoint" write-1', selector sun.nio.ch.WindowsSelectorImpl@1b7ab2a

      15:27:30,304 ERROR [org.jboss.remoting.remote] (Remoting "client-endpoint" read-1) JBREM000200: Remote connection failed: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?

      15:27:30,304 ERROR [org.jboss.remoting.remote] (Remoting "sansingh-t40064" read-1) JBREM000200: Remote connection failed: java.io.IOException: Received an invalid message length of -2140864253

      15:27:30,305 WARN  [org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector] (Timer-2) Could not register a EJB receiver for connection to remote://localhost:4447: java.lang.RuntimeException: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?

                at org.jboss.ejb.client.remoting.IoFutureHelper.get(IoFutureHelper.java:91) [jboss-ejb-client-1.0.0.Final.jar:1.0.0.Final]

                at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.setupEJBReceivers(ConfigBasedEJBClientContextSelector.java:107) [jboss-ejb-client-1.0.0.Final.jar:1.0.0.Final]

                at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.<init>(ConfigBasedEJBClientContextSelector.java:75) [jboss-ejb-client-1.0.0.Final.jar:1.0.0.Final]

                at com.tibco.mdm.util.JNDILookup.getHome(JNDILookup.java:359) [ECMClasses.jar:]

                at com.tibco.mdm.util.EJBLocator.getHome(EJBLocator.java:116) [ECMClasses.jar:]

                at com.tibco.mdm.session.workflow.event.process.ProcessSsn.getEJBHome(ProcessSsn.java:146) [ProcessSsnDeploy.jar:]

                at com.tibco.mdm.session.workflow.event.process.ProcessSsn.getEJBRemote(ProcessSsn.java:162) [ProcessSsnDeploy.jar:]

                at com.tibco.mdm.session.workflow.event.process.ProcessSsn.getEJBBizInterface(ProcessSsn.java:185) [ProcessSsnDeploy.jar:]

                at com.tibco.mdm.session.workflow.event.process.ProcessBusinessDelegate.init(ProcessBusinessDelegate.java:48) [ECMClasses.jar:]

                at com.tibco.mdm.session.workflow.event.process.ProcessBusinessDelegate.timeoutSuspendedProcesses(ProcessBusinessDelegate.java:264) [ECMClasses.jar:]

                at com.tibco.mdm.infrastructure.globalobj.MqRevivify$MqRevivifyTask.process(MqRevivify.java:584) [ECMClasses.jar:]

                at com.tibco.mdm.infrastructure.globalobj.MqRevivify$MqRevivifyTask.run(MqRevivify.java:450) [ECMClasses.jar:]

                at java.util.TimerThread.mainLoop(Timer.java:512) [:1.6.0_22]

                at java.util.TimerThread.run(Timer.java:462) [:1.6.0_22]

      Caused by: javax.net.ssl.SSLException: Unrecognized SSL message, plaintext connection?

                at com.sun.net.ssl.internal.ssl.EngineInputRecord.bytesInCompletePacket(EngineInputRecord.java:152) [:1.6]

                at com.sun.net.ssl.internal.ssl.SSLEngineImpl.readNetRecord(SSLEngineImpl.java:798) [:1.6]

                at com.sun.net.ssl.internal.ssl.SSLEngineImpl.unwrap(SSLEngineImpl.java:713) [:1.6]

                at javax.net.ssl.SSLEngine.unwrap(SSLEngine.java:607) [:1.6]

                at org.xnio.ssl.JsseConnectedSslStreamChannel.unwrap(JsseConnectedSslStreamChannel.java:439)

                at org.xnio.ssl.JsseConnectedSslStreamChannel.read(JsseConnectedSslStreamChannel.java:480)

                at org.xnio.ssl.JsseConnectedSslStreamChannel.read(JsseConnectedSslStreamChannel.java:445)

                at org.xnio.channels.FramedMessageChannel.receive(FramedMessageChannel.java:88)

                at org.jboss.remoting3.remote.ClientConnectionOpenListener$Greeting.handleEvent(ClientConnectionOpenListener.java:131)

                at org.jboss.remoting3.remote.ClientConnectionOpenListener$Greeting.handleEvent(ClientConnectionOpenListener.java:123)

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

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

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

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

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

                at org.xnio.ssl.JsseConnectedSslStreamChannel.handleReadable(JsseConnectedSslStreamChannel.java:180)

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

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

                at org.xnio.nio.NioHandle.run(NioHandle.java:90)

                at org.xnio.nio.WorkerThread.safeRun(WorkerThread.java:205)

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

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

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

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

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

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

                at org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector.setupEJBReceivers(ConfigBasedEJBClientContextSelector.java:105) [jboss-ejb-client-1.0.0.Final.jar:1.0.0.Final]

                ... 12 more

       

       

      15:27:30,371 DEBUG [org.jboss.ejb.client.remoting.ConfigBasedEJBClientContextSelector] (Timer-2) Registered 0 remoting EJB receivers for EJB client context org.jboss.ejb.client.EJBClientContext@3b6bc1

       

      Appreaciate any help on this.

       


      Thanks

      Sanjeev

        • 1. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
          jaikiran pai Master

          What are the exact jar files that you have included in your client classpath and which exact AS7 version are you testing this against?

          • 2. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
            Sanjeev Singh Newbie

            Thanks a lot JaiKiran for the quick reply

             

            I downloaded the final version of Jboss7.1 (Nightly build from https://ci.jboss.org/jenkins/job/JBoss-AS-7.x-latest/      on 7th Feb )

             

            Following are the JAR version's which I am using.

             

             

            jar name

            jboss-transaction-api_1.1_spec-1.0.0.Final

            jboss-ejb-api_3.1_spec-1.0.1.Final.jar

            jboss-ejb-client-1.0.0.Final.jar

            jboss-marshalling-1.3.6.GA.jar

            jboss-marshalling-river-1.3.6.GA.jar

            jboss-remoting-3.2.0.CR9.jar

            jboss-logging-3.1.0.CR2.jar

            xnio-api-3.0.0.GA.jar

            jboss-sasl-1.0.0.Final.jar

            jboss-marshalling-river-1.3.6.GA.jar

             

            Previously I was getting "No EJB receiver available for handling". I tried the resolve that error but didn't get rid off as such my  jboss-ejb-client.properties file was present in my class path and also setted in System variables through console.

             

            After getting the same error I changed the implementation as -

             

            String resourceName = "client.properties";

                                ClassLoader loader = JNDILookup.class.getClassLoader();

                                                URL url=loader.getResource(".");

                                                String path=URLDecoder.decode(url.getPath());

                                                path =path.substring(1);

                                                System.out.println(path);

                               

                                Properties clientConfigProps =new Properties();

                                path =  path+"/"+resourceName;

            System.out.println(path);

            clientConfigProps.load(new FileInputStream(path));

            EJBClientConfiguration clientConfiguration = new PropertiesBasedEJBClientConfiguration(clientConfigProps);

                              

            ContextSelector< EJBClientContext> ejbClientContextSelector = new ConfigBasedEJBClientContextSelector(clientConfiguration);

                                // Now let's setup the EJBClientContext to use this selector

            ContextSelector<EJBClientContext> previousSelector = EJBClientContext.setSelector(ejbClientContextSelector);

             

             

            After changing the implementation I am getting these above errors.

            • 3. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
              Prasad Deshpande Expert

              Can you post your client.properties here?

              • 4. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
                Prasad Deshpande Expert

                1. From your list seems that you are missing xnio-nio-3.0.0.GA.jar in your client claspath. It is required..

                 

                2. But from your post above it says

                 

                15:27:30,295 WARN  [org.xnio.option.parse] (Timer-2) Invalid option 'org.xnio.Options.SSL_ENABLED' in property 'remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED': java.lang.IllegalArgumentException: Class 'org.xnio.Options' not found

                Can you please check if you have xnio-api-3.0.0.GA.jar in your classpath properly?

                • 5. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
                  Sanjeev Singh Newbie

                  Hi Prashad,

                   

                  Following is my client.properties

                   

                  endpoint.name=client-endpoint

                  remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED=false

                  remote.connections=default

                  remote.connection.default.host=localhost

                  remote.connection.default.port = 4447

                  remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS=false

                   

                  Regards,

                  Sanjeev

                  • 6. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
                    Sanjeev Singh Newbie

                    Hi Prashad,

                     

                    xnio-nio Jar is also in my classpath .....below are the startup logs.

                     

                    21:56:35,966 INFO  [org.jboss.modules] JBoss Modules version 1.1.0.CR8

                    21:56:36,169 INFO  [org.jboss.msc] JBoss MSC version 1.0.2.GA

                    21:56:36,218 INFO  [org.jboss.as] JBAS015899: JBoss AS 7.1.0.Final-SNAPSHOT "Flux Capacitor" starting

                    21:56:37,093 INFO  [org.jboss.as.server] JBAS015888: Creating http management service using socket-binding (management-http)

                    21:56:37,099 INFO [org.xnio] XNIO Version 3.0.0.GA

                    21:56:37,112 INFO  [org.xnio.nio] XNIO NIO Implementation Version 3.0.0.GA

                    21:56:37,124 INFO  [org.jboss.as.logging] JBAS011502: Removing bootstrap log handlers

                    21:56:37,131 INFO  [org.jboss.remoting] JBoss Remoting version 3.2.0.CR9

                     

                    Regards,

                    Sanjeev

                    • 7. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
                      Prasad Deshpande Expert

                      your client properties looks ok to me.. can you try with having above two jar files in your client classpath?

                       

                      Also when you say

                      Previously I was getting "No EJB receiver available for handling". I tried the resolve that error but didn't get rid off as such my  jboss-ejb-client.properties file was present in my class path and also setted in System variables through console.

                      How did you put jboss-ejb-client.properties in classpath? just as a file or inside any jar? Cause if it's in classpath then it sould be automatically picked-up. Can you try InputStream is = getClass().getClassLoader().getResourceAsStream("jboss-ejb-client.properties"); just to see whether your classloader can see this file? Your inputstream should not be null if it's in classpath & can be seen by classloader..

                      • 8. Re: Invalid option 'org.xnio.Options.SSL_ENABLED'
                        Prasad Deshpande Expert

                        Sanjeev Singh wrote:

                         

                        xnio-nio Jar is also in my classpath .....below are the startup logs.

                         

                        21:56:37,099 INFO [org.xnio] XNIO Version 3.0.0.GA

                        21:56:37,112 INFO  [org.xnio.nio] XNIO NIO Implementation Version 3.0.0.GA

                         

                        Regards,

                        Sanjeev

                        Those logs seems to be from server side.. It will always be there in server classpath..  you need it in your client classpath too where you get this exception..