DO NOT REPLY [Bug 47292] New: Attributes are lost in newly created DeltaSession

2009-05-31 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=47292

   Summary: Attributes are lost in newly created DeltaSession
   Product: Tomcat 6
   Version: unspecified
  Platform: PC
OS/Version: Linux
Status: NEW
  Keywords: PatchAvailable
  Severity: critical
  Priority: P2
 Component: Cluster
AssignedTo: dev@tomcat.apache.org
ReportedBy: martin.su...@nam.cz


It seems SessionMessages spread in multicast are processed by all nodes
including sender.

Problem timing:
1) http request received
2) session is created
3) session_created message sent
4) attribute added into session
5) session_created received back
6) new session createde with same session_id and stored into sessions map
replacing original session with attributes
7) http request is done
8) deltarequest sent but for empty session from step 6

My quick fix:

/**
 * handle receive new session is created at other node (create backup -
primary false)
 * @param msg
 * @param sender
 */
protected void handleSESSION_CREATED(SessionMessage msg,Member sender) {
// Bug fix begin
if (sessions.containsKey(msg.getSessionID())) {
log.debug("Rejected session_created with duplicit id");
return;
}
// Bug fix end

counterReceive_EVT_SESSION_CREATED++;
if (log.isDebugEnabled())
log.debug(sm.getString("deltaManager.receiveMessage.createNewSession",getName(),
msg.getSessionID()));
DeltaSession session = (DeltaSession) createEmptySession();
session.setManager(this);
session.setValid(true);
session.setPrimarySession(false);
session.setCreationTime(msg.getTimestamp());
// use container maxInactiveInterval so that session will expire
correctly in case of primary transfer
session.setMaxInactiveInterval(getMaxInactiveInterval());
session.access();
if(notifySessionListenersOnReplication)
session.setId(msg.getSessionID());
else
session.setIdInternal(msg.getSessionID());
session.resetDeltaRequest();
session.endAccess();
}

My suggested fixes:

1) in sender node drop SessionMessage sent back by network layer
Check worker id in SessionMessage, which is part of session_id.

2) replace SESSION_CREATED functionality by DeltaRequest.
If SessionMessage with DeltaRequest is received with unknown session_id, create
new session.

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

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



DO NOT REPLY [Bug 47292] Attributes are lost in newly created DeltaSession

2009-05-31 Thread bugzilla
https://issues.apache.org/bugzilla/show_bug.cgi?id=47292





--- Comment #1 from Martin Sulak   2009-05-31 23:01:31 PST 
---
Sorry, I forgot to mention : the handleSESSION_CREATED method I modified is
located in class org.apache.catalina.ha.session.DeltaManager.

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

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



Bug report for Tomcat 6 [2009/05/31]

2009-05-31 Thread bugzilla
+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=Critical  REG=Regression  MAJ=Major   |
| |   |   MIN=Minor   NOR=NormalENH=Enhancement TRV=Trivial |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
|39661|Opn|Enh|2006-05-25|Please document JULI FileHandler configuration pro|
|41093|Ver|Enh|2006-11-30|publish 6.0.2 beta jars in a maven repository |
|41128|Inf|Enh|2006-12-07|Reference to java Thread name from RequestProcesso|
|41530|Ver|Nor|2007-02-02|stopping a connector produces intermittent SocketE|
|41679|Ass|Enh|2007-02-22|SemaphoreValve should be able to filter on url pat|
|41791|New|Enh|2007-03-07|Tomcat behaves inconsistently concerning flush-pac|
|41797|Ver|Maj|2007-03-09|CNFE/NPE thrown from function mapper when external|
|41883|Ass|Enh|2007-03-18|use abstract wrapper instead of plain X509Certific|
|41944|New|Enh|2007-03-25|Start running the RAT tool to see where we're miss|
|41992|New|Enh|2007-03-30|Need ability to set OS process title  |
|42463|New|Enh|2007-05-20|"crossContext" and classloader issues - pls amend |
|42996|Opn|Nor|2007-07-29|POST with nio connector results in missing variabl|
|43001|New|Enh|2007-07-30|JspC lacks setMappedFile and setDie for use in Ant|
|43003|New|Enh|2007-07-30|Separate dependent component download and build ta|
|43154|New|Enh|2007-08-17|forward port from 5.5.x to 6.x about AccessLogValv|
|43343|Opn|Nor|2007-09-10|Loss of data and concurrency issue with Catalina s|
|43400|New|Enh|2007-09-14|enum support for tag libs |
|43497|New|Enh|2007-09-26|Add ability to escape rendered output of JSP expre|
|43548|New|Enh|2007-10-04|xml schema for tomcat-users.xml   |
|43642|New|Enh|2007-10-17|Add prestartminSpareThreads attribute for Executor|
|43682|New|Enh|2007-10-23|JULI: web-inf/classes/logging.properties to suppor|
|43742|New|Enh|2007-10-30|.tag compiles  performed one at a time -- extremel|
|43790|Ass|Enh|2007-11-03|concurrent access issue on TagHandlerPool |
|43979|New|Enh|2007-11-27|Add abstraction for Java and Classfile output |
|44047|New|Enh|2007-12-10|Provide a way for Tomcat to serve up error pages w|
|44106|New|Enh|2007-12-19|autodeploy configures directories which do not con|
|44199|New|Enh|2008-01-10|expose current backlog queue size |
|44225|New|Enh|2008-01-14|SSL connector tries to load the private keystore f|
|44264|New|Enh|2008-01-18|Clustering - Support for disabling multicasting an|
|44265|New|Enh|2008-01-18|Improve JspWriterImpl performance with "inline" su|
|44284|New|Enh|2008-01-23|Support java.lang.Iterable in c:forEach tag   |
|44294|New|Enh|2008-01-25|Support for EL functions with varargs |
|44299|New|Enh|2008-01-26|Provider manager app with a log out button|
|44312|New|Enh|2008-01-28|Warn when overwritting docBase of the default Host|
|44409|New|Enh|2008-02-13|Tomcat does not support Windows-My Provider   |
|44598|New|Enh|2008-03-13|JAASRealm is suppressing Exceptions   |
|44645|New|Enh|2008-03-20|[Patch] JNDIRealm - Doesn't support JNDI "java.nam|
|44787|New|Enh|2008-04-09|provide more error context on "java.lang.IllegalSt|
|44818|New|Enh|2008-04-13|tomcat hangs with GET when content-length is defin|
|45014|New|Enh|2008-05-15|Request and Response classes should have wrappers |
|45255|New|Enh|2008-06-23|support disable jsessionid from url against sessio|
|45282|New|Enh|2008-06-25|NioReceiver doesn't close cleanly, leaving sockets|
|45283|Opn|Enh|2008-06-25|Allow multiple authenticators to be added to pipel|
|45403|New|Nor|2008-07-15|Tomcat does not reload application|
|45428|New|Enh|2008-07-18|warn if the tomcat stop doesn't complete  |
|45654|New|Enh|2008-08-19|use static methods and attributes in a direct way!|
|45731|New|Enh|2008-09-02|Enhancement request : pluggable httpsession cache |
|45794|New|Enh|2008-09-12|Patch causes JNDIRealm to bind with user entered c|
|45832|New|Enh|2008-09-18|add DIGEST authentication support to Ant tasks|
|45871|New|Enh|2008-09-23|Support for salted and digested patches in DataSou|
|45878|New|Enh|2008-09-24|Generated jars do not contain proper manifests or |
|45879|

Bug report for Tomcat 4 [2009/05/31]

2009-05-31 Thread bugzilla
+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=Critical  REG=Regression  MAJ=Major   |
| |   |   MIN=Minor   NOR=NormalENH=Enhancement TRV=Trivial |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
| 3839|Opn|Enh|2001-09-26|Problem bookmarking login page|
| 4227|Opn|Enh|2001-10-17|Invalid CGI path  |
| 5329|New|Enh|2001-12-08|NT Service exits startup before Tomcat is finished|
| 5795|New|Enh|2002-01-10|Catalina Shutdown relies on localhost causing prob|
| 5829|New|Enh|2002-01-13|StandardManager needs to cope with sessions throwi|
| 5985|New|Enh|2002-01-23|Tomcat should perform a more restrictive validatio|
| 6600|Opn|Enh|2002-02-20|enodeURL adds 'jsession' when 'isRequestedSessionI|
| 6614|New|Enh|2002-02-21|Have Bootstrap and StandardClassLoader use the sam|
| 6671|New|Enh|2002-02-25|Simple custom tag example uses old declaration sty|
| 7043|New|Enh|2002-03-12|database user and password for JDBC Based Store   |
| 7374|New|Enh|2002-03-22|Apache Tomcat/4.0.1 message on standard output|
| 7676|New|Enh|2002-04-02|Allow name property to use match experssions in  without className in server.xml produces N|
|11129|New|Enh|2002-07-24|New valve for putting the sessionIDs in the reques|
|11248|New|Enh|2002-07-29|DefaultServlet doesn't send expires header|
|11754|Opn|Enh|2002-08-15|Synchronous shutdown script - shutdown.sh should w|
|12069|New|Enh|2002-08-27|Creation of more HttpSession objects for one previ|
|12428|Opn|Enh|2002-09-09|request.getUserPrincipal(): Misinterpretation of s|
|12658|New|Enh|2002-09-15|a proxy host and port at the  element level |
|12766|New|Enh|2002-09-18|Tomcat should use tld files in /WEB-INF/ over vers|
|13309|Opn|Enh|2002-10-04|Catalina calls System.exit()  |
|13634|New|Enh|2002-10-15|Allowing system properties to be substituted in co|
|13689|Opn|Enh|2002-10-16|Classloader paths for 'Common' classes and librari|
|13731|New|Enh|2002-10-17|Final request, response, session and other variabl|
|13941|New|Enh|2002-10-24|reload is VERY slow   |
|13965|New|Enh|2002-10-25|Catalina.sh correction request for Tru64 Unix |
|14097|New|Enh|2002-10-30|hardcoded registry value for vm lets tomcat servic|
|14416|New|Enh|2002-11-10|blank tag name in TLD cause NullPointerException  |
|14635|New|Enh|2002-11-18|Should be possible not to have -MM-DD in log f|
|14766|New|Enh|2002-11-22|Redirect Vavle|
|14993|New|Enh|2002-12-02|Possible obselete synchronized declaration|
|15115|New|Enh|2002-12-05|correct docs... XML parser *cannot* be overridden |
|15417|Opn|Enh|2002-12-16|Add port for forced compilation of JSP pages  |
|15688|New|Enh|2002-12-27|full-qualified names instead of imports   |
|15941|New|Enh|2003-01-10|Expose rootCause exceptions at deeper levels  |
|16294|New|Enh|2003-01-21|Configurable URL Decoding.|
|16357|New|Enh|2003-01-23|"connection timeout reached"  |
|16531|New|Enh|2003-01-29|Updating already deployed ".war" files in a single|
|16579|New|Enh|2003-01-30|documentation page layout/style breaks wrapping to|
|16596|New|Enh|2003-01-30|option for disabling log rotation |
|17070|New|Enh|2003-02-14|The Catalina Ant tasks do not allow for 'reusable'|
|17146|New|Enh|2003-02-18|Simplify build.xml using 

Bug report for Tomcat 5 [2009/05/31]

2009-05-31 Thread bugzilla
+---+
| Bugzilla Bug ID   |
| +-+
| | Status: UNC=Unconfirmed NEW=New ASS=Assigned|
| | OPN=ReopenedVER=Verified(Skipped Closed/Resolved)   |
| |   +-+
| |   | Severity: BLK=Blocker CRI=Critical  REG=Regression  MAJ=Major   |
| |   |   MIN=Minor   NOR=NormalENH=Enhancement TRV=Trivial |
| |   |   +-+
| |   |   | Date Posted |
| |   |   |  +--+
| |   |   |  | Description  |
| |   |   |  |  |
|27122|Opn|Enh|2004-02-20|IE plugins cannot access components through Tomcat|
|28039|Opn|Enh|2004-03-30|Cluster Support for SingleSignOn  |
|29160|Ver|Enh|2004-05-23|precompile problem: _jspx_meth_* (javax.servlet.js|
|29494|Inf|Enh|2004-06-10|No way to set PATH when running as a service on Wi|
|30241|Ver|Enh|2004-07-21|Enhance build script to use branch argument when c|
|33262|Inf|Enh|2005-01-27|Service Manager autostart should check for adminis|
|33453|Opn|Enh|2005-02-08|Jasper should recompile JSP files whose datestamps|
|33671|Opn|Enh|2005-02-21|Manual Windows service installation with custom na|
|34110|Opn|Nor|2005-03-21|The message "SEVERE: Error listenerStart" should b|
|34801|New|Enh|2005-05-08|PATCH: CGIServlet does not terminate child after a|
|34805|Ass|Enh|2005-05-08|warn about invalid security constraint url pattern|
|34868|Ass|Enh|2005-05-11|allow to register a trust store for a session that|
|35054|Inf|Enh|2005-05-25|warn if appBase is not existing as a File or direc|
|36133|Inf|Enh|2005-08-10|Support JSS SSL implementation|
|36362|New|Enh|2005-08-25|missing check for Java reserved keywords in tag fi|
|36569|Inf|Enh|2005-09-09|Redirects produce illegal URL's   |
|36837|Inf|Enh|2005-09-28|Looking for ProxyHandler implementation of Http re|
|36922|Inf|Enh|2005-10-04|setup.sh file mis-advertised and missing  |
|36923|New|Nor|2005-10-05|Deactivated EL expressions are not parsed for jsp |
|37018|Ass|Enh|2005-10-11|Document how to use tomcat-SSL with a pkcs11 token|
|37084|Ass|Nor|2005-10-14|JspC from ant fails on JSPs that use custom taglib|
|37334|Inf|Enh|2005-11-02|Realm digest property not aligned with the adminis|
|37449|Opn|Enh|2005-11-10|Two UserDatabaseRealm break manager user  |
|37458|Ass|Nor|2005-11-10|Datarace on org.apache.catalina.loader.WebappClass|
|37485|Inf|Enh|2005-11-14|I'd like to run init SQL after JDBC Connection cre|
|37498|New|Nor|2005-11-14|[PATCH] NPE in org.apache.catalina.core.ContainerB|
|37515|Opn|Nor|2005-11-15|smap not generated by JspC when used from Ant for |
|37627|Inf|Nor|2005-11-24|Slow and incomplete dynamic content generation aft|
|37785|Inf|Nor|2005-12-05|Changing startup type via Tomcat Monitor does not |
|37794|Opn|Nor|2005-12-05|getParameter() fails on POST with transfer-encodin|
|37797|Inf|Maj|2005-12-05|Configure Tomcat utility truncates classpath to 96|
|37847|Ass|Enh|2005-12-09|Allow User To Optionally Specify Catalina Output F|
|37869|Opn|Nor|2005-12-12|Cannot obtain client certificate with SSL / client|
|37984|New|Nor|2005-12-21|JNDIRealm.java not able to handle MD5 password|
|38197|Opn|Maj|2006-01-09|taglib pool bug when tag is used with jsp:attribut|
|38216|Inf|Enh|2006-01-10|Extend Jmxproxy to allow call of MBean Operations |
|38217|Ver|Enh|2006-01-10|mention that private key password and keystore pas|
|38268|Inf|Enh|2006-01-13|User friendly: Need submit button on adding/deleti|
|38352|Inf|Nor|2006-01-22|Additional Entries for Default catalina.policy fil|
|38360|Inf|Enh|2006-01-24|Domain for session cookies|
|38483|New|Nor|2006-02-01|access log valve uses simpledateformat in tread-un|
|38516|Inf|Nor|2006-02-05|Configuration Manager loses "Log On" settings |
|38546|Inf|Enh|2006-02-07|Google bot sends invalid If-Modifed-Since Header, |
|38553|New|Nor|2006-02-07|Wrong HTTP code for failed CLIENT-CERT authenticat|
|38570|New|Nor|2006-02-08|if docBase path contains "webapps", a backslash is|
|38577|Inf|Enh|2006-02-08|Enhance logging of security failures  |
|38630|Inf|Maj|2006-02-13|Environment (java:comp/env/) sometimes not availab|
|38713|Ass|Nor|2006-02-20|java.io.IOException: tmpFile.renameTo(classFile) f|
|38743|New|Min|2006-02-21|when using APR, JKS options are silently ignored  |
|38797|Opn|Nor|2006-02-27|5.5.12 and 5.5.15 emit different code on  |
|41007|Opn|Enh|2006-11-20|Can't define customized 503 error page|
|41059|Ass|Maj|