Hi,

I wrote to the list a couple of weeks ago with problems getting the
latest stable Castor (0.9.3.9) to work with JBoss 2.4.4. Well, I sorted
it out eventually but didn't find any time to write down the procedure
and send it off to the list.

The basic procedure involves getting the latest known stable version of
the castor JDO plugin (ie the one that shipped with JBoss 2.4.3) from
the CVS repository, changing a few lines of code in it and building it
against the JBoss 2.4.4 jars.

Here's how I did it:

   o I downloaded JBoss 2.4.4 into the directory $JBOSS_244 and
     removed the 0.8.x release of Castor that shipped with
     it. (in $JBOSS_244/lib/ext)
   o I downloaded JBoss HEAD from CVS into $JBOSS_HEAD.
   o I reverted the Castor stuff from HEAD to the 2.4.3 release. It
     wasn't tagged, so I had to revert by date.
        > cd $JBOSS_HEAD/plugins/varia/src/main
        > cvs update -D "2001-10-03"
   o Applied the patch below.
   o Built it manually against the 2.4.4 jars:
        > javac -classpath
$JBOSS_244/lib/ext/jboss.jar:$JBOSS_244/lib/jmxri.jar:$JBOSS_244/lib/ext/castor-0.9.3.9.jar:$JBOSS_244/lib/crimson.jar:$JBOSS_244/lib/ext/log4j.jar
 org/jboss/jdo/castor/*.java
   o Created a jar.
        > jar cvf $JBOSS_244/lib/ext/jboss-castorjdo-2.4.4.jar
org/jboss/jdo/castor/*.class

Here's the unified diff, generated with "cvs diff -u
CastorJDOImpl*.java" in org/jboss/jdo/castor. NOTE: This diff is
generated against a snapshot of the code (Oct 3, 2001), NOT against
HEAD.

--- 8< ---
Index: CastorJDOImpl.java
===================================================================
RCS file:
/cvsroot/jboss/contrib/varia/src/main/org/jboss/jdo/castor/CastorJDOImpl.java,v
retrieving revision 1.5
diff -u -r1.5 CastorJDOImpl.java
--- CastorJDOImpl.java  2001/09/11 20:51:32     1.5
+++ CastorJDOImpl.java  2002/02/01 17:24:33
@@ -37,7 +37,7 @@
 import org.exolab.castor.xml.Unmarshaller;
 
 import org.jboss.logging.log4j.CategoryWriter;
-import org.jboss.system.ServiceMBeanSupport;
+import org.jboss.util.ServiceMBeanSupport;
 
 import org.jboss.proxy.Proxy;
 import org.jboss.proxy.Proxies;
@@ -309,7 +309,7 @@
 
     public PrintWriter getPrintWriter() {
         if (writer == null) {
-            writer = new CategoryWriter(log);
+            writer = new CategoryWriter(log.getCategory());
         }
         return writer;
     }
Index: CastorJDOImplMBean.java
===================================================================
RCS file:
/cvsroot/jboss/contrib/varia/src/main/org/jboss/jdo/castor/CastorJDOImplMBean.java,v
retrieving revision 1.2
diff -u -r1.2 CastorJDOImplMBean.java
--- CastorJDOImplMBean.java     2001/08/30 02:42:38     1.2
+++ CastorJDOImplMBean.java     2002/02/01 17:24:33
@@ -14,7 +14,7 @@
  *   @version $Revision: 1.2 $
  */
 public interface CastorJDOImplMBean
-       extends org.jboss.system.ServiceMBean
+       extends org.jboss.util.ServiceMBean
 {
     public static final String OBJECT_NAME = ":service=CastorJDO";
     
--- 8< ---

Here's a copy of the built jarfile:

        http://www.eifrem.com/files/java/jboss/jboss-castorjdo-2.4.4.jar

This procedure worked for me. YMMV.

-- 
Emil Eifrem [[EMAIL PROTECTED]]
Kernel Developer, .windh AB


_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to