[jboss-user] [JCA/JBoss] - Problem in data source binding while server start

sunil@jboss.org do-not-reply at jboss.com
Thu Feb 19 04:45:47 EST 2009


Hi All,

I am facing a problem in jboss deployment order while starting server. I am trying to deploy a .jar file which connects to mssql data source. While deploying I am getting the below exception:


14:36:48,795 ERROR [Alerter] Exception occurred in com.soa.alerter.Alerter : MSSQLDSA not bound

javax.naming.NameNotFoundException: MSSQLDSA not bound
        at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)
        at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)
        at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
        at org.jnp.server.NamingServer.lookup(NamingServer.java:296)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
        at sun.rmi.transport.Transport$1.run(Transport.java:153)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.rmi.transport.Transport.serviceCall(Transport.java:149)
        at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:466)
        at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:707)
        at java.lang.Thread.run(Thread.java:595)
        at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)

        at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)
        at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
        at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
        at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:667)
        at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
        at javax.naming.InitialContext.lookup(InitialContext.java:351)
        at com.nyco.soa.alerter.Alerter.getConnection(Unknown Source)
        at com.nyco.soa.alerter.Alerter.getQueueList(Unknown Source)
        at com.nyco.soa.alerter.Alerter.execute(Unknown Source)
        at com.nyco.soa.alerter.Alerter.perform(Unknown Source)
        at org.jboss.varia.scheduler.Scheduler$Listener.handleNotification(Scheduler.java:1251)
        at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.jboss.mx.notification.NotificationListenerProxy.invoke(NotificationListenerProxy.java
:153)
        at $Proxy11.handleNotification(Unknown Source)
        at javax.management.NotificationBroadcasterSupport.handleNotification(NotificationBroadcaste
rSupport.java:221)
        at javax.management.NotificationBroadcasterSupport.sendNotification(NotificationBroadcasterS
upport.java:184)
        at javax.management.timer.Timer.sendNotification(Timer.java:1295)
        at javax.management.timer.Timer.notifyAlarmClock(Timer.java:1264)
        at javax.management.timer.TimerAlarmClock.run(Timer.java:1347)
        at java.util.TimerThread.mainLoop(Timer.java:512)
        at java.util.TimerThread.run(Timer.java:462)



I have configured two data sources in mssql-ds.xml which point to the same database. Following is the data source configuration:



<local-tx-datasource>
    <jndi-name>DefaultDS</jndi-name>
    <connection-url>jdbc:sqlserver://102.602.19.163:1433;DatabaseName=myDB</connection-url>
    <driver-class>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver-class>
    <user-name>sa</user-name>
    sa
        <!-- sql to call when connection is created
        <new-connection-sql>some arbitrary sql</new-connection-sql>
        -->

        <!-- sql to call on an existing pooled connection when it is obtained from pool 
        <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
        -->

      <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->
      
         <type-mapping>MS SQLSERVER2000</type-mapping>
      
  </local-tx-datasource>

<local-tx-datasource>
    <jndi-name>MSSQLDSA</jndi-name>
	<use-java-context>false</use-java-context>
    <connection-url>jdbc:sqlserver://102.602.19.163:1433;DatabaseName=myDB</connection-url>
    <driver-class>com.microsoft.sqlserver.jdbc.SQLServerDriver</driver-class>
    <user-name>sa</user-name>
    sa
        <!-- sql to call when connection is created
        <new-connection-sql>some arbitrary sql</new-connection-sql>
        -->

        <!-- sql to call on an existing pooled connection when it is obtained from pool 
        <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
        -->

      <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->
      
         <type-mapping>MS SQLSERVER2000</type-mapping>
      
  </local-tx-datasource> 

  


Thanks in Advance for the help :)

  

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4211369#4211369

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4211369



More information about the jboss-user mailing list