David Coons

Greenhorn
+ Follow
since Feb 07, 2011
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by David Coons

Seeing your actual code would help, but this works for me.
13 years ago
This code works fine, except when it's finished executing, Tomcat's localhost.log contains multiple (10x-20x) copies of the line "Success" from line 23. The code is pretty much linear and line 23 is the only place anywhere where "Success" is printed, so I don't understand why the line is executed more than once, let alone dozens of times. Preceeding each "Success" line in the log is Feb 28, 2011 1:06:17 PM org.apache.catalina.core.StandardWrapperValve invoke (the timestamp is the same in each copy). The getID() method has been omitted from the code below. It just does a SQL query, returns a string, and contains no System.out.println statements.
13 years ago
I just figured out how 'static' works. This is a simple example I worked out to keep in my notes.
13 years ago
Thanks, Tim[0] and Tim[1] (you can arm-wrestle for the title of Tim[0]). This site is a goldmine for beginners. Thanks for the info about filters.

Late one night last week as I was thinking about this task, having worked on it for several days, I decided I was going about it the wrong way and created a separate webapp. It's easier than having to fit my code around someone else's.

Is oracle.jdbc.driver.OracleDriver or servletapi-2.4-20040521.jar the MS SQL driver?
13 years ago
I've added a <filter> and a <filter-mapping> to web.xml that turns a functioning Tomcat 6.0 system into one with severe startup errors in catalina.log. My first thought is that the errors are caused by the new filter using the same filter-class as an existing filter (since the other additions are just params). Are two filters with the same filter-class permissible in Tomcat?

The filter class that's used twice handles single-sign-on. All the current pages are behind SSO. I've added a JSP page that requests user input before redirecting to the app's normal startup page, and it needs to be behind SSO as well. The two filters are necessary (as far as I know) because the url-patterns are different.

Here's the portion of catalina.log that's generated when Tomcat starts:
14 years ago