1 2 Previous Next 16 Replies Latest reply on Sep 16, 2002 2:29 AM by pvamstel

    ra.xml for eXcelon

    pvamstel

      This is a newbe question and i hope someone could tell me where to start.

      I'm trying to connect to a XML database called excelon. They have suppied the ra.xml and the connection factory.

      <?xml version="1.0" encoding="UTF-8"?>

      <!DOCTYPE connector PUBLIC '-//Sun Microsystems, Inc.//DTD Connector 1.0//EN' 'http://java.sun.com/dtd/connector_1_0.dtd'>


      <display-name>Excelon DXE Remote Connector</display-name>
      <vendor-name>Excelon Corporation</vendor-name>
      <spec-version>1.0</spec-version>
      <eis-type></eis-type>
      1.0

      <managedconnectionfactory-class>com.exln.dxe.jca.RemoteManagedConnectionFactory</managedconnectionfactory-class>
      <connectionfactory-interface>javax.resource.cci.ConnectionFactory</connectionfactory-interface>
      <connectionfactory-impl-class>com.exln.dxe.jca.RemoteConnectionFactory</connectionfactory-impl-class>
      <connection-interface>javax.resource.cci.Connection</connection-interface>
      <connection-impl-class>com.exln.dxe.jca.ConnectionImpl</connection-impl-class>
      <transaction-support>NoTransaction</transaction-support>
      <config-property>
      DXE admin server name
      <config-property-name>ServerName</config-property-name>
      <config-property-type>java.lang.String</config-property-type>
      <config-property-value>sydney.anachron.nl</config-property-value>
      </config-property>
      <config-property>
      DXE admin host port
      <config-property-name>PortNumber</config-property-name>
      <config-property-type>java.lang.Integer</config-property-type>
      <config-property-value>1050</config-property-value>
      </config-property>
      <authentication-mechanism>
      Authentication mechanism
      <authentication-mechanism-type>BasicPassword</authentication-mechanism-type>
      <credential-interface>javax.resource.security.PasswordCredential</credential-interface>
      </authentication-mechanism>
      <reauthentication-support>false</reauthentication-support>



      They also gave a weblogic specific file.

      <?xml version="1.0"?>

      <!DOCTYPE weblogic-connection-factory-dd PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 6.0.0 Connector//EN" "http://www.bea.com/servers/wls600/dtd/weblogic600-ra.dtd">

      <weblogic-connection-factory-dd>

      <connection-factory-name>DXERemoteConnectionFactory</connection-factory-name>
      <jndi-name>eis/DXERemoteConnector_JNDI</jndi-name>

      <map-config-property>
      <map-config-property-name>ServerName</map-config-property-name>
      <map-config-property-value>localhost</map-config-property-value>
      </map-config-property>

      <map-config-property>
      <map-config-property-name>PortNumber</map-config-property-name>
      <map-config-property-value>9876</map-config-property-value>
      </map-config-property>

      <security-principal-map>
      </security-principal-map>

      </weblogic-connection-factory-dd>

      How does this map to someting from jboss.

      Where do i start??
      What documentation can i read.

      Anything will help

      Has it got something to do with the xe-datasource

      grt Patrick

        • 1. Re: ra.xml for eXcelon
          davidjencks

          I hope they provided compliant packaging in a .rar file.

          It's always useful to say what jboss version you are using.

          If you have a binary download of jboss 3.x, look at the firebird-service.xml file in docs/jca/example-config (I think). Change XaTxConnectionManager to NoTxConnectionManager. Change all the config-properties and their values to the properties for exelon. Set the jndi name. change the object names if you don't want to be confused :-)

          Deploy the adapter by putting it in the deploy directory. After it has deployed, look at the jmx viewer (port 8080/jmx-console) and find the mbean representing the deployed rar: put its object name in the "oldRarDeployment" property in your *-service.xml file. Deploy this file by putting it in deploy also.

          After you have it working, please submit it and I will put it in cvs to help the next guy.

          There are some instructions in the quickstart guide. Be sure you have the right firebird-service.xml file to start with for your jboss version: they are all slightly different and hard to see what the differences are. Generally if you look closely at the server.log there are a lot of clues if anything doesn't work.

          • 2. Re: ra.xml for eXcelon
            pvamstel

            Thx for the start but still struggeling

            • 3. Re: ra.xml for eXcelon
              pvamstel

              I've done what you suggested but. I do not understand the bit about the oldRarDeployment.

              This is what i have in the MBean view

              MBean View [JMX RI/1.0]

              MBean Name: jboss.jca:service=XaTxDS,name=ExcelonDS
              MBean Java Class: org.jboss.resource.connectionmanager.RARDeployment
              Back to Agent View Reload Period in seconds:




              --------------------------------------------------------------------------------

              MBean description:
              Management Bean.



              --------------------------------------------------------------------------------

              List of MBean attributes:
              Name Type Access Value
              AuthenticationMechanismType java.lang.String RW
              ConnectionFactoryImplClass java.lang.String RW
              ConnectionFactoryInterface java.lang.String RW
              ConnectionImplClass java.lang.String RW
              ConnectionInterface java.lang.String RW
              CredentialInterface java.lang.String RW
              DisplayName java.lang.String RW
              EisType java.lang.String RW
              JndiName java.lang.String RW
              ManagedConnectionFactoryClass java.lang.String RW
              ManagedConnectionFactoryProperties org.w3c.dom.Element RW Type Not Supported: [ <config-property> DXE admin server name <config-property-name>ServerName</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>sydney.anachron.nl</config-property-value> </config-property> <config-property> DXE admin host port <config-property-name>PortNumber</config-property-name> <config-property-type>java.lang.Integer</config-property-type> <config-property-value>1050</config-property-value> </config-property> ]
              OldRarDeployment javax.management.ObjectName RW view
              ReauthenticationSupport boolean RW True False
              SpecVersion java.lang.String RW
              TransactionSupport java.lang.String RW
              VendorName java.lang.String RW
              Version java.lang.String RW





              --------------------------------------------------------------------------------


              List of MBean operations:

              --------------------------------------------------------------------------------
              Description of stopManagedConnectionFactory
              void


              --------------------------------------------------------------------------------
              Description of setManagedConnectionFactoryAttribute (Operation Not Supported)
              void setManagedConnectionFactoryAttribute (java.lang.String)java.lang.String
              (java.lang.Class)java.lang.Class
              (java.lang.Object)java.lang.Object




              --------------------------------------------------------------------------------
              Description of startManagedConnectionFactory (Operation Not Supported)
              javax.resource.spi.ManagedConnectionFactory startManagedConnectionFactory (javax.resource.spi.ConnectionManager)javax.resource.spi.ConnectionManager

              I think i miss a lot of stuff here.

              And how is the ra.xml connected to this service file. How does this servise thing knows which rar to use?

              How do i tell the service file which class to use for the connection factory. And for what interface should i look in the given jar file so the mbean deployer does not complain?

              I hope someone will help me

              • 4. Re: ra.xml for eXcelon
                pvamstel

                I've done what you suggested but. I do not understand the bit about the oldRarDeployment.

                This is what i have in the MBean view

                MBean View [JMX RI/1.0]

                MBean Name: jboss.jca:service=XaTxDS,name=ExcelonDS
                MBean Java Class: org.jboss.resource.connectionmanager.RARDeployment
                Back to Agent View Reload Period in seconds:




                --------------------------------------------------------------------------------

                MBean description:
                Management Bean.



                --------------------------------------------------------------------------------

                List of MBean attributes:
                Name Type Access Value
                AuthenticationMechanismType java.lang.String RW
                ConnectionFactoryImplClass java.lang.String RW
                ConnectionFactoryInterface java.lang.String RW
                ConnectionImplClass java.lang.String RW
                ConnectionInterface java.lang.String RW
                CredentialInterface java.lang.String RW
                DisplayName java.lang.String RW
                EisType java.lang.String RW
                JndiName java.lang.String RW
                ManagedConnectionFactoryClass java.lang.String RW
                ManagedConnectionFactoryProperties org.w3c.dom.Element RW Type Not Supported: [ <config-property> DXE admin server name <config-property-name>ServerName</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>sydney.anachron.nl</config-property-value> </config-property> <config-property> DXE admin host port <config-property-name>PortNumber</config-property-name> <config-property-type>java.lang.Integer</config-property-type> <config-property-value>1050</config-property-value> </config-property> ]
                OldRarDeployment javax.management.ObjectName RW view
                ReauthenticationSupport boolean RW True False
                SpecVersion java.lang.String RW
                TransactionSupport java.lang.String RW
                VendorName java.lang.String RW
                Version java.lang.String RW





                --------------------------------------------------------------------------------


                List of MBean operations:

                --------------------------------------------------------------------------------
                Description of stopManagedConnectionFactory
                void


                --------------------------------------------------------------------------------
                Description of setManagedConnectionFactoryAttribute (Operation Not Supported)
                void setManagedConnectionFactoryAttribute (java.lang.String)java.lang.String
                (java.lang.Class)java.lang.Class
                (java.lang.Object)java.lang.Object




                --------------------------------------------------------------------------------
                Description of startManagedConnectionFactory (Operation Not Supported)
                javax.resource.spi.ManagedConnectionFactory startManagedConnectionFactory (javax.resource.spi.ConnectionManager)javax.resource.spi.ConnectionManager

                I think i miss a lot of stuff here.

                And how is the ra.xml connected to this service file. How does this servise thing knows which rar to use?

                How do i tell the service file which class to use for the connection factory. And for what interface should i look in the given jar file so the mbean deployer does not complain?

                I hope someone will help me

                • 5. Re: ra.xml for eXcelon
                  pvamstel

                  I've done what you suggested but. I do not understand the bit about the oldRarDeployment.

                  This is what i have in the MBean view

                  MBean View [JMX RI/1.0]

                  MBean Name: jboss.jca:service=XaTxDS,name=ExcelonDS
                  MBean Java Class: org.jboss.resource.connectionmanager.RARDeployment
                  Back to Agent View Reload Period in seconds:




                  --------------------------------------------------------------------------------

                  MBean description:
                  Management Bean.



                  --------------------------------------------------------------------------------

                  List of MBean attributes:
                  Name Type Access Value
                  AuthenticationMechanismType java.lang.String RW
                  ConnectionFactoryImplClass java.lang.String RW
                  ConnectionFactoryInterface java.lang.String RW
                  ConnectionImplClass java.lang.String RW
                  ConnectionInterface java.lang.String RW
                  CredentialInterface java.lang.String RW
                  DisplayName java.lang.String RW
                  EisType java.lang.String RW
                  JndiName java.lang.String RW
                  ManagedConnectionFactoryClass java.lang.String RW
                  ManagedConnectionFactoryProperties org.w3c.dom.Element RW Type Not Supported: [ <config-property> DXE admin server name <config-property-name>ServerName</config-property-name> <config-property-type>java.lang.String</config-property-type> <config-property-value>sydney.anachron.nl</config-property-value> </config-property> <config-property> DXE admin host port <config-property-name>PortNumber</config-property-name> <config-property-type>java.lang.Integer</config-property-type> <config-property-value>1050</config-property-value> </config-property> ]
                  OldRarDeployment javax.management.ObjectName RW view
                  ReauthenticationSupport boolean RW True False
                  SpecVersion java.lang.String RW
                  TransactionSupport java.lang.String RW
                  VendorName java.lang.String RW
                  Version java.lang.String RW





                  --------------------------------------------------------------------------------


                  List of MBean operations:

                  --------------------------------------------------------------------------------
                  Description of stopManagedConnectionFactory
                  void


                  --------------------------------------------------------------------------------
                  Description of setManagedConnectionFactoryAttribute (Operation Not Supported)
                  void setManagedConnectionFactoryAttribute (java.lang.String)java.lang.String
                  (java.lang.Class)java.lang.Class
                  (java.lang.Object)java.lang.Object




                  --------------------------------------------------------------------------------
                  Description of startManagedConnectionFactory (Operation Not Supported)
                  javax.resource.spi.ManagedConnectionFactory startManagedConnectionFactory (javax.resource.spi.ConnectionManager)javax.resource.spi.ConnectionManager

                  I think i miss a lot of stuff here.

                  And how is the ra.xml connected to this service file. How does this servise thing knows which rar to use?

                  How do i tell the service file which class to use for the connection factory. And for what interface should i look in the given jar file so the mbean deployer does not complain?

                  I hope someone will help me

                  • 6. Re: ra.xml for eXcelon
                    davidjencks

                    When you deploy a .rar, jboss generates an mbean for it that basically makes a classloader for the classes and makes the ra.xml contents available. This one is named something like jboss.jca:service=RARDeployment,name=<adapter-display-name>.

                    When you deploy the mbeans to set up a connection factory, you need to tell it which adapter to use. Right now this is done through the mbean reference to the "OldRARDeployment" which is the one I just mentioned from deploying the .rar. Only the stuff from the .rar needed to set up the connection factory and the property values from the mbean config are shown in the "managedConnectionFactory" mbean that you show the configuration of. Unfortunately I made 2 bad naming choices here: calling this mbean class RARDeployment also and using the naming convention of giving it an object name with service=XaTxDS in it. I wish I had named them both using ManagedConnectionFactory.

                    Anyway, jboss doesn't really care what kind of connection factory is supplied by your ManagedConnectionFactory, since all it has to do is get it from the mcf using createConnectionFactory, and bind it in jndi.

                    I'd expect that all 4 needed mbeans have been deployed. Were there any errors? What state are they in? Did the connection factory get bound in jndi?

                    • 7. Re: ra.xml for eXcelon
                      pvamstel

                      I'm a bit further now

                      When i have it working i let you know

                      Thx a lot for all the help so far

                      • 8. Re: ra.xml for eXcelon
                        pvamstel

                        Another step in the correct direction.

                        But these properties are not propagated to the the eXcelon Remote Connection Factory class.

                        They are in the rar deployment mbean. How do i get them to the class. adding them to properties in the managed connection factory does not realy have the correct effect


                        <config-property>
                        <!-- DXE admin server name -->
                        <config-property-name>ServerName</config-property-name>
                        <config-property-type>java.lang.String</config-property-type>
                        <config-property-value>sydney.anachron.nl</config-property-value>
                        </config-property>
                        <config-property>
                        <!-- DXE admin host port -->
                        <config-property-name>PortNumber</config-property-name>
                        <config-property-type>Integer</config-property-type>
                        <config-property-value>1051</config-property-value>
                        </config-property>

                        • 9. Re: ra.xml for eXcelon
                          pvamstel

                          Seems to be working better wit jboss 3.02 and jetty

                          But now i have

                          14:32:05,625 INFO [eis/DXERemoteConnector] [JCA] RMCF: Creating managed connect
                          ion: Subject=null this=com.exln.dxe.jca.RemoteManagedConnectionFactory@5ac9fca4
                          14:32:06,046 ERROR [LogInterceptor] Unexpected Error:
                          java.lang.LinkageError: duplicate class definition: com/ooc/CORBA/ORB
                          at java.lang.ClassLoader.defineClass0(Native Method)
                          at java.lang.ClassLoader.defineClass(ClassLoader.java:502)
                          at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:12


                          I'm just totally lost and go and have a nice weekend

                          If anyone knows any starting points please do not shy away

                          Till monday

                          • 10. Re: ra.xml for eXcelon
                            pvamstel

                            It was a configuration thing

                            The jar from excelon only works with jdk1.3

                            How are properties past to the application.
                            Because they are not set with this syntax



                            <config-property>
                            <config-property-name>ServerName</config-property-name>
                            <config-property-type>java.raar.String</config-property-type>
                            <config-property-value>sydney.anachron.nl</config-property-value>
                            </config-property>
                            <config-property>
                            <config-property-name>PortNumber</config-property-name>
                            <config-property-type>java.raar.Integer</config-property-type>
                            <config-property-value>1050</config-property-value>
                            </config-property>



                            Is this normal or is there something special i have to set




                            grt Patrick

                            • 11. Re: ra.xml for eXcelon
                              pvamstel

                              A never ending story it seems.

                              I finally know where the problem lies.

                              The connector needs to read a properties file.

                              The file is called like
                              obj = ClassLoader.getSystemResourceAsStream("Properties file name")

                              Where do i package this file in the rar jar?
                              And do i need to set any security things that it can actually read this file.

                              I just put it in the root of the rar file and it could not find it

                              grt Patrick

                              • 12. Re: ra.xml for eXcelon
                                davidjencks

                                You don't need any extra security settings.

                                You'll need to put the file in the jar inside the rar I suspect. I don't know if the root of the jar or the same directory as the class that is reading it is more likely to work.

                                maybe you could lobby the vendor to support jca spec-compliant configuration via ManagedConnectionFactoryt properties.

                                • 13. Re: ra.xml for eXcelon
                                  pvamstel

                                  Our relationship with the vendor is not that great anymore. So we do not have support or any other resource where we can put our questions.

                                  So lobying does not realy work.

                                  I think i i will solve it the easy way. Because there is no real standard way of setting all the properties.

                                  Do you still want the service file

                                  grt Patrick

                                  • 14. Re: ra.xml for eXcelon
                                    davidjencks

                                    Sorry to hear the vendor isn't cooperative. I'd still like the config file, especially if you can include instructions on how to get it to work:-)

                                    thanks
                                    david

                                    1 2 Previous Next