2 Replies Latest reply on Sep 9, 2002 4:15 PM by Dain Sundstrom

    a question about CMP 1.1 compatibility

    dugu Newbie


      i know we should be using CMP 2.0 now, but i am trying some exercises from some published EJB books which have examples using JBoss 2.x CMP 1.1 JAWS. My questions are these :

      Using JBoss 3, can these configurations work?

      1. using jaws.xml AND jboss.jcml
      (i cannot seem to find an example jboss.jcml so can
      i take jboss.jcml from JBoss 2.x distribution,
      modify it and put it in conf directory)?

      2. set DOCTYPE to 1.1 and use JAWS?

      3. let DOCTYPE remain at 2.0 but
      set <cmp-version> to 1.x and use JAWS?

      4. any other variations?

      Also, since standardjaws.xml is in conf directory, in CMP 2.0, will it STILL be picked up? or will it be picked by ONLY under the any of above configurations?

      I suppose standardjbosscmp-jdbc will be ignored under above configurations, correct?

      BTW, why is DOCTYPE in standardjaws.xml declared as

      <!DOCTYPE jbosscmp-jdbc PUBLIC
      "-//JBoss//DTD JBOSSCMP-JDBC 3.0//EN"
      "http://www.jboss.org/j2ee/dtd/jbosscmp-jdbc_3_0.dtd">

      Shouldn't it be declared like following?

      <!DOCTYPE jaws PUBLIC
      "-//JBoss//DTD JAWS 2.4//EN"
      "http://www.jboss.org/j2ee/dtd/jaws_2_4.dtd">

      i'm using JBoss 3.0.1

        • 1. Re: a question about CMP 1.1 compatibility
          Damian Sutton Newbie

          Hi,

          I want to help, but you have asked alot of questions and I will do my best to answer them.

          Firstly, it is very possible to use CMP1.1 on JBoss 3.0.1.

          You can use the JAWS file just as you did before in other 2.x versions of JBoss.

          In JBoss 3.0.x jcml.xml has gone. Most of this work is now complete from whatever-service.xml files in your deploy folder. Have a look in the deploy folder for examples, eg hsqldb-service.xml. If you want to create a new service (or DB Mapping) you must create a new file.

          Other examples are in the docs\examples\jca folder. If you wish to use them, insert them into the deploy folder, that were they going if you want them to work.

          Doc type of JAWS should not matter, I don't even include a doc type and it still works.

          Doc type in ejb-jar.xml is really important, if you want to use CMP1.1, use the CMP1.1 doc type.

          I hope this helped a little.

          Damian

          • 2. Re: a question about CMP 1.1 compatibility
            Dain Sundstrom Master

            You can use the new JBossCMP persistence manager, which replaces JAWS, in backwards compatiability mode. To do this, use a 2.0 ejb-jar.xml file with cmp-version set to 1.x. JAWS will be removed in JBoss 4.0.