0 Replies Latest reply on Jun 30, 2002 10:50 PM by a13519

    DS

    a13519

      I tried to setup a datasource for my mySql server. Everything looks OK in the Jboss server console, but when I use a test client to lookup my datasource, there is a exception of time out.

      Version: WINDOWS2000SP2 + JBoss 3.0 + MySql + JDBC driver mm.mysql.jdbc-1.2c

      SETUP Datasource:
      I just simply modify exsit samply file mysql-service to match my system situation. I changed connnection URL. Then I copy this file to %JBOSS_DIST%\server\default\deploy. I can clearly see that the console print out :
      --------------------------------------------------------
      17:42:17,640 WARN [ServiceController] jboss.jca:service=LocalTxDS,name=MySqlDS
      does not implement any Service methods
      17:42:17,640 INFO [LocalTxConnectionManager] Creating
      17:42:17,796 INFO [LocalTxConnectionManager] Created
      17:42:18,000 INFO [LocalTxConnectionManager] Starting
      17:42:18,781 INFO [MySqlDS] Bound connection factory for resource adapter 'JBos
      s LocalTransaction JDBC Wrapper' to JNDI name 'java:/MySqlDS'
      17:42:18,781 INFO [LocalTxConnectionManager] Started
      --------------------------------------------------------

      Client looks up:

      I write a very very simply client to run to check if I could find this datasource:
      --------------------------------------------------------
      import javax.naming.InitialContext;

      /**
      * This is a simple client for the "CD" EJB; it lists (to standard output) all
      * the "CD" instances in the system. The "main" method allows this class to be
      * run from the command line.
      */
      public class JTest
      {

      public static void main(String[] args)
      {
      try
      {
      InitialContext jndiContext = new InitialContext();

      Object ref = jndiContext.lookup("java:/MySqlDS");
      System.out.println(ref);
      }
      catch(Exception e)
      {
      System.out.println(e.toString());
      }
      }

      }
      --------------------------------------------------------

      I got a exception in running:
      javax.naming.CommunicationException: Receive timed out [Root exception is java.n
      et.SocketTimeoutException: Receive timed out]

      Although I want to make sure my client has no problem, I tried to lookup queue/DLQ, it's OK, I can find it.

      Where is wrong? Any suggestions are welcome and I am appreciated that.

      Thanks,
      a13519