Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Cannot create XA data source with MS SQL

Hello,

I am currently trying to create a datasource with he XA transactions support. The exception is the same when I'm using the SYSTEM_DRIVER (NetWeaver is using the MS SQL 2005) and when I'm using the user-defined MS SQL JDBC driver. The 'regular' (using tag <jdbc-1.x>) datasources are successfully created, the problem appears only for the XA one.

This is the part of my data-sources.xml responsible for this data source:

 <data-source>
        <data-source-name>DataSource/SCP</data-source-name>
        <driver-name>SYSTEM_DRIVER</driver-name>
        <init-connections>5</init-connections>
        <max-connections>25</max-connections>
        <sql-engine>Vendor_SQL</sql-engine>
        <jdbc-2.0>
            <xads-class-name>com.microsoft.sqlserver.jdbc.SQLServerXADataSource</xads-class-name>
            <object-factory>com.microsoft.sqlserver.jdbc.SQLServerDataSourceObjectFactory</object-factory>
           <properties>
                <property>
                    <property-name>serverName</property-name>
                    <property-value>localhost</property-value>
                </property>
                <property>
                    <property-name>databaseName</property-name>
                    <property-value>SCP</property-value>
                </property>
                <property>
                    <property-name>port</property-name>
                    <property-value>1433</property-value>
                </property>
                <property>
                    <property-name>user</property-name>
                    <property-value>myUser</property-value>
                </property>
                <property>
                    <property-name>password</property-name>
                    <property-value>myPassword<property-value>
                </property>
            </properties>
        </jdbc-2.0>
    </data-source>

Below you can see the stacktrace that appears in the defaultTrace_00.trc:

Text: [ERROR CODE DPL.DS.5029] Exception in operation startApp with application se.sync/BPE.
Reason : [ERROR CODE DPL.DS.5029] Exception in operation startApp with application se.sync/BPE. 
[EXCEPTION]
 com.sap.engine.services.deploy.exceptions.ServerDeploymentException: [ERROR CODE DPL.DS.5029] Exception in operation startApp with application se.sync/BPE.
	at com.sap.engine.services.deploy.server.application.ApplicationTransaction.rollbackPart(ApplicationTransaction.java:521)
	at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:422)
	at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:445)
	at com.sap.engine.services.deploy.server.application.ParallelAdapter.super_MakeAllPhases(ParallelAdapter.java:337)
	at com.sap.engine.services.deploy.server.application.StartTransaction.makeAllPhasesImpl(StartTransaction.java:550)
	at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:251)
	at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesAndWait(ParallelAdapter.java:392)
	at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3389)
	at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3375)
	at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3278)
	at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:3251)
	at com.sap.engine.services.dc.lcm.impl.J2EELCMProcessor.doStart(J2EELCMProcessor.java:99)
	at com.sap.engine.services.dc.lcm.impl.LifeCycleManagerImpl.start(LifeCycleManagerImpl.java:62)
	at com.sap.engine.services.dc.cm.deploy.impl.LifeCycleManagerStartVisitor.visit(LifeCycleManagerStartVisitor.java:34)
	at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
	at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcessLCMDeplItem(DefaultDeployPostProcessor.java:80)
	at com.sap.engine.services.dc.cm.deploy.impl.DefaultDeployPostProcessor.postProcess(DefaultDeployPostProcessor.java:56)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doPostProcessing(DeployerImpl.java:741)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:732)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:576)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:270)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:192)
	at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:875)
	at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:351)
	at com.sap.engine.services.rmi_p4.server.ServerDispatchImpl.run(ServerDispatchImpl.java:70)
	at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:62)
	at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:37)
	at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:877)
	at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:53)
	at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:58)
	at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
	at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:304)
Caused by: com.sap.engine.services.dbpool.exceptions.BaseDeploymentException: Cannot create DataSource "DataSource/SCP".
	at com.sap.engine.services.dbpool.deploy.ContainerImpl.startDataSources(ContainerImpl.java:1467)
	at com.sap.engine.services.dbpool.deploy.ContainerImpl.prepareStart(ContainerImpl.java:468)
	at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:219)
	at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:179)
	at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:420)
	... 30 more
Caused by: java.lang.NullPointerException
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:164)
	at com.sap.engine.services.dbpool.deploy.ContainerImpl.startDataSources(ContainerImpl.java:1394)
	... 34 more

When I'm looking at the \usr\sap\EE5\J00\exe\mssjdbc\sqljdbc.jar file, I can see both these classes (SQLServerXADataSource and SQLServerDataSourceObjectFactory), so the problem is probably somewhere else. As the exception comes from the native method - does it mean, that the XA extension is not installed correctly on the server (as described [here|http://technet.microsoft.com/en-us/library/aa342335(SQL.90).aspx])?

Thanks for any help!

Best Regards,

-Milosz

Not what you were looking for? View more on this topic or Ask a question