2 Replies Latest reply on Nov 17, 2009 6:50 AM by liuliu

    question about datasource configuration.

    liuliu

      hello ,

      my problem is i have to deploy the same ear with different app name on the same jboss server. every application has his app-name-ds file to connect different database.

      I want to know how configure the ear to connect his database without modify the source code ?

      thanks in advance.

        • 1. Re: question about datasource configuration.
          vickyk

           

          "liuliu" wrote:

          I want to know how configure the ear to connect his database without modify the source code ?

          what does the source code refer to here?
          Is this the configuration related change in the -ds.xml and the corresponding deployment descriptor files?

          • 2. Re: question about datasource configuration.
            liuliu


            thanks for your reply,

            source code here means java code in backingbean or ejb.
            by example:
            in ejb : context.lookup("jdbc/datasource")
            in -ds.xml : <jndi_name>ear_name_ds</jndi_name>
            somewhere in ear : ear_name_ds = jdbc/datasource.
            I know i can do it with web.xml,jboss-web.xml and declare it for every ejb.
            what i want is to do it in ONE place.