2 Replies Latest reply on Sep 11, 2003 6:26 PM by coachvargo

    Postgress and Jboss

    Ron Jawanda Novice

      Anyone connected to a postgress database?
      If so, what driver did you specify and do you have the XML file?
      Thank you

        • 1. Re: Postgress and Jboss
          coachvargo Newbie

          yep, I just dropped the postgres-ds.xml file into the deploy directory. It's a small connection pool, since we're only in development right now. But I do have a small problem with this...when I start JBoss, the first, and only the first, attempt at a database connection fails with an "Apparently wrong driver class specified for URL" error. But each call after that works fine. I would imagine something is getting loaded out of order, but I'm not sure. Anyone else see this problem?

          Here is a copy of the xml file:

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



          <local-tx-datasource>
          <jndi-name>PortalDS</jndi-name>
          <connection-url>jdbc:postgresql://192.168.1.30:5432/portal</connection-url>
          <driver-class>org.postgresql.Driver</driver-class>
          <min-pool-size>1</min-pool-size>
          <max-pool-size>5</max-pool-size>
          </local-tx-datasource>

          • 2. Re: Postgress and Jboss
            coachvargo Newbie

            I fixed the problem myself...

            I realized that the postgresql jdbc .jar file needs to be in the server/{default}/lib directory. I originally had it in the WEB-INF/lib. Makes sense since I suspected it may have been a loading issue.