[jboss-cvs] JBossCache/src/org/jboss/cache/marshall ...

Manik Surtani manik at jboss.org
Mon Apr 23 10:09:08 EDT 2007


  User: msurtani
  Date: 07/04/23 10:09:08

  Modified:    src/org/jboss/cache/marshall   
                        ObjectSerializationFactory.java
                        CacheMarshaller200.java
  Removed:     src/org/jboss/cache/marshall   
                        JBossObjectStreamFactory.java
  Log:
  Removed dependency on JBoss Serialization
  
  Revision  Changes    Path
  1.21      +10 -13    JBossCache/src/org/jboss/cache/marshall/ObjectSerializationFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ObjectSerializationFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/ObjectSerializationFactory.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- ObjectSerializationFactory.java	29 Jan 2007 17:40:35 -0000	1.20
  +++ ObjectSerializationFactory.java	23 Apr 2007 14:09:08 -0000	1.21
  @@ -6,17 +6,15 @@
    */
   package org.jboss.cache.marshall;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -
   import java.io.IOException;
  +import java.io.InputStream;
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
   import java.io.OutputStream;
  -import java.io.InputStream;
   
   /**
  - * Factory class for creating object output and inut streams, switching between JDK defaults and JBoss Serialization classes.
  + * Factory class for creating object output and inut streams, to allow for multiple mechanisms of serialization.
  + * Java serialization is the only supported mechanism at this point.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  @@ -24,10 +22,9 @@
    */
   public class ObjectSerializationFactory
   {
  -   static boolean useJBossSerialization = false;
  -   private static Log log = LogFactory.getLog(ObjectSerializationFactory.class);
      static ObjectStreamFactory factory = new JavaObjectStreamFactory();
   
  +   /*
      static
      {
         // start with the NEW property
  @@ -39,7 +36,7 @@
            if (propString != null)
               log.info("The system property 'serialization.jboss' is deprecated and may be removed from future releases.  Please use 'jboss.serialization' instead.");
         }      
  -      useJBossSerialization = true; // default.
  +      useJBossSerialization = false; // default.
         if (propString != null) useJBossSerialization = Boolean.valueOf(propString);
   
         try
  @@ -53,9 +50,9 @@
         {
            log.error("Unable to load JBossObjectStreamFactory.  Perhaps jboss-serialization jar not loaded?", e);
            log.error("Falling back to java serialization.");
  -
         }
      }
  +   */
   
      public static ObjectOutputStream createObjectOutputStream(OutputStream out) throws IOException
      {
  @@ -72,8 +69,8 @@
         return factory.createObjectInputStream(in);
      }
   
  -   public static boolean useJBossSerialization()
  -   {
  -      return useJBossSerialization;
  -   }
  +//   public static boolean useJBossSerialization()
  +//   {
  +//      return useJBossSerialization;
  +//   }
   }
  
  
  
  1.12      +1 -1      JBossCache/src/org/jboss/cache/marshall/CacheMarshaller200.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheMarshaller200.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/CacheMarshaller200.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- CacheMarshaller200.java	3 Apr 2007 00:43:52 -0000	1.11
  +++ CacheMarshaller200.java	23 Apr 2007 14:09:08 -0000	1.12
  @@ -378,7 +378,7 @@
            out.writeByte(MAGICNUMBER_GRAVITATERESULT);
            marshallGravitateResult((GravitateResult) o, out, refMap);
         }
  -      else if (o instanceof Serializable || ObjectSerializationFactory.useJBossSerialization())
  +      else if (o instanceof Serializable)
         {
            int refId = createReference(o, refMap);
            if (log.isTraceEnabled())
  
  
  



More information about the jboss-cvs-commits mailing list