tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 36113] - Session persistence for objects with primitive types
Date Thu, 08 Sep 2005 13:30:27 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=36113>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=36113





------- Additional Comments From marcus.haarmann@midoco.de  2005-09-08 15:30 -------
Hi, I tried your code and it works correctly for session persistence in my case.
Although my approch would be faster (because only one exception is caught until 
the result is returned in case of a primitive type), I agree to better not cut 
and paste code (this is object orientated programming, isn't it ?).
Keep in mind to also change the ReplicationStream class in clustering.
Something like:
public Class resolveClass(ObjectStreamClass classDesc)
        throws ClassNotFoundException, IOException {
        String name = classDesc.getName();
        boolean tryRepFirst = name.startsWith("org.apache.catalina.cluster");
        try {
          try
          {
            if ( tryRepFirst ) return findReplicationClass(name);
            else return findWebappClass(name);
          }
          catch ( Exception x )
          {
            if ( tryRepFirst ) return findWebappClass(name);
            else return findReplicationClass(name);
          }
        }
        catch (ClassNotFoundException e)
        {
          return super.resolveClass (classDesc);
        }
    }
     
Thanks, Marcus

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message