Return-Path: Delivered-To: apmail-jakarta-tomcat-dev-archive@apache.org Received: (qmail 26483 invoked from network); 8 Aug 2002 16:46:21 -0000 Received: from unknown (HELO nagoya.betaversion.org) (192.18.49.131) by daedalus.apache.org with SMTP; 8 Aug 2002 16:46:21 -0000 Received: (qmail 9620 invoked by uid 97); 8 Aug 2002 16:46:32 -0000 Delivered-To: qmlist-jakarta-archive-tomcat-dev@jakarta.apache.org Received: (qmail 9354 invoked by uid 97); 8 Aug 2002 16:46:28 -0000 Mailing-List: contact tomcat-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Tomcat Developers List" Reply-To: "Tomcat Developers List" Delivered-To: mailing list tomcat-dev@jakarta.apache.org Received: (qmail 9148 invoked by uid 98); 8 Aug 2002 16:46:26 -0000 X-Antivirus: nagoya (v4198 created Apr 24 2002) Message-ID: <3D52A02C.B4787E68@asu.edu> Date: Thu, 08 Aug 2002 09:45:32 -0700 From: Harry Koehnemann X-Mailer: Mozilla 4.77 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: tomcat-dev@jakarta.apache.org Subject: NullPointerException in StandardSession w/ Tomcat 4.1.8 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Hi all, I'm not sure if this is a developer question. But, I tried this question on Tomcat user and didn't receive any responses. Any help is appreciated. Thanks. -------- Original Message -------- Subject: NullPointerException in StandardSession w/ Tomcat 4.1.8 Date: Tue, 06 Aug 2002 17:02:22 -0700 From: Harry Koehnemann Reply-To: Tomcat Users List To: tomcat-user@jakarta.apache.org Hi, I'm in need of scaling a webapp in Tomcat to multiple boxes and need to solve the shared servlet session problem. We wrote an RMI-based session server 4 years ago and it's been heavily utilized with several servet engines hitting it. There is an internal push to keep it as it's been very reliable at managing and reaping sessions and scale. I've written a little adapter that extends ManagerBase and overloads interesting methods to read and write sessions to that existing server. CreateSession() and addSession() appear to work fine but the first servlet to call findSession() generates this exception. java.lang.NullPointerException at org.apache.catalina.session.StandardSession.setAttribute(StandardSession.java:1268) at org.apache.catalina.session.StandardSessionFacade.setAttribute(StandardSessionFacade.java:191) at org.apache.catalina.session.StandardSessionFacade.setAttribute(StandardSessionFacade.java:191) at Session1.doGet(Unknown Source) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) Looking at CVS, StandardSession.java:1268 is Context context = (Context) manager.getContainer(); I notice manager is not transient and think that may be my problem. I'm not sure that StandardSession objects can be serialized then brought back into the container as I'm attempting. Can they? If so, any pointers on what I might be doing wrong? Also, I see Tomcat ships with a session manager that appears to share sessions using a multicast socket. I assume this manager broadcast all session changes to all other engines. Does anyone have performance stats on how much work it is for the engine to receive these sessions as a site scales. It seems that adding more servlet engines causes more work for the servlet engines using this scheme. Regards, Harry. -- To unsubscribe, e-mail: For additional commands, e-mail: