svn commit: r409572 - /tomcat/connectors/trunk/jk/native/common/jk_global.h

2006-05-26 Thread rjung
Author: rjung
Date: Fri May 26 00:12:38 2006
New Revision: 409572

URL: http://svn.apache.org/viewvc?rev=409572view=rev
Log:
- Use previous types for WIN32
- Don't assume we have auto* on AS400

Modified:
tomcat/connectors/trunk/jk/native/common/jk_global.h

Modified: tomcat/connectors/trunk/jk/native/common/jk_global.h
URL: 
http://svn.apache.org/viewvc/tomcat/connectors/trunk/jk/native/common/jk_global.h?rev=409572r1=409571r2=409572view=diff
==
--- tomcat/connectors/trunk/jk/native/common/jk_global.h (original)
+++ tomcat/connectors/trunk/jk/native/common/jk_global.h Fri May 26 00:12:38 
2006
@@ -245,12 +245,19 @@
 /* jk_uint32_t defines a four byte word */
 /* jk_uint64_t defines a eight byte word */
 #if defined (WIN32)
-typedef UINT32 jk_uint32_t;
-#define JK_UINT32_T_FMT I32u
-#define JK_UINT32_T_HEX_FMT I32x
-typedef UINT64 jk_uint64_t;
+typedef unsigned int jk_uint32_t;
+#define JK_UINT32_T_FMT u
+#define JK_UINT32_T_HEX_FMT x
+typedef unsigned __int64 jk_uint64_t;
 #define JK_UINT64_T_FMT I64u
 #define JK_UINT64_T_HEX_FMT I64x
+#elif defined(AS400)
+typedef unsigned int jk_uint32_t;
+#define JK_UINT32_T_FMT u
+#define JK_UINT32_T_HEX_FMT x
+typedef unsigned long long jk_uint64_t;
+#define JK_UINT64_T_FMT llu
+#define JK_UINT64_T_HEX_FMT llx
 #else
 #include jk_types.h
 #endif



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 39663] - JasperException: File [TLD Name] not found with zero length context path

2006-05-26 Thread bugzilla
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=39663.
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=39663





--- Additional Comments From [EMAIL PROTECTED]  2006-05-26 09:24 ---
I'm experiencing the same issue with my application (MeshCMS). The taglib 
standard-fmt-rt does not work, while my custom taglib still works. I tested the 
app on both Windows (JDK 1.5 and 1.6) and Linux (JDK 1.5). The issue happens 
with all versions of Tomcat  5.5.12, which works fine instead. 

This is my test server.xml:

-
Server port=8005 shutdown=SHUTDOWN
  Service name=Catalina
Connector port=8080 /

Engine name=Catalina defaultHost=localhost
  Host name=localhost appBase=/home/tomcat/meshcms
Context path= docBase= debug=0 reloadable=false 
allowLinking=false /
  /Host
/Engine
  /Service
/Server
-



-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 39663] - JasperException: File [TLD Name] not found with zero length context path

2006-05-26 Thread bugzilla
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=39663.
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=39663





--- Additional Comments From [EMAIL PROTECTED]  2006-05-26 12:32 ---
Some further considerations:

Tomcat reports
26-mag-2006 12.14.00 org.apache.jasper.compiler.TldLocationsCache 
processWebDotXml
AVVERTENZA: Internal Error: File /WEB-INF/web.xml not found

The org.apache.jasper.compiler.TldLocationsCache.processWebDotXml() has changed 
a lot between 5.5.12 and 5.5.16. Maybe going back to the old method could solve 
this issue.

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 10527] - SSL socket error shuts down access to HTTPS pages

2006-05-26 Thread bugzilla
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=10527.
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=10527





--- Additional Comments From [EMAIL PROTECTED]  2006-05-26 13:16 ---
Created an attachment (id=18354)
 -- (http://issues.apache.org/bugzilla/attachment.cgi?id=18354action=view)
Tomcat thread hung on handshake

Server.xml 
Connector className=org.apache.coyote.tomcat4.CoyoteConnector port=8443
minProcessors=5 maxProcessors=75 enableLookups=true acceptCount=100
debug=0 scheme=https secure=true useURIValidationHack=false
disableUploadTimeout=true
Factory
className=org.apache.coyote.tomcat4.CoyoteServerSocketFactory
clientAuth=false
keystoreFile=/omcsw/27.0.2.8.00/lib/3pt/bes/var/domains/base/configurations/EMF/mos/presentation/Client_iEMS/appl/iemsKeystore
keystorePass=lucent protocol=TLS/
/Connector

We found that this is happening in our setup here. All the connections were
fine and then after some time the tomcat was slow in responding and then it
stopped responding. We believe it is because our maxProcessors was set to 75
and we can see there were 74 threads on handshake running. So we understand the
server slowness could be of high number of threads but what we do not
understand is why the threads are performing socket read and why there is no
time out. 

If it is not a tomcat problem any clue on what client configuration could be
wrong will be helpful.

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 35709] - allow to create a short-lived secondary session from a request to prevent cross-site scripting-like attacks

2006-05-26 Thread bugzilla
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=35709.
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=35709





--- Additional Comments From [EMAIL PROTECTED]  2006-05-26 14:09 ---
MSIE sometimes even ignores the mime-type we send it, but looks at the content.
So an attacker could hide a cross-site script in e.g. a jpg image.

http://msdn.microsoft.com/library/default.asp?url=/workshop/networking/moniker/overview/appendix_a.asp

-- 
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r409695 - in /tomcat/tc6.0.x/trunk/java/org/apache/catalina: startup/WebAnnotationSet.java util/AnnotationProcessor.java

2006-05-26 Thread remm
Author: remm
Date: Fri May 26 09:38:24 2006
New Revision: 409695

URL: http://svn.apache.org/viewvc?rev=409695view=rev
Log:
- Fix some bugs with annotation support.

Modified:
tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
tomcat/tc6.0.x/trunk/java/org/apache/catalina/util/AnnotationProcessor.java

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java?rev=409695r1=409694r2=409695view=diff
==
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/WebAnnotationSet.java 
Fri May 26 09:38:24 2006
@@ -99,6 +99,10 @@
 if (children[i] instanceof StandardWrapper) {
 
 wrapper = (StandardWrapper) children[i];
+if (wrapper.getServletClass() == null) {
+continue;
+}
+
 try {
 classClass = 
classLoader.loadClass(wrapper.getServletClass());
 } catch (ClassNotFoundException e) {

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/catalina/util/AnnotationProcessor.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/util/AnnotationProcessor.java?rev=409695r1=409694r2=409695view=diff
==
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/util/AnnotationProcessor.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/util/AnnotationProcessor.java 
Fri May 26 09:38:24 2006
@@ -30,8 +30,6 @@
 import javax.persistence.PersistenceUnit;
 import javax.xml.ws.WebServiceRef;
 
-import org.apache.tomcat.util.IntrospectionUtils;
-
 
 /**
  * Verify the annotation and Process it.
@@ -49,7 +47,7 @@
 public static void postConstruct(Object instance)
 throws IllegalAccessException, InvocationTargetException {
 
-Method[] methods = IntrospectionUtils.findMethods(instance.getClass());
+Method[] methods = instance.getClass().getDeclaredMethods();
 Method postConstruct = null;
 for (int i = 0; i  methods.length; i++) {
 if (methods[i].isAnnotationPresent(PostConstruct.class)) {
@@ -82,7 +80,7 @@
 public static void preDestroy(Object instance)
 throws IllegalAccessException, InvocationTargetException {
 
-Method[] methods = IntrospectionUtils.findMethods(instance.getClass());
+Method[] methods = instance.getClass().getDeclaredMethods();
 Method preDestroy = null;
 for (int i = 0; i  methods.length; i++) {
 if (methods[i].isAnnotationPresent(PreDestroy.class)) {
@@ -116,7 +114,7 @@
 throws IllegalAccessException, InvocationTargetException, 
NamingException {
 
 // Initialize fields annotations
-Field[] fields = instance.getClass().getFields();
+Field[] fields = instance.getClass().getDeclaredFields();
 for (int i = 0; i  fields.length; i++) {
 if (fields[i].isAnnotationPresent(Resource.class)) {
 Resource annotation = (Resource) 
fields[i].getAnnotation(Resource.class);
@@ -144,7 +142,7 @@
 }
 
 // Initialize methods annotations
-Method[] methods = IntrospectionUtils.findMethods(instance.getClass());
+Method[] methods = instance.getClass().getDeclaredMethods();
 for (int i = 0; i  methods.length; i++) {
 if (methods[i].isAnnotationPresent(Resource.class)) {
 Resource annotation = (Resource) 
methods[i].getAnnotation(Resource.class);



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r409696 - in /tomcat/tc6.0.x/trunk/java/org/apache/catalina: connector/CoyoteAdapter.java servlets/CometServlet.java

2006-05-26 Thread remm
Author: remm
Date: Fri May 26 09:39:08 2006
New Revision: 409696

URL: http://svn.apache.org/viewvc?rev=409696view=rev
Log:
- Some small comet fixes.

Modified:
tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
tomcat/tc6.0.x/trunk/java/org/apache/catalina/servlets/CometServlet.java

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java?rev=409696r1=409695r2=409696view=diff
==
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java 
Fri May 26 09:39:08 2006
@@ -116,12 +116,22 @@
 Response response = (Response) res.getNote(ADAPTER_NOTES);
 
 if (request.getWrapper() != null) {
+
+// Bind the context CL to the current thread
+if (request.getContext().getLoader() != null ) {
+Thread.currentThread().setContextClassLoader
+(request.getContext().getLoader().getClassLoader());
+}
+
 CometProcessor servlet = null;
 try {
 servlet = (CometProcessor) request.getWrapper().allocate();
 } catch (Throwable t) {
 log.error(sm.getString(coyoteAdapter.service), t);
 request.removeAttribute(org.apache.tomcat.comet);
+// Restore the context classloader
+Thread.currentThread().setContextClassLoader
+(CoyoteAdapter.class.getClassLoader());
 return false;
 }
 try {
@@ -156,6 +166,9 @@
 request.recycle();
 response.recycle();
 }
+// Restore the context classloader
+Thread.currentThread().setContextClassLoader
+(CoyoteAdapter.class.getClassLoader());
 }
 }
 return true;

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/catalina/servlets/CometServlet.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/catalina/servlets/CometServlet.java?rev=409696r1=409695r2=409696view=diff
==
--- tomcat/tc6.0.x/trunk/java/org/apache/catalina/servlets/CometServlet.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/catalina/servlets/CometServlet.java 
Fri May 26 09:39:08 2006
@@ -71,12 +71,20 @@
 if (request.getAttribute(org.apache.tomcat.comet.support) == 
Boolean.TRUE) {
 begin(request, response);
 } else {
-// FIXME: Implement without comet support
+// No Comet support: regular servlet handling
 begin(request, response);
-
-// Loop reading data
-
-end(request, response);
+boolean error = true;
+try {
+// Loop reading data
+while (read(request, response));
+error = false;
+} finally {
+if (error) {
+error(request, response);
+} else {
+end(request, response);
+}
+}
 }
 
 }



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



svn commit: r409799 - in /tomcat/container/tc5.5.x/modules/groupcom: doc/introduction.xml src/share/org/apache/catalina/tribes/group/GroupChannel.java to-do.txt

2006-05-26 Thread fhanik
Author: fhanik
Date: Fri May 26 19:32:21 2006
New Revision: 409799

URL: http://svn.apache.org/viewvc?rev=409799view=rev
Log:
Absence reply should be sent if the message was not by an RPC channel

Modified:
tomcat/container/tc5.5.x/modules/groupcom/doc/introduction.xml

tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/tribes/group/GroupChannel.java
tomcat/container/tc5.5.x/modules/groupcom/to-do.txt

Modified: tomcat/container/tc5.5.x/modules/groupcom/doc/introduction.xml
URL: 
http://svn.apache.org/viewvc/tomcat/container/tc5.5.x/modules/groupcom/doc/introduction.xml?rev=409799r1=409798r2=409799view=diff
==
--- tomcat/container/tc5.5.x/modules/groupcom/doc/introduction.xml (original)
+++ tomcat/container/tc5.5.x/modules/groupcom/doc/introduction.xml Fri May 26 
19:32:21 2006
@@ -31,33 +31,33 @@
   source
 //create a channel
 Channel myChannel = new GroupChannel();
-
+
 //create my listeners
-MyMessageListener msgListener = new MyMessageListener();
-MyMemberListener mbrListener = new MyMemberListener();
-
+ChannelListener msgListener = new MyMessageListener();
+MembershipListener mbrListener = new MyMemberListener();
+
 //attach the listeners to the channel
 myChannel.addMembershipListener(mbrListener);
 myChannel.addChannelListener(msgListener);
-
+
 //start the channel
 myChannel.start(Channel.DEFAULT);
-
+
 //create a message to be sent, message must implement 
java.io.Serializable
 //for performance reasons you probably want them to implement 
java.io.Externalizable
 Serializable myMsg = new MyMessage();
 
 //retrieve my current members
 Member[] group = myChannel.getMembers();
-
+
 //send the message
 channel.send(group,myMsg,Channel.SEND_OPTIONS_DEFAULT);
   /source
 /li
   /ul
   p
-  Simple yeah? There is a lot more to Tribes than we have shown, hopefully 
the docs will be able 
-  to explain more to you. Remember, that we are always interested in 
suggestions, improvements, bug fixes 
+  Simple yeah? There is a lot more to Tribes than we have shown, hopefully 
the docs will be able
+  to explain more to you. Remember, that we are always interested in 
suggestions, improvements, bug fixes
   and anything that you think would help this project.
   /p
   p
@@ -70,20 +70,20 @@
   p
 Tribes is a messaging framework with group communication abilities. Tribes 
allows you to send and receive
 messages over a network, it also allows for dynamic discovery of other 
nodes in the network.br/
-And that is the short story, it really is as simple as that. What makes 
Tribes useful and unique will be 
+And that is the short story, it really is as simple as that. What makes 
Tribes useful and unique will be
 described in the section below.br/
   /p
   p
-The Tribes module was started early 2006 and a small part of the code base 
comes from the clustering module 
-that has been existing since 2003 or 2004. 
-The current cluster implementation has several short comings and many work 
arounds were created due 
+The Tribes module was started early 2006 and a small part of the code base 
comes from the clustering module
+that has been existing since 2003 or 2004.
+The current cluster implementation has several short comings and many work 
arounds were created due
 to the complexity in group communication. Long story short, what should 
have been two modules a long time
-ago, will be now. Tribes takes out the complexity of messaging from the 
replication module and becomes 
+ago, will be now. Tribes takes out the complexity of messaging from the 
replication module and becomes
 a fully independent and highly flexible group communication module.br/
   /p
   p
 In Tomcat the old codemodules/cluster/code has now become 
codemodules/groupcom/code(Tribes) and
-codemodules/ha/code (replication). This will allow development to 
proceed and let the developers 
+codemodules/ha/code (replication). This will allow development to 
proceed and let the developers
 focus on the issues they are actually working on rather than getting 
boggled down in details of a module
 they are not interested in. The understanding is that both communication 
and replication are complex enough,
 and when trying to develop them in the same module, well you know, it 
becomes a cluster :)br/
@@ -92,14 +92,14 @@
 Tribes allows for guaranteed messaging, and can be customized in many 
ways. Why is this important?br/
 Well, you as a developer want to know that the messages you are sending 
are reaching their destination.
 More than that, if a message doesn't reach its destination, the 
application on top of Tribes will be notified
-