RE: OT: Is it ok to close connection in finalize() ?

2003-02-22 Thread Jacob Hookom
GC'ing is done in parallel now... as far as I know, it won't halt all
threads... it's not as bad with the new JVM's.

| -Original Message-
| From: Warden, Matt [mailto:[EMAIL PROTECTED]
| Sent: Saturday, February 22, 2003 3:02 AM
| To: Tomcat Users List
| Subject: RE: OT: Is it ok to close connection in finalize() ?
| 
| On Feb 20, Mike Jackson had something to say about RE: OT: Is it ok to...
| 
| >> finalize() is indeed guaranteed to run upon garbage collection, which
| in
| >> turn is guaranteed to happen.  However, garbage collection can
| >> happen at any
| >> time, so the connection may not be closed immediately.  If this
| >> is an issue
| >> for you, you can call System.gc() to force it to garbage collect
| >> immediately.
| >
| >True, but the garbage collector doesn't have to collect everything.  So
| even
| >if you call it directly you can't count on it collecting some or all of
| the
| >available object.
| 
| That's not the half of it. Garbage collection requires that all running
| threads (except its own) are halted. In other words, not only does it
| stall the execution of your method for a couple seconds, but it also
| stalls the execution of ALL executing java code running on that VM
| instance. You can imagine what that does to performance.
| 
| This is why you want to avoid unnecessary object creation (like using
| Integer wrapper for nothing else but holding an int). This is also why you
| want to keep objects in as small scope as possible (within reason --
| there's no need to localize each section of code with { and }
| unnecessarily) -- to ensure that garbage collection, when it does run, can
| collect as much as possible. e.g. pass in a long representing the date and
| create the date object (new Date(long)) within the method, when
| possible. This usually means duplicate code (i.e. public void
| mymethod(long time), public void mymethod(Date date)), so that's something
| to consider.
| 
| Anyways, bottom line:
| System.gc() is almost always a bad idea.
| 
| One exception might be a "garbage collect" feature in an IDE written in
| java. There aren't many more.
| 
| See the following article by JavaWorld (reproduced on IBM's website):
| http://www-106.ibm.com/developerworks/java/library/j-jw-performance.html
| 
| 
| --
| mattwarden
| mattwarden.com
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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



RE: Is it ok to close connection in finalize() ?

2003-02-20 Thread Jacob Hookom
You shouldn't put anything in your finalize() method, it's a bad practice
because it can cause issues with the jvm's gc.

In your case, you should implement connection and treat the connection just
like normal with JDBC access.  In your own connection, keep a reference to
your connection cache and then when you call connection.close(), it should
call a method to return itself to the connection cache, or it's internal
"actual" connection.

-Jacob



| -Original Message-
| From: Rosdi bin Kasim [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, February 20, 2003 10:13 PM
| To: Tomcat Users List
| Subject: OT: Is it ok to close connection in finalize() ?
| 
| This is a bit off topic.
| 
| I am using connection pooling, and in my code, I open all the connection I
| need in an object constructor.
| Then I will close this connection in finalize(), which (according to what
| I
| read) will be executed during java garbage collect.
| 
| --- sample code --
| 
| public class GeneralConn {
| 
|private ConnCache connCache;
| 
|//open connection during object creation
|public GeneralConn () {
|try {
|   connCache = ConnCache.getInstance();
|   dbConn= connCache.getConnection();  //grab a connection from
| the connection pool
|}catch (Exception e) {
|   System.out.println("Fail to open connection: " +
| e.getMessage());
|}
| }
| 
| //close when this object is destroyed
| public void finalize () {
| try{
| dbConn.close();
| dbConn = null;
|   }catch (Exception e) {
|   System.out.println("Fail to close connection: " +
| e.getMessage());
|   }
| }
| }
| 
| Would this be okay? is it guaranteed that finalize() will be executed
| during
| garbage collect??
| 
| 
| Regards,
| Rosdi bin Kasim.
| 
| 
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: JVM Question

2003-02-14 Thread Jacob Hookom
I'm wondering also, I posted the same question a few months ago.  I did some
testing on my own and found Sun's 1.4 to be slightly faster, but that was
only with a few concurrent users.  I would imagine JRocket would provide
better performance with a few hundred users.

-Jacob

| -Original Message-
| From: Anecito, Anthony (HQP) [mailto:[EMAIL PROTECTED]]
| Sent: Friday, February 14, 2003 12:46 PM
| To: [EMAIL PROTECTED]
| Subject: JVM Question
| 
| Hi All,
| 
| Has anyone tried BEA JRockit with Tomcat? Does anyone know if Tomcat is
| certified with it?
| 
| Many Thanks,
| Tony


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




RE: NEW POST: How do I view this jsp???

2003-02-13 Thread Jacob Hookom
You only have the footer attached.

You also need to describe HOW the date is showing up.  I can't help you if
you just say it doesn't show up right.

Regards,
Jacob

-Original Message-
From: Steve Burrus [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, February 13, 2003 4:58 PM
To: [EMAIL PROTECTED]
Subject: NEW POST: How do I view this jsp???

hi, I need help/assistance right now with viewing this particular jsp, a
rather simple one, which displays the current date and time! Now, when I go
to viewing it, any text which I might have written in it shows up OK, but
the actual date and time does not. Now, what am i possibly lacking in the
code anyway? I am really *stumped" about this one. I have included the
program for anyone out there who is still willing to help me. 


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




RE: Pro WAR (was Re: Fw: Fight war)

2003-02-13 Thread Jacob Hookom
Genius.

| -Original Message-
| From: Will Hartung [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, February 13, 2003 12:57 PM
| To: Tomcat Users List
| Subject: Pro WAR (was Re: Fw: Fight war)
| 
| > From: "Kemp Randy-W18971" <[EMAIL PROTECTED]>
| > Sent: Thursday, February 13, 2003 9:55 AM
| > Subject: RE: Fw: Fight war
| 
| 
| > Hey guys!  Please!  I thought this was a series of posts on Java "war"
| > files.  It seems I was mistaken!
| 
| Here's why I'm all for WAR. It's not secret, I've advocated it before.
| 
| Consolidation - It brings together the disparate entities into a
| concerted,
| unified whole.
| 
| Structure - It helps ends the chaos by promoting an overarching structure
| to
| the whole domain.
| 
| Piece - It makes it one single piece.
| 
| Diplomacy - WAR is the only things that various parties can agree on. They
| differ on other factors, but they all agree on WAR.
| 
| So, I try to advocate and use WAR files myself. Once you settle upon the
| WAR
| file structure, and keep it as a subtext to how you application gets
| deployed, I find it makes dealing with the containers much easier because
| they're designed to operate on and document the interaction with WAR
| files.
| 
| So, wholeheatedly, 100% I'm Pro WAR
| 
| Regards,
| 
| Will Hartung
| ([EMAIL PROTECTED])
| 
| 
| 
| 
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: Tomcat Performance Measuring

2003-02-12 Thread Jacob Hookom
There is an article at javaworld on filters that accomplish this, otherwise
head over to opensymphony.com to download the filter itself.

-Bocaj

| -Original Message-
| From: p niemandt [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, February 13, 2003 12:11 AM
| To: Tomcat Users List
| Subject: Re: Tomcat Performance Measuring
| 
| There is some stuff on filters for doing this on the web: do a google,
| but the basic idea is you write a filter that filters the request, get
| the current time, dispatches the request, filter the response, work out
| the difference, and return to the browser ...
| 
| hth,
| paul
| 
| On Thu, 2003-02-13 at 04:39, Garrett Dangerfield wrote:
| > I've looked through the documentation I could find, and I looked through
| > the source for AccessLogValve and I didn't see the option for what I'm
| > looking for.
| >
| > I'm looking for getting a measurement of "page duration" (the time,
| > preferrably in milliseconds, between when the server originally receives
| > the first byte of a request and the time it sends the last byte of the
| > response).
| >
| > What I'm trying to do is monitor the server load/response time back to
| > the users, particularly by time of day.
| >
| > I've seen lots of test clients that do this, but I want to monitor my
| > actual production system to see how it's doing.
| >
| > Thank you,
| > Garrett.
| >
| >
| > -
| > To unsubscribe, e-mail: [EMAIL PROTECTED]
| > For additional commands, e-mail: [EMAIL PROTECTED]
| --
| p niemandt <[EMAIL PROTECTED]>
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: my first servlet

2003-02-12 Thread Jacob Hookom
Check your logs to see if your servlet is even initialized

| -Original Message-
| From: Jose Moreira [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, February 12, 2003 5:00 AM
| To: Tomcat Users List
| Subject: my first servlet
| 
| hello, i created my first servlet called db2xml but when i try to access
| it
| i get :
| 
| http://localhost:8081/servlet/db2xml
| 
| 
| Apache Tomcat/4.0.4 - HTTP Status 503 - Servlet db2xml is currently
| unavailable
| 
| type Status report
| 
| message Servlet db2xml is currently unavailable
| 
| description The requested service (Servlet db2xml is currently
| unavailable)
| is not currently available.
| 
| 
| 
| ps.: im using Netbeans 2.4.1 IDE and the servlet whas wizard-created.
| 
| what could be the problem? thank you
| 
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: preview of webapp of Tomcat Performance book

2003-02-11 Thread Jacob Hookom
Yes, very much so.

| -Original Message-
| From: Peter Lin [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, February 11, 2003 7:59 AM
| To: Tomcat Users List
| Subject: preview of webapp of Tomcat Performance book
| 
| 
| I plan on releasing the webapp and utilities for
| Tomcat Performance Handbook Remy and I are writing in
| the next few days. I'd like to know if tomcat-users
| find that appealing?
| 
| peter lin
| 
| 
| __
| Do you Yahoo!?
| Yahoo! Shopping - Send Flowers for Valentine's Day
| http://shopping.yahoo.com
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: Need help w. another jsp!

2003-02-10 Thread Jacob Hookom
<%
  switch(color) {
case RED : {
%>
<%=data %>
<%
}
default : {
%>
<%=data %>
<%
}
  }
%>

There is a better way to do this though with scriptlets (if you must embed
java code).

<%
  final String[] colors = new String[]
  { "black", "blue", "green", "red"  };
  int colorToUse = 3;
  if (colorToUse >= colors.length) colorToUse = 0;
%>

<%=data %>

-Jacob

| -Original Message-
| From: Steve Burrus [mailto:[EMAIL PROTECTED]]
| Sent: Monday, February 10, 2003 11:32 PM
| To: Tomcat Users List
| Subject: RE: Need help w. another jsp!
| 
| Hi Denise, and I really do appreciate yer nice response back to my plea
| for some help/assistance with this damn "ControlFlow.jsp" of mine. Listen,
| did you know that the "switch-case" is in a jsp, and so the whole block is
| contained in these symbols (<% %>). Now, how exactly do I handle that? I
| need some guidance from you now. Is the whole block contained between
| brackets ({ }) or something?


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




RE: MySQL control center

2003-02-05 Thread Jacob Hookom
I just started using it, the one thing to point out is that their user
management doesn't work properly.  Whenever you update security settings for
a user, then their password is resaved in a non hashed format causing your
password to become invalid if you previously set one.

-Bocaj

| -Original Message-
| From: tomcat guy [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, February 05, 2003 12:42 PM
| To: Tomcat Users List
| Subject: MySQL control center
| 
| Could anyone tell me about the MySQL interfaceMySQLCC?  Any basic
| information about it would be great (i.e. stability, accuracy, easy of
| use).


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




RE: Realm url-pattern problems

2003-02-05 Thread Jacob Hookom
/*.htm should just be *.htm

| -Original Message-
| From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, February 05, 2003 6:20 AM
| To: [EMAIL PROTECTED]
| Subject: Realm url-pattern problems
| 
| Hi, I am working on an application using Realm.
| I'm trying to use "/*.htm" in the ur-pattern tag but it is
|  not working.
| Is that a bug? Am I doing anything wrong?
| 
|   
|   
|   Sample
|   /*.htm
|   
|   
|   guest
|   
|   
| 
| I'll appreciate all help.
| Thanks.
| 
| Ricardo Kohler Costa.
| 
| Don't E-Mail, ZipMail! http://www.zipmail.com/
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: pageContext error ???

2003-02-04 Thread Jacob Hookom
You might want to check your page declaration if you have your isErrorPage
or errorPage declarations setup incorrectly.  It might be trying to throw an
exception to a page that does not exist or cannot be found.

-Jacob Hookom

| -Original Message-
| From: jsp [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, February 04, 2003 2:00 PM
| To: 'Tomcat Users List'
| Subject: pageContext error ???
| 
| Im running tomcat 4.1 and I'm building a shopping cart from a book. When
| browse to the index.jsp page of the app I receive this error...
| 
| root cause
| 
| javax.servlet.ServletException
|   at
| org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContex
| tImpl.java:533)
| 
| I know why this is happening , in the WORK folder under tomcat the
| index_jsp.java file reads at line 251...
| 
| if (pageContext != null) pageContext.handlePageException(t);
| 
| 
| 
| Anyone know what cuases this type of error, or where to look for help???
| 
| Regards,
| Wiley
| 
| 
| -
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]


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




RE: Why won't anyone help me out??

2003-02-04 Thread Jacob Hookom
It's a much simpler framework to use for dynamic content as opposed to
jsp/servlets.  I think dabbling in coldfusion may help you understand the
parts of a web application a little better than jumping into JSP/Servlets.
The other alternative to Servlets is to look at the standard taglibs can
possibly be Java free (no need to compile on your part) AKA JSTL.

To reiterate what was mentioned before, if you can't package a class and you
can't make a conscious effort to look to your IDE's FAQs/Help for
information instead of OT'ing tomcat-user, then you should maybe look at
getting a book or look at markups like ColdFusion.

Best Regards,
Jacob Hookom

PS, any further questions/comments can be sent to me directly :-)

| -Original Message-
| From: Steve Burrus [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, February 04, 2003 4:25 PM
| To: Tomcat Users List
| Subject: RE: Why won't anyone help me out??
| 
| Hi Jakob, I just gotta respond back to your posting w. the obvious
| question of you: Why do you necessarily recommend to me that I start to
| "check out" Macromedia's Cold Fusion product??! How would that help me get
| over this problem with being able to execute a jsp/servlet in the Tomcat
| container?


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




RE: Why won't anyone help me out??

2003-02-04 Thread Jacob Hookom
Steve, have you ever looked at coldfusion? www.macromedia.com/coldfusion


| -Original Message-
| From: Steve Burrus [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, February 04, 2003 3:36 PM
| To: [EMAIL PROTECTED]
| Subject: Why won't anyone help me out??
| 
| 
| Well, seeing how no one, so far, has seen fit to respond back to my "plea
| for help/assistance", I will re-post this from late last nite!! I am
| getting quite desperate the longer that I have to go on without getting
| this right!
| 
| 
| 
| Hello again, Filip, I tried to "package up" the 2 required files,
| login.jsp and
| LDAPAuth.java into a newly created "org.burrus.test" folder, and then
| compiled them
| into that same folder/directory to create 2 .class files, but then when I
| tried to
| run the whole program in my JBuilder 8, I STILL got, for my efforts, the
| old 505
| server error page:
| 
| Apache Tomcat/4.0.6 - HTTP Status 500 - Internal Server Errortype
| Exception
| reportmessage Internal Server Errordescription The server encountered an
| internal error
| (Internal Server Error) that prevented it from fulfilling this
| request.exception
| org.apache.jasper.JasperException: Unable to compile class for JSPNote:
| sun.tools.javac.Main has been deprecated.
| 
| 
| An error occurred at line: 4 in the jsp file: /login.jsp
| 
| Generated servlet error:
| C:\Documents and Settings\Steven R.
| Burrus\jbproject\thirdjavaproj\Tomcat\work\login$jsp.java:64: Class
| org.apache.jsp.LDAPAuthBean not found.
| LDAPAuthBean auth = null;
| ^
| 
| 
| An error occurred at line: 4 in the jsp file: /login.jsp
| 
| Generated servlet error:
| C:\Documents and Settings\Steven R.
| Burrus\jbproject\thirdjavaproj\Tomcat\work\login$jsp.java:67: Class
| org.apache.jsp.LDAPAuthBean not found.
| auth= (LDAPAuthBean)
|^
| 
| 
| An error occurred at line: 4 in the jsp file: /login.jsp
| 
| Generated servlet error:
| C:\Documents and Settings\Steven R.
| Burrus\jbproject\thirdjavaproj\Tomcat\work\login$jsp.java:72: Class
| org.apache.jsp.LDAPAuthBean not found.
| auth = (LDAPAuthBean)
| java.beans.Beans.instantiate(this.getClass().getClassLoader(),
| "LDAPAuthBean");
| ^
| Note: C:\Documents and Settings\Steven R.
| Burrus\jbproject\thirdjavaproj\Tomcat\work\login$jsp.java uses or
| overrides a deprecated API.  Recompile with
| "-deprecation" for details.
| 3 errors, 2 warnings
| 
|  at org.apache.jasper.compiler.Compiler.compile(Compiler.java:285)
|  at org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:548)
|  at
| org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(Jsp
| Servlet.java:176)
|  at
| org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.
| java:188)
|  at
| org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)
|  at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)
|  at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
|  at
| org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applicati
| onFilterChain.java:247)
|  at
| org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilter
| Chain.java:193)
|  at
| org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.
| java:243)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :566)
|  at
| org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472
| )
|  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
|  at
| org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.
| java:190)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :566)
|  at
| org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java
| :246)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :564)
|  at
| org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472
| )
|  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
|  at
| org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2347)
|  at
| org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:1
| 80)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :566)
|  at
| org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValv
| e.java:170)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :564)
|  at
| org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:1
| 70)
|  at
| org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java
| :564)
|  at
| org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472
| )
|  at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
|  at
| org.apache.catalina.core.StandardE

RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!

2003-01-27 Thread Jacob Hookom
I did finally get my caching filter to work by following the same logic
included in the GZip filter included in Tomcat 4.1.18.  It works VERY well
:-) Hopefully we can resurrect the Common's Cache project that includes
filters and taglibs?

-Jacob

| -Original Message-
| From: Cox, Charlie [mailto:[EMAIL PROTECTED]]
| Sent: Monday, January 27, 2003 7:48 AM
| To: 'Tomcat Users List'
| Cc: 'Jacob Kjome'
| Subject: RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!
| 
| see the thread titled:
| RE: Tomcat 4.1.18/19 - How to activate gzip support?
| http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg82477.html
| 
| and read the associated links about a similar problem (filter works for
| static content, not for dynamic).
| 
| Charlie
| 
| 
| > -Original Message-
| > From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| > Sent: Saturday, January 25, 2003 12:21 PM
| > To: 'Tomcat Users List'
| > Subject: RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!
| >
| >
| > I did something very similar to what you have here, but I did a
| > DualServletOutputStream where if the printwriter was
| > requested from the
| > HttpServletResponseWrapper, I would return a new PrintWriter
| > that wrapped my
| > DualServletOutputStream.  The dual output stream contains the
| > super.getOutputStream() (the actual response output) and the
| > BufferedOutputStream that is used to getByteArray() and cache it.
| >
| > It's very strange though because again, HTML files are
| > successfully cached
| > and I can even look at the serialized content on the file
| > system, but 0
| > bytes are written from JSP requests, even though I can see in my Log4j
| > output that indeed the getWriter() method was called on my
| > HttpServletResponseWrapper.
| >
| > Best Regards,
| > Jacob Hookom
| >
| > -Original Message-
| > From: li pan [mailto:[EMAIL PROTECTED]]
| > Sent: Friday, January 24, 2003 11:01 PM
| > To: [EMAIL PROTECTED]
| > Subject: RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!
| >
| >
| > Hello Jacob
| >   I have successfully implemented this idea. I guess you mean
| > that get the
| > writer of JSP, and replace the writer with another one which
| > will cache the
| > jsp results as well as output them to the original writer?
| > Yes, it works.
| >   I didn't use a filter, I simply hacked tomcat, so that my
| > cache facility
| > can be used by any web applications without modifying source
| > codes of them.
| >   But I didn't get trouble by getWriter(), I guess maybe :
| > 1 before you get the writer from the filter, tomcat has already done
| > something to the writer? I get it right after the JSP
| > instance is built.
| > 2 tomcat does not allow you to change the writer of a
| > response while it is
| > in the filter chain? I also replace the response with my own
| > wrapper, so I
| > don't change it.
| >
| > Here is my buffered writer:
| >
| > package servercache;
| > import java.io.PrintWriter;
| > import java.nio.CharBuffer;
| > public class BufferedPrintWriter
| > extends PrintWriter {
| >
| > private PrintWriter writer;
| > private CharBuffer buffer = CharBuffer.allocate(1024);
| >
| > public BufferedPrintWriter(PrintWriter writer) {
| > super(writer); //doesnot make any sense.
| > this.writer = writer;
| > }
| >
| > public void write(char[] buf, int offset, int count) {
| > writer.write(buf, offset, count);
| > buffer.put(buf, offset, count);
| > }
| >
| > public void write(String str) {
| > writer.write(str);
| > buffer.put(str);
| > }
| >
| > public void print(String str) {
| > writer.print(str);
| >
| > if (str == null) {
| > buffer.put("null");
| > } else {
| > buffer.put(str);
| > }
| > }
| >
| > public void println(String str) {
| > writer.println(str);
| > buffer.put(str);
| > buffer.put("\n");
| > }
| >
| > public CharBuffer getBuffer() {
| >
| > return buffer;
| > }
| > }
| >
| > and here is how it is created:
| >
| > writer = new BufferedPrintWriter(response.getWriter());
| >
| >
| >
| > _
| > ÓëÁª»úµÄÅóÓѽøÐн»Á÷£¬ÇëʹÓà MSN Messenger:  http://messenger.msn.com/cn
| >
| >
| > --
| > To unsubscribe, e-mail:
| > <mailto:[EMAIL PROTECTED]>
| > For additional commands, e-mail:
| > <mailto:[EMAIL PROTECTED]>
| >
| >
| > --
| > To unsubscribe, e-mail:
| > <mailto:[EMAIL PROTECTED]>
| > For additional commands, e-mail:
| > <mailto:[EMAIL PROTECTED]>
| >
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>


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




RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!

2003-01-25 Thread Jacob Hookom
I did something very similar to what you have here, but I did a
DualServletOutputStream where if the printwriter was requested from the
HttpServletResponseWrapper, I would return a new PrintWriter that wrapped my
DualServletOutputStream.  The dual output stream contains the
super.getOutputStream() (the actual response output) and the
BufferedOutputStream that is used to getByteArray() and cache it.

It's very strange though because again, HTML files are successfully cached
and I can even look at the serialized content on the file system, but 0
bytes are written from JSP requests, even though I can see in my Log4j
output that indeed the getWriter() method was called on my
HttpServletResponseWrapper.

Best Regards,
Jacob Hookom

-Original Message-
From: li pan [mailto:[EMAIL PROTECTED]] 
Sent: Friday, January 24, 2003 11:01 PM
To: [EMAIL PROTECTED]
Subject: RE: [Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!


Hello Jacob
  I have successfully implemented this idea. I guess you mean that get the 
writer of JSP, and replace the writer with another one which will cache the 
jsp results as well as output them to the original writer? Yes, it works.
  I didn't use a filter, I simply hacked tomcat, so that my cache facility 
can be used by any web applications without modifying source codes of them.
  But I didn't get trouble by getWriter(), I guess maybe :
1 before you get the writer from the filter, tomcat has already done 
something to the writer? I get it right after the JSP instance is built.
2 tomcat does not allow you to change the writer of a response while it is 
in the filter chain? I also replace the response with my own wrapper, so I 
don't change it.

Here is my buffered writer:

package servercache;
import java.io.PrintWriter;
import java.nio.CharBuffer;
public class BufferedPrintWriter
extends PrintWriter {

private PrintWriter writer;
private CharBuffer buffer = CharBuffer.allocate(1024);

public BufferedPrintWriter(PrintWriter writer) {
super(writer); //doesnot make any sense.
this.writer = writer;
}

public void write(char[] buf, int offset, int count) {
writer.write(buf, offset, count);
buffer.put(buf, offset, count);
}

public void write(String str) {
writer.write(str);
buffer.put(str);
}

public void print(String str) {
writer.print(str);

if (str == null) {
buffer.put("null");
} else {
buffer.put(str);
}
}

public void println(String str) {
writer.println(str);
buffer.put(str);
buffer.put("\n");
}

public CharBuffer getBuffer() {

return buffer;
}
}

and here is how it is created:

writer = new BufferedPrintWriter(response.getWriter());



_
ÓëÁª»úµÄÅóÓѽøÐн»Á÷£¬ÇëʹÓà MSN Messenger:  http://messenger.msn.com/cn  


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


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




[Tomcat 4.1] Caching JSP Output via Filter PLZ HELP!!

2003-01-24 Thread Jacob Hookom
I'm running Tomcat 4.1.18

 

I've just about about finished a Filter that wraps the response and allows
caching to take place by storing the response in a ByteArrayOutputStream.

 

Currently, I have my Filter deployed in the Examples Application bound to
/jsp/*.  It will cache HTML files just fine, but any time I request a JSP, I
can see that getWriter() is being called for which I return my OutputStream
wrapped in a PrintWriter.  After passing through the chain with the filter,
I output how many bytes were written to Log4j, with HTML files, it displays
correctly, but whenever I request a JSP, nothing is written and a 0 length
byte array is returned from my outputStream.

 

Is there a method other than getOutputStream() and getWriter() that Tomcat
is using to write the content of JSP's out because thus far, these are the
only method's I've proxied for caching-but again, with JSP pages, nothing is
written to the writer or output stream?

 

PLEASE HELP!!

 

-Jacob




HttpServletResponse Caching

2003-01-23 Thread Jacob Hookom
I'm going to cache the response from a resource via a filter
(WrappedHttpServletResponse).

Currently I'm storing both the header information and the outputstream as a
byte array.  Should I be making accommodations for storing/rewriting header
information, or is this something that automatically gets written into the
outputstream at some point that I wouldn't need to do up proxy-type methods
for caching when a resource calls setHeader(String, String) on the response?

Best Regards,
Jacob


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: CPU and Tomcat 4.1 problems

2003-01-19 Thread Jacob Hookom
I had lots of problems with the Struts Iterate tags causing memory leaks
when I stress tested pages.  I ended up replacing them with JSTL tags and it
went away.  Struts 1.1b3 probably has the issue resolved (if it was the
case).

Jacob

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, January 19, 2003 10:01 AM
To: tomcat-user
Subject: CPU and Tomcat 4.1 problems

I have created a web application with Struts 1.0. I use Tomcat 4.1.12 to run
it.
Lots of times, the CPU reach 90% and I need to restart the Tomcat service.

My Computer runs with :
Windows 2000 Server
512 Mo RAM
JDK 1.3.1.02

The service was created by the command :

tomcat.exe -install "Apache Tomcat 4.1"
[jdk1.3path]\jre\bin\server\jvm.dll
-Djava.class.path=[tomcatpath]\bin\bootstrap.jar;[jdk1.3path]\lib\tools.jar
-Dcatalina.home=[tomcatpath]
-server -Xms128m -Xmx512m -Xrs
-start org.apache.catalina.startup.BootstrapService -params start
-stop org.apache.catalina.startup.BootstrapService -params stop
-out [tomcatpath]\logs\stdout.log
-err [tomcatpath]\logs\stderr.log

Thanks very much

Christophe (CLN)

PS : Can I reduce the memory taken by Tomcat with the parameters -Xms64m
-Xmx256m without any problem.

--

Faites un voeu et puis Voila ! www.voila.fr 



--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




[OT] RE: Game server - two player board game

2003-01-19 Thread Jacob Hookom
You might want to look that the wildtangent driver.  It's not necessarily
made for multiplayer games, but we wrote an implementation in there that
worked with a servlet.

www.wildtangent.com


-Original Message-
From: Rasputin [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, January 19, 2003 9:01 AM
To: Steven J. Owens
Cc: Tomcat Users List
Subject: Re: Game server - two player board game

* Steven J. Owens <[EMAIL PROTECTED]> [0128 23:28]:
> On Sat, Jan 18, 2003 at 12:48:20PM -0800, Mark wrote:
> > Hi, I'm using Tomcat 4.1 to set up a game server for the two player
> > board game, Tanbo (similar to Go). Basically, I will be providing one
> > board and a waiting list, and a chat.
> >  
> > I need advice on how to set up the object architecture. I'm
> > considering using an int array to represent the board. And possibly a
> > separate class to evaluate legal moves.
> >  
> > I need advice on security, persistence, thread safety and anything
> > else that I might need to know to make this a successful web site
> > (tanbo.com).
 
>  You might be better off asking for help at javagaming.org,
> gamedev.net, or possibly rec.games.programmer.  Javagaming.org used to
> have a mailing list, but it appears they've dispensed with that in
> favor of a forums system on the website (frankly, I miss the mailing
> list).  The [EMAIL PROTECTED] mailing list is fairly active
> and (oddly enough) game programming oriented, so they might be able to
> help you out.

Thanks a lot for the link - I've tried several times to write online games,
and have never got a project off the ground because I don't
have clue about architecture.


-- 
Rasputin :: Jack of All Trades - Master of Nuns

--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Game server - two player board game

2003-01-18 Thread Jacob Hookom
Usually, when speed is at stake, you would want to represent the board as a
2D array.  For example you can write tic-tac-toe w/ AI in only a page of
code.  If you are talking about applet->servlet communication or pseudo
object RMI, then you might want to pick up  "Java Developers Guide to
Servlets and JSP" by Brogden pub. SYBEX.  He has a whole chapter on applet
and servlet communication.

Jacob

-Original Message-
From: Mark [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, January 18, 2003 2:48 PM
To: Tomcat Users List
Subject: Game server - two player board game

Hi, I'm using Tomcat 4.1 to set up a game server for the two player board
game, Tanbo (similar to Go). Basically, I will be providing one board and a
waiting list, and a chat.

I need advice on how to set up the object architecture. I'm considering
using an int array to represent the board. And possibly a separate class to
evaluate legal moves.

I need advice on security, persistence, thread safety and anything else that
I might need to know to make this a successful web site (tanbo.com).

Thanks in advance.

Mark Steere
[EMAIL PROTECTED] 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Servlet channing

2003-01-16 Thread Jacob Hookom
Comments below:

| -Original Message-
| From: Reynir Hübner [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, January 16, 2003 2:04 PM
| To: Tomcat Users List
| Subject: RE: Servlet channing
| 
| I can of course only answer this for my self, but the main reason is
| Struts is an implementation of a specific pattern. When I started
writing
| J2EE applications some time ago, struts was not fully grown. I had a
| pattern in my mind that I wanted to have an implementation of. The
main
| thing in this pattern is the servlet chaining mechanism (btw, filters
had
| not be introduced (to tomcat or other app servers) when I wrote this
| chaining mechanism).

I'm a big user of Struts and can't say enough about it :-)

| I have to admitt the fact that I have never used struts, and I have
not
| really spent a lot of time on checking it out.
| The functionality I wanted in my servlet-chains is the ability to
create
| streamlines, that have can have multiple starting nodes and an
multiple
| stop nodes. This means I need to be able to build in some "flow logic"
| into the servlet chain mechanism, I can't see how that would be done
with
| filters, at least not in the way I want.

Well, Struts acts like a controller to receive requests, then pull data
in from your model (DB, XML, etc), attach it to the request as an
attribute, then pass the request on to another resource to handle the
display.

Filters are great because you can lay them sort of before your
ActionController receives the request.  The reason that I say sort of,
is that Filters act like PullParsers where once your Filter receives the
request, YOU call the next item in the chain by passing the request and
response up the chain.

Here's how I'm using filters with Struts:
I'm using the SecurityFilter to block access to resources on the server
based on user roles.  Then I have a CachingFilter bound to many
resources to cache the output of a Struts Action so I can reduce
processing and catch the request before it re-executes the Struts
Action.  Then I also have TransformationFilters setup so I can convert
the response from an Action into PDF or HTML based on XML outputted by
the succeeding JSP from the Action.

| So I think servlet chaining, struts and filters all describe sepperate
| patterns even though there isn't much difference between them.

Correct, Filters do not replace Struts, but act like an added bonus at
the view level of the MVC framework that Struts provides.

| Each servlet in a chain has some specific purpouse such as determine
the
| user who is logged on, determine some data that will be used in the
| presentation layer below the chain. If anyone has seen Intershops
Enfinity
| Pipelines my application does similar things, in similar ways except
less
| propriatary.
| 
| 
| -reynir

Jacob Hookom



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




RE: Servlet channing

2003-01-16 Thread Jacob Hookom
Instead of chaining servlets, why not look at filters, whose specific
purpose is to work on a chain.  There is even some talk of switching
struts over from a servlet to a filter in a later release.

Jacob

| -Original Message-
| From: Reynir Hübner [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, January 16, 2003 1:29 PM
| To: Tomcat Users List
| Subject: RE: Servlet channing
| 
| Some people would recommend to you that you look into struts, which is
an
| web-application framework.
| 
| Servlet chaining in it's most simple way is a servlet that forwards
the
| request to another servlet. This can be achived by using the
| RequestDispatcher, be aware that using the RequestDispatcher may slow
your
| application down a little bit because (I've heard) it's not fully
| optimized in tomcat.
| 
| I wrote servlet-chaining mechanism, it was not hard to do, so I
recommend
| that if this is something you really think you need, you should write
your
| own servlet chianing API.
| 
| -reynir
| 
| 
| > -Original Message-
| > From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
| > Sent: 16. janúar 2003 18:29
| > To: Tomcat Users List
| > Subject: Re: Servlet channing
| >
| >
| >
| >
| > On Thu, 16 Jan 2003, nitin mandolkar wrote:
| >
| > > Date: Thu, 16 Jan 2003 05:45:12 + (GMT)
| > > From: nitin mandolkar <[EMAIL PROTECTED]>
| > > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
| > > To: [EMAIL PROTECTED]
| > > Subject: Servlet channing
| > >
| > >
| > > How to achive servlet channing with tomcat
| >
| > Servlet chaining (in the manner you describe) is not
| > supported by the servlet spec.  However, you can accomplish
| > something very similar using filters instead (Tomcat 4.x or later).
| >
| > Craig
| >
| >
| >
| > --
| > To unsubscribe, e-mail:
| >  [EMAIL PROTECTED]>
| > For
| > additional commands,
| > e-mail: 
| >
| >
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Apache1.3.27 - tomcat4.1.12 - Mysql 3.23.43 ERROR

2003-01-15 Thread Jacob Hookom
Why don't you run some tests from your IDE, tomcat aside and see if it
does the same thing.  Meaning, setup DBCP in a Main, and run tests to
try to simulate the application's activity.  I highly doubt it has
anything to do with Tomcat, or this list for that matter.

| -Original Message-
| From: Laxmikanth M.S. [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, January 15, 2003 4:39 AM
| To: Tomcat Users List
| Subject: RE: Apache1.3.27 - tomcat4.1.12 - Mysql 3.23.43 ERROR
| 
| Hi all,
| please ehlp me out more. the replies are not enough.
| 
| Regards
| Laxmikanth M S
| Off  : 91-80-6610330 extn 1256
| http://www.sonata-software.com
| 
| > Coming together is the beginning, staying together is progress and
| working
| > together is Success
| What lies behind us and what lies before us are tiny matters compared
to
| what lies within us  - Emerson
| 
| 
| > -Original Message-
| > From:   Laxmikanth M.S. [SMTP:[EMAIL PROTECTED]]
| > Sent:   Monday, December 16, 2002 1:59 PM
| > To: [EMAIL PROTECTED]
| > Subject:Apache1.3.27 -  tomcat4.1.12 - Mysql 3.23.43 ERROR
| >
| > Hi all,
| > I am using apache with tomcat along with mysql database
| > apache and tomcat is in one Linux Machine and mydal database is in
| > separate
| > machine
| > I am using mm.mysql-2.0.9 Driver to connect.the driver is in
| machine1
| > where apache tomcat is installed
| > when i connect to the database during the get connection line is
exeuted
| > error arises in the database ...the error is hownbelow...can
anyone
| > help
| > me in this regardthanks in advance
| > Laxmikanth
| >

| --
| > --
| >

| --
| > --
| > --
| > ERROR
| > bin/safe_mysqld: line 273: 20449 Segmentation fault
$NOHUP_NICENESS
| > $ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION --
| datadir=$DATADIR
| > $USER_OPTION --pid-file=$pid_file --skip-locking >>$err_log 2>&1
| >
| > Number of processes running now: 0
| > 021216 14:42:05  mysqld restarted
| > 021216 14:42:05  mysqld ended
| >

| --
| > --
| >

| --
| > --
| > --
| >
*
| > Disclaimer: The information in this e-mail and any attachments is
| > confidential / privileged. It is intended solely for the addressee
or
| > addressees. If you are not the addressee indicated in this message,
you
| > may
| > not copy or deliver this message to anyone. In such case, you should
| > destroy
| > this message and kindly notify the sender by reply email. Please
advise
| > immediately if you or your employer does not consent to Internet
email
| for
| > messages of this kind.
| >
*
| >
| > --
| > To unsubscribe, e-mail:
| > 
| > For additional commands, e-mail:
| > 
| *
| Disclaimer: The information in this e-mail and any attachments is
| confidential / privileged. It is intended solely for the addressee or
| addressees. If you are not the addressee indicated in this message,
you
| may
| not copy or deliver this message to anyone. In such case, you should
| destroy
| this message and kindly notify the sender by reply email. Please
advise
| immediately if you or your employer does not consent to Internet email
for
| messages of this kind.
| *
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: How do I...

2003-01-10 Thread Jacob Hookom
To properly handle logging, you might want to check out log4j.org or
commons-logging.  It's one of the first things I setup for a project, it
makes debugging extremely smooth.

| -Original Message-
| From: Paul Yunusov [mailto:[EMAIL PROTECTED]]
| Sent: Friday, January 10, 2003 12:35 PM
| To: Tomcat Users List
| Subject: Re: How do I...
| 
| On Friday 10 January 2003 01:18 pm, Dan Lipofsky wrote:
| > >
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/context.html
| > >
| > > tells about using the Context element in server.xml to configure a
| > > webapp. Scroll down and note the Logger entry under Nested
Components.
| I
| > > hope this helps.
| >
| > I have the same question as Luc.
| > I set up a Context with a Logger inside.
| > Messages such as JSP compile errors go to the
| > Logger I set up, but messages that are printed
| > to System.out still show up in catalina.out.
| > I read the docs above but I don't see how to change this.
| > Thanks,
| > Dan
| 
| You can't do that individually for contexts, AFAIK. Use
| ServletContext.log()
| instead of System.out.println() to manage log output with
Context-specific
| Loggers.
| 
| You can change the destination of all System.out's for your entire
| Catalina
| engine if you edit catalina.sh.
| 
| System.out is whatever standard output Catalina is pointed at, and,
| respectively, System.err is whatever standard error output Catalina is
| pointed at. Standard output and standard error output are OS concepts
and
| they can be set to a file, console, etc. when running the actual
server
| startup command.
| 
| That command is a part of the catalina.sh script (and its Windows
| equivalent).
| Search that script for /logs/catalina.out and you will see the output
| streams' redirection in action.
| 
| The above is based on the assumption that you use Tomcat 4.1.x.
| 
| Paul
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: How do I...

2003-01-10 Thread Jacob Hookom
Refer to your server.xml and look at the examples setup towards the
middle where it declares the logger and file pattern.

| -Original Message-
| From: Luc Foisy [mailto:[EMAIL PROTECTED]]
| Sent: Friday, January 10, 2003 11:09 AM
| To: Tomcat User List (E-mail)
| Subject: How do I...
| 
| 
| Get out put to go into the context specific logs rather than
| catalina.out??
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Authentication and Filters

2003-01-10 Thread Jacob Hookom
I'm working on finishing up a caching filter, but this puts a kink in
things slightly.  I will just have to manually call the cache manager in
the servlets to handle includes.

| -Original Message-
| From: AAron nAAs [mailto:[EMAIL PROTECTED]]
| Sent: Friday, January 10, 2003 9:03 AM
| To: [EMAIL PROTECTED]
| Subject: Re: Authentication and Filters
| 
| In the meantime, you can intercept includes by writing your own taglib
tag
| to do the include. With your code behind the include, you can do what
you
| wanted to do in the filter chain.
| 
| Example use of a custom include:
| 
| <%@page contentType="text/html"%>
| <%@ taglib uri="/mylib" prefix="my" %>
| 
| Index
| 
| This is the index page.
| The my:include tag filters and outputs the included file in any
fashion
| desireable. Just replace normal includes with this my:include tag. For
| instance, it could replace all less thans with ampersand-lt-semicolon
| strings.
| Included file begins here
| 
| Included file ends here
| 
| 
| 
| -AAron
| 
| >From: Tim Funk <[EMAIL PROTECTED]>
| >Reply-To: "Tomcat Users List" <[EMAIL PROTECTED]>
| >To: Tomcat Users List <[EMAIL PROTECTED]>
| >Subject: Re: Authentication and Filters
| >Date: Fri, 10 Jan 2003 09:52:29 -0500
| >
| >Filters are only performed on the incoming request. So the filter
chain
| is
| >executed once and only once per request.
| >
| >There is an option in the 2.4 Servlet API to allow filter chains to
be
| >invoked on .includes() and .forwards().
| >
| >See section 6.2.5 of the Servlet 2.4 Spec for more details.
| >
| >Tomcat 5 will support the Servlet 2.4 Spec. Tomcat 5 is not released
yet
| >and there is no known timetable as to when it will be released.
| >
| >-Tim
| >
| >Jacob Hookom wrote:
| >>Authentication aside, does the servlet container work such that an
| >>include or RD operation has the option of passing through the
filter?
| >>If so, as of which release?
| >>
| >>Best Regards,
| >>Jacob
| >>
| >
| >
| >--
| >To unsubscribe, e-mail:
| ><mailto:[EMAIL PROTECTED]>
| >For additional commands, e-mail:
| ><mailto:[EMAIL PROTECTED]>
| 
| 
| _
| Add photos to your e-mail with MSN 8. Get 2 months FREE*.
| http://join.msn.com/?page=features/featuredemail
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>


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




RE: Authentication and Filters

2003-01-10 Thread Jacob Hookom
Authentication aside, does the servlet container work such that an
include or RD operation has the option of passing through the filter?
If so, as of which release?

Best Regards,
Jacob

| -Original Message-
| From: Tim Funk [mailto:[EMAIL PROTECTED]]
| Sent: Friday, January 10, 2003 6:30 AM
| To: Tomcat Users List
| Subject: Re: Authentication and Filters
| 
| I meant 2.5 since changes to 2.4 are closed from my position in the
dev
| community.
| 
| My point is only the incoming request is protected by the security
| constraint in web.xml. It may be nice to allow the programmer to also
| check future dispatches for authorization before the dispatch occurs.
| 
| RequestDispatcher.isAuthorized() was to allow an admin to define
| additional security contraints in web.xml without writing code. This
| also requires the cooperation of the developer of a webapp to check
for
| this condition too.
| 
| Sorry for starting to take this off-topic.
| 
| -Tim
| 
| Craig R. McClanahan wrote:
| >
| > On Thu, 9 Jan 2003, Tim Funk wrote:
| >
| >
| >>Date: Thu, 09 Jan 2003 21:15:12 -0500
| >>From: Tim Funk <[EMAIL PROTECTED]>
| >>Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
| >>To: Tomcat Users List <[EMAIL PROTECTED]>
| >>Subject: Re: Authentication and Filters
| >>
| >>Is there a chance (or worthwhile) that in Servlet API 2.5 a
developer
| >>could check if an obtained RequestDispatcher would violate a
security
| >>constraint in web.xml?
| >>
| >
| >
| > I assume you mean Servlet 2.4, right?
| >
| >
| >>For example the following new method:
| >>RequestDispatcher.isAuthorized()
| >>Returns true if the RequestDispatcher's url passes the constraints
| >>defined in web.xml
| >
| >
| > This does not seem likely to me.  Nor does it seem necessary.  After
| all,
| > your application has available everything it needs to know (through
| calls
| > like request.getUserPrincipal() and request.isUserInRole()) to make
this
| > decision for itself.  If the app chooses to forward, the container
is
| > going to assume that it knows what it is doing.
| >
| > Now that you can declare a Filter to be imposed on RD calls in
Servlet
| > 2.4, that might be a good place to implement a check like this.
| >
| >
| >>-Tim
| >>
| >
| >
| > Craig
| >
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Java NIO and IIs/IE ACK/NAK Requests

2003-01-07 Thread Jacob Hookom
Thanks for your comments Craig.  I completely understand that there
isn't any interest in accommodating MS's vacuous attempts at achieving
an upper hand :-)

-Jacob 

-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, January 08, 2003 12:55 AM
To: Tomcat Users List
Subject: Re: Java NIO and IIs/IE ACK/NAK Requests



On Wed, 8 Jan 2003, Jacob Hookom wrote:

> Date: Wed, 8 Jan 2003 00:38:22 -0600
> From: Jacob Hookom <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: Java NIO and IIs/IE ACK/NAK Requests
>
> Two things I'm wondering about:
>
> First, is there any push to include the new NIO libraries or are they
> already included in the new Tomcat releases; if so, there has been
some
> debate as to the actual benefit of them on UNIX based systems
pertaining
> to performance over standard IO.
>

Nobody I know of is pushing it at the moment -- indeed, people whose
opinion I respect have been skeptical of its likely value in a servlet
container.  But if you want to push for it, please speak with code, not
words :-).  Writing a customized version of Coyote that used NIO
(without
impacting the core of the servlet container yet) would be the first step
in determining whether it's worth the effort or not.

> Secondly, I was reading a forum post on how IE with IIs servers work
by
> pre-acking packets from the server to speed up downloads to the client
> browser.  I know it's just a simple return signal from IIs to
accomplish
> this pseudo handshake, but is this a feature that will be integrated
> into Tomcat or Apache down the road?
>

This would have to be implemented in the JVM (for Tomcat standalone) or
in
your webserver (for Tomcat behind a webserver).  There's nothing that
Tomcat can do directly unless it were to ignore the
java.net.ServerSocket
APIs and implement native code TCP/IP drivers.  I don't know about you,
but *I* am totally uninterested in creating a platform dependency in
Tomcat like this, let alone the fact that it would be quite difficult to
achieve comparable performance via JNI.

Regarding the specifics of what IIS does, deliberately violating the
TCP/IP spec standards (to only assist the browser manufactured by
Microsoft) does not seem like something most Apache HTTPD developers
would
be very fond of.  Go ahead and pitch it to them -- but warn me first so
I can stand well back :-).

> -Jacob
>

Craig



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


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




Java NIO and IIs/IE ACK/NAK Requests

2003-01-07 Thread Jacob Hookom
Two things I'm wondering about:
 
First, is there any push to include the new NIO libraries or are they
already included in the new Tomcat releases; if so, there has been some
debate as to the actual benefit of them on UNIX based systems pertaining
to performance over standard IO.
 
Secondly, I was reading a forum post on how IE with IIs servers work by
pre-acking packets from the server to speed up downloads to the client
browser.  I know it's just a simple return signal from IIs to accomplish
this pseudo handshake, but is this a feature that will be integrated
into Tomcat or Apache down the road?
 
-Jacob



RE: Tomcat 4.1.18 has problem castor??

2003-01-06 Thread Jacob Hookom
I remember reading that one of the distributions of Castor had the same
issue you are describing with parsing.  My recommendation is to upgrade
to Castor 4.1 and see if that fixes your issue, it did for me.

Jacob

-Original Message-
From: Ali Kaplan [mailto:[EMAIL PROTECTED]] 
Sent: Monday, January 06, 2003 1:43 PM
To: [EMAIL PROTECTED]
Subject: Tomcat 4.1.18 has problem castor??

Hi,
I am working on a project which uses Tomcat as servlet container and
castor
(ver 0.9.39) which is embedded in Jbuilder 7/8. My problem is that
Unmarshaller.unmarshal(class, reader) has problem with Tomcat 4.1.18.
Unmarshal method does not return proper java object, however, it does
not
throw any exception either.
The same application is working with previous versions of Tomcat 4.1.12,
etc..
Does Tomcat use any xml document parser library which may cause to
conflict
with castor?
Does anyone have this problem before?

All suggestions are welcome.

Thanks,

--ak


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Question - Form Validation

2002-12-29 Thread Jacob Hookom
Why not browse the Jakarta Validator libs?  They are integrated into
Struts.

-Original Message-
From: Turner, John [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, December 28, 2002 11:59 PM
To: ''Tomcat Users List ' '
Subject: RE: Question - Form Validation

 
Hi -

I was researching this very topic as an extension to using regular
expressions for form validation, and I found this on sourceforge.  It
might
be worth a look:

http://formproc.sourceforge.net/

I've never used it, but I plan to give it a look later.

John

-Original Message-
From: Denise Mangano
To: 'Tomcat Users List '
Sent: 12/28/02 8:09 PM
Subject: RE: Question - Form Validation

Any web site references? I'm pressed for time so can't wait for item to
be
shipped and no local bookstores have it in stock...

Also, if I am to have my JSP form post back to itself to validate, I
would
need to employ Java Beans for this - is that correct?

Sorry - I'm a newbie :)

Thanks! 

-Original Message-
From: Paul Campbell
To: Tomcat Users List
Sent: 12/28/2002 3:29 PM
Subject: RE: Question - Form Validation

Advanced Java Server Pages by Geary (Prentice Hall 2001)

At 03:30 PM 12/28/2002 -0500, you wrote:
>It seems to me that Struts is more for large scale enterprise webapps.
>Eventually once my webapp is up and running in a production
environment, if
>our project seems to be more popular than expected, then updates will
be
>necessary and alternative approaches will be considered.
>
>In the meantime, our webapp is for less than medium size organization,
the
>site is pretty simple - just select the fee you are paying and provide
the
>cc info for processing - all this for a pretty stable number of users
(for
>the time being).
>
>Can anyone provide links to any resources for form validation with JSP
- not
>using Struts?  I have a couple of books, but none seem to go into
enough
>detail..
>
>Thanks :)
>Denise
>
>-Original Message-
>From: Noel J. Bergman
>To: Tomcat Users List
>Sent: 12/27/2002 11:34 PM
>Subject: RE: Question - Form Validation
>
>Denise,
>
>There are a number of ways to do it.  One is to build a Struts
>application.
>Another is to have the form post back to itself.  If it likes the form
>data
>(validates), then it can forward to the target page.  There are various
>other solutions.
>
>--- Noel
>
>
>--
>To unsubscribe, e-mail:
>
>For additional commands, e-mail:
>
>
>--
>To unsubscribe, e-mail:

>For additional commands, e-mail:



--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: New HOWTO - Windows XP

2002-12-27 Thread Jacob Hookom
Your howto's are greatly appreciated.  I used your site the first time I
setup my redhat server.  I'm sure it would be of great benefit to the
list as a whole if your site was linked in the footer of the mailing
list ;-)

Highest Regards,
Jacob Hookom

-Original Message-
From: Turner, John [mailto:[EMAIL PROTECTED]] 
Sent: Friday, December 27, 2002 8:37 PM
To: '[EMAIL PROTECTED]'
Subject: New HOWTO - Windows XP


Greetings -

I've been sitting on this HOWTO for awhile, just never got around to
posting
it until tonight.

It covers setting up Apache 2.0.43, Tomcat 4.1.18, and mod_jk with JDK
1.4.1
on Windows XP Professional.  I took some time just now to verify that
all of
the versions are as recent as I could make them, and that everything was
a
binary.  There is no need to compile from source whatsoever, including
the
connector.  If I get some time next week after the holiday, I will do
the
same thing for JK2, though I am still new to JK2.

Win XP Pro + Apache 2.0.43 + Tomcat 4.1.18 + JK HOWTO:

http://www.johnturner.com/howto/winxp-howto.html

Other HOWTOs:

http://www.johnturner.com/howto

As far as I know, the XP HOWTO will work just fine with Windows 2000...I
don't see any reason why it wouldn't.  There might be some issues in the
HOWTO with where to find the Services control panel, etc. that are
different
between 2000 and XP, but as far as the Apache and Tomcat parts of it go,
everything should be identical.  If you're an adept Win 2K user, I'm
sure
you will be able to adapt accordingly.  I don't have access to a Win2K
box
that I can use for messing around, so Win XP Pro it is.

I just didn't have the energy to deal with trying to make JK and Tomcat
work
with IIS...maybe someday, but I doubt it.  I am also considering
revamping
the WinXP HOWTO to include screenshots of the different windows during
all
of the installation steps, but that's a lot of work.  If I get enough
people
asking for that I will consider it, but for now it's just text.

As always, comments and suggestions are welcome, though if you go
through
the HOWTO and have problems, the best place for help is right here.  I'm
getting more and more email each day from people asking for individual
help,
and I just can't do it, as much as I would like to.  If you notice a
glaring
error or mistake in the HOWTO, or have a suggestion, that's different.
Folks sending email consisting of "I followed your HOWTO and it doesn't
work
help me right now" and similar will be directed politely to this list,
so
you might as well post here first.  When posting, please be as specific
as
possible.  At least that way, the solution will be in the archives for
others to use.

Happy New Year to everyone!

John


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.419 / Virus Database: 235 - Release Date: 11/13/2002
 

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


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




RE: in search of more efficient design

2002-12-19 Thread Jacob Hookom
I thought 1 vs many servlets were brought up a while back (possibly late
July), the conclusion was that it was VM dependent if I remember
correctly.

-Original Message-
From: Tim Moore [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 19, 2002 2:17 PM
To: Tomcat Users List
Subject: RE: in search of more efficient design

Maybe a bit more than one word would be more helpful. ;-)

Instead of having 60 - 70 servlet classes, you could have one servlet
with 60 - 70 delegates that are loaded on demand.  Struts includes the
main servlet, and basically consists of a framework for creating and
invoking those delegate classes.  I'm not sure, though, whether they're
actually loaded (and unloaded) on demand, or whether it loads on startup
and keeps them all in memory.  I have a feeling that it's half & half:
loads on demand, but then keeps them in memory until the webapp is
restarted.  Maybe Craig can comment.

It's also worth noting that the memory freed from garbage collecting
objects in Java isn't returned to the OS, but kept as the VMs free
internal heap space.  So just because the VM shows that it's using 500M
of space doesn't mean that there are actually 500M of objects in memory.
If there was high load at some earlier point that pushed it up to 500,
it will stay there until you restart the VM.  I don't know if that's
relevant to your case, though.

-- 
Tim Moore / Blackboard Inc. / Software Engineer
1899 L Street, NW / 5th Floor / Washington, DC 20036
Phone 202-463-4860 ext. 258 / Fax 202-463-4863


> -Original Message-
> From: Jacob Hookom [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, December 19, 2002 3:07 PM
> To: 'Tomcat Users List'
> Subject: RE: in search of more efficient design
> 
> 
> One word... struts
> 
> -Original Message-
> From: ilasno [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, December 19, 2002 1:29 PM
> To: [EMAIL PROTECTED]
> Subject: in search of more efficient design
> 
>  PREAMBLE - I apologize if this is off-topic.  I have been on this 
> search for a month, and have searched the web far and wide, but have 
> mostly found either J2EE design recommendations (higher-level 
> than i am 
> prepared to explore right now) or software vendors trying to sell me 
> load-testing programs.  I would appreciate pointers to 
> self-enlightenment sites almost as much as more specific guidance.
> 
> SHORT VERSION - I am a beginner-intermediate webapp designer, and my 
> first large-scale development is using around 500 mb of 
> memory, with low
> 
> client load.  I am seeking ways to both measure where this extreme 
> resource-usage is stemming from and design tips to bring it down.
> 
> LONG VERSION - The site I am developing is for a company that 
> wishes to 
> be able to change/update portions of their site through a web-based 
> private section of their site.  The result is an extensive admin 
> implemented through a combination of jsp pages (for forms, 
> and feedback)
> 
> and corresponding servlets (for processing and database 
> updating through
> 
> db-access modules).  The admin section is obviously much 
> bigger and more
> 
> resource-intensive than the public portion, which just hits 
> the database
> 
> once-an-hour for updates and displays the current data.  Conversely, 
> while the admin section is much larger (many more servlets 
> with larger 
> file sizes, more processing), it is obviously used much less 
> (one or two
> 
> users per day as opposed to many per day for the public portion).  I 
> have steered away from keeping variables global within servlets 
> (including db-access module instances), so that within a 
> doGet or doPost
> 
> everything i need is created, and then i am assuming when the method 
> ends everything is garbage-collected?  is it possible to have 
> that much 
> memory used just to hold 60 or 70 servlets ready for requests?  I am 
> wondering if my design is flawed, or a bad idea altogether..
> 
> any help or guidance would be greatly appreciated.
> 
> jesse
> -- 
> i am deprogrammed
> 
> 
> --
> To unsubscribe, e-mail: 
> <mailto:tomcat-user-> [EMAIL PROTECTED]>
> For 
> additional commands, 
> e-mail: <mailto:[EMAIL PROTECTED]>
> 
> 
> --
> To unsubscribe, e-mail:   
> <mailto:tomcat-user-> [EMAIL PROTECTED]>
> For 
> additional commands, 
> e-mail: <mailto:[EMAIL PROTECTED]>
> 
> 

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


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




RE: in search of more efficient design

2002-12-19 Thread Jacob Hookom
One word... struts

-Original Message-
From: ilasno [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 19, 2002 1:29 PM
To: [EMAIL PROTECTED]
Subject: in search of more efficient design

 PREAMBLE - I apologize if this is off-topic.  I have been on this 
search for a month, and have searched the web far and wide, but have 
mostly found either J2EE design recommendations (higher-level than i am 
prepared to explore right now) or software vendors trying to sell me 
load-testing programs.  I would appreciate pointers to 
self-enlightenment sites almost as much as more specific guidance.

SHORT VERSION - I am a beginner-intermediate webapp designer, and my 
first large-scale development is using around 500 mb of memory, with low

client load.  I am seeking ways to both measure where this extreme 
resource-usage is stemming from and design tips to bring it down.

LONG VERSION - The site I am developing is for a company that wishes to 
be able to change/update portions of their site through a web-based 
private section of their site.  The result is an extensive admin 
implemented through a combination of jsp pages (for forms, and feedback)

and corresponding servlets (for processing and database updating through

db-access modules).  The admin section is obviously much bigger and more

resource-intensive than the public portion, which just hits the database

once-an-hour for updates and displays the current data.  Conversely, 
while the admin section is much larger (many more servlets with larger 
file sizes, more processing), it is obviously used much less (one or two

users per day as opposed to many per day for the public portion).  I 
have steered away from keeping variables global within servlets 
(including db-access module instances), so that within a doGet or doPost

everything i need is created, and then i am assuming when the method 
ends everything is garbage-collected?  is it possible to have that much 
memory used just to hold 60 or 70 servlets ready for requests?  I am 
wondering if my design is flawed, or a bad idea altogether..

any help or guidance would be greatly appreciated.

jesse
-- 
i am deprogrammed


--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: SUCCESSFUL Tomcat Install!

2002-11-17 Thread Jacob Hookom
The best newbie-book i have read for starting with JSP's, Servlets, and
Taglibs is:

"Java Developer's Guide to Servlets and JSP" by Bill Brogden under Sybex
publishing

It's the book that everyone still borrows from me to read as a starting
point.  Now, I mainly use Jason Hunter's O'Reilly book titled "Java Servlet
Programming" as a quick reference.

-Jacob

- Original Message -
From: "Steve R Burrus" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, November 18, 2002 12:17 AM
Subject: SUCCESSFUL Tomcat Install!


> Well, I really haven't bothered to post to this newsgroup in quite some
time, but
> I just had to proudly announce to anyone interested that I HAVE
SUCCESSFULLY
> INSTALLED TOMCAT!!! This is the 4.1.12 version that I am now talking
about! Any
> possible signs of appreciation from anyone in this newsgroup to that
"dramatic
> news" [-sic] would be greatly welcomed by myself!!!
>
>  Well, with that said, I would like to know just how exactly I start to go
about
> creating the components of the J2EE API, i.e., Servlets and Java Server
Pages in
> the Tomcat web container?! I would bet--if I were a betting man--that it's
a
> rather "tricky" proposition to do so!! Am I wrong? I just know that
someone out
> there in this newsgroup will send me the hyperlink to access all of the
relevant
> information that I need to learn about to create these. I developed the
thought
> some time ago in my mind to start to develop the components of server-side
Java
> programming as a real career for myself. Am I just flat deluding myself
into
> thinking that I can possibly make a "go" of it with trying/attempting to
"dabble"
> with such high technology as a basis for a career? Please give some
feedback about
> this.
>
> __
> Do you Yahoo!?
> Yahoo! News - Today's headlines
> http://news.yahoo.com
>
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Deploying a custom realm.

2002-11-13 Thread Jacob Hookom
http://www.mail-archive.com/tomcat-user@;jakarta.apache.org/msg64942.html

- Original Message -
From: "Scott Dierbeck" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, November 13, 2002 1:51 PM
Subject: Deploying a custom realm.


> We have implemented our own propriatary security API that we would like
> to use in our jsp that run in tomcat 4.1.x.
>
> To authenticate using our security API we will need to write our own
> Authenticator which would extend one of the Authenticators from
> Catalina, and somehow deploy it in Tomcat.
>
> What are the steps that have to be taken to deploy a custom Authenticator?
>
> Do I have to modify the deployment descriptor that comes with catalina
> (mbeans-descriptors.xml) or is there a way to patch in my own?
>
> thanks in advance,
> scott
>
>
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Current performance comparisons of PHP vs. JSP anywhere?

2002-11-10 Thread Jacob Hookom
The only thing I remember off hand was that for multi-user web servers that
have major loads, the memory growth wasn't linear with JSP as opposed to
PHP.  I can't remember the article link, but I do remember that it came to
the conclusion that larger sites with dynamic content should use Java.  Then
again, as with any language-- they will give you enough rope to hang
yourself if you aren't careful.

-Jacob
- Original Message -
From: "Steinar Bang" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, November 10, 2002 2:45 AM
Subject: Current performance comparisons of PHP vs. JSP anywhere?


> I typed the three words "php jsp performace" to www.google.com, and I
> got the following relevant matches:
> http://www.linuxdocs.org/HOWTOs/PHP-HOWTO-13.html>
> http://www.zend.com/zend/art/php-over-java.php>
>
> Both articles are referring to an eWeek test that showed JSP to be 3,5
> times slower than PHP when serving pages from the same hardware.
>
> The article containing the test was published in October 2000, which
> is quite a while ago in JSP terms.  Has there been any newer tests
> that google doesn't know about?
>
> The second article has a link to the original article, but it doesn't
> work.  I was hoping I could go there and perhaps find links to related
> articles.
>
> Thanx!
>
>
> - Steinar
>
>
>
>
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

>


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: [Realm] MBeanException

2002-09-05 Thread Jacob Hookom

I fixed it.

After downloading Tomcat's source code and then walking through the API
and source, I was able to get my specialized DomRealm up and running
without errors.  There is still a tiny problem with non-page based
logins though (Craig could maybe offer some help? ;-)

Initially, I thought about importing all of the MBean classes and force
feeding the Registry within the Realm constructor, but as I continued to
look at the source.

JMX uses an XML configuration file located at:

/org/apache/catalina/mbeans/mbeans-descriptors.xml

So, after walking through the VERY LARGE xml document, I was able to add
my own bean descriptor and then save the mbeans-descriptor.xml to:

$CATALINA_HOME/server/classes/org/apache/./mbeans-descriptors.xml

The only problem I can think of is that you will have to pull the new
descriptor with each release and add your stuff in each time.

I don't really get JMX, it just seams like an archaic version of
BeanUtils?

Jacob Hookom
Comprehensive Computer Science Student
University of Wisconsin, Eau Claire


| -Original Message-
| From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, September 05, 2002 10:39 PM
| To: 'Tomcat Users List'
| Subject: RE: [Realm] MBeanException
| 
| Thanks, although I'm still in the same boat as you.
| 
| I tried commenting out the listeners, but all it did was hide the
| errors.  The Common's model code and the Mbean API are sparsely
| commented :-(
| 
| I did add some System.outs to the Realm and the console reads:
| 
| INFO: Creating MBeanServer
| INITIALIZING DOMREALM
| .
| ServerLifeCycleListener: createMBeans: MBeanException
| java.lang.Exception: ManagedBean is not found with DomRealm
| ...
| Starting service Tomcat-Standalone
| ..
| STARTING DOMREALM
| ..
| 
| I am able to use my realm to authenticate for $ROOT/admin via web
page,
| but authentication for the manager shows a blank page.
| 
| -Jacob
| 
| 
| | -Original Message-
| | From: Robert Parker [mailto:[EMAIL PROTECTED]]
| | Sent: Thursday, September 05, 2002 10:22 PM
| | To: 'Tomcat Users List'
| | Subject: RE: [Realm] MBeanException
| |
| | Members Equity Email System
| | I have a similar problem... I found an earlier post which suggested
| | commenting out the server lifecyle listeners. The post seemed to
imply
| | that
| | it was a JMX classloading type issue. So try commenting out the
| | listeners...
| | This did not work for me, but I don't have exactly the same problem.
| |
| | regards
| |
| | Rob
| |
| | -Original Message-
| | From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| | Sent: Friday, 6 September 2002 12:39PM
| | To: Tomcat Users List
| | Subject: [Realm] MBeanException
| |
| |
| | Hello,
| |
| | I've created a Realm that extends RealmBase, but now I'm getting an
| | exception at startup from the ServerLifecycleListener.
| |
| | I'm running W2K, 4.1.9 and JDK 1.4
| |
| | My class DomRealm extends RealmBase and both the start and stop are
| | overridden, but do call super.start() and super.end().  The jar
| | containing DomRealm and DomPrincipal are within $CATALINA/server/lib
| |
| | Here is the exception:
| |
| | INFO: Initializing Coyote HTTP/1.1 on port 8080
| | ServerLifecycleListener: createMBeans: MBeanException
| | java.lang.Exception: ManagedBean is not found with DomRealm
| | at
| |
org.apache.catalina.mbeans.MBeanUtils.createMBean(MBeanUtils.java:616
| | )
| | at
| |
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| | rLifecycleListener.java:527)
| | at
| |
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| | rLifecycleListener.java:722)
| | at
| |
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| | rLifecycleListener.java:690)
| | at
| |
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| | rLifecycleListener.java:329)
| | at
| |
org.apache.catalina.mbeans.ServerLifecycleListener.lifecycleEvent(Ser
| | verLifecycleListener.java:206)
| | at
| |
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
| | eSupport.java:166)
| | at
| |
org.apache.catalina.core.StandardServer.start(StandardServer.java:218
| | 1)
| | at
| org.apache.catalina.startup.Catalina.start(Catalina.java:510)
| | at
| | org.apache.catalina.startup.Catalina.execute(Catalina.java:400)
| | at
| | org.apache.catalina.startup.Catalina.process(Catalina.java:180)
| | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
Method)
| | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown
Source)
| | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
| | Source)
| | at java.lang.reflect.Method.invoke(Unknown Source)
| | at
| | org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
| | Starting service Tomcat-Standalone
| |
| | Any help would be ap

RE: [Realm] MBeanException

2002-09-05 Thread Jacob Hookom

Thanks, although I'm still in the same boat as you.

I tried commenting out the listeners, but all it did was hide the
errors.  The Common's model code and the Mbean API are sparsely
commented :-(
 
I did add some System.outs to the Realm and the console reads:

INFO: Creating MBeanServer
INITIALIZING DOMREALM
. 
ServerLifeCycleListener: createMBeans: MBeanException
java.lang.Exception: ManagedBean is not found with DomRealm
...
Starting service Tomcat-Standalone
.. 
STARTING DOMREALM
..

I am able to use my realm to authenticate for $ROOT/admin via web page,
but authentication for the manager shows a blank page.

-Jacob


| -Original Message-
| From: Robert Parker [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, September 05, 2002 10:22 PM
| To: 'Tomcat Users List'
| Subject: RE: [Realm] MBeanException
| 
| Members Equity Email System
| I have a similar problem... I found an earlier post which suggested
| commenting out the server lifecyle listeners. The post seemed to imply
| that
| it was a JMX classloading type issue. So try commenting out the
| listeners...
| This did not work for me, but I don't have exactly the same problem.
| 
| regards
| 
| Rob
| 
| -Original Message-
| From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| Sent: Friday, 6 September 2002 12:39PM
| To: Tomcat Users List
| Subject: [Realm] MBeanException
| 
| 
| Hello,
| 
| I've created a Realm that extends RealmBase, but now I'm getting an
| exception at startup from the ServerLifecycleListener.
| 
| I'm running W2K, 4.1.9 and JDK 1.4
| 
| My class DomRealm extends RealmBase and both the start and stop are
| overridden, but do call super.start() and super.end().  The jar
| containing DomRealm and DomPrincipal are within $CATALINA/server/lib
| 
| Here is the exception:
| 
| INFO: Initializing Coyote HTTP/1.1 on port 8080
| ServerLifecycleListener: createMBeans: MBeanException
| java.lang.Exception: ManagedBean is not found with DomRealm
| at
| org.apache.catalina.mbeans.MBeanUtils.createMBean(MBeanUtils.java:616
| )
| at
| org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| rLifecycleListener.java:527)
| at
| org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| rLifecycleListener.java:722)
| at
| org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| rLifecycleListener.java:690)
| at
| org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
| rLifecycleListener.java:329)
| at
| org.apache.catalina.mbeans.ServerLifecycleListener.lifecycleEvent(Ser
| verLifecycleListener.java:206)
| at
| org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
| eSupport.java:166)
| at
| org.apache.catalina.core.StandardServer.start(StandardServer.java:218
| 1)
| at
org.apache.catalina.startup.Catalina.start(Catalina.java:510)
| at
| org.apache.catalina.startup.Catalina.execute(Catalina.java:400)
| at
| org.apache.catalina.startup.Catalina.process(Catalina.java:180)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
| Source)
| at java.lang.reflect.Method.invoke(Unknown Source)
| at
| org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
| Starting service Tomcat-Standalone
| 
| Any help would be apprechiated!
| 
| -Jacob
| 
| 
| ---
| Outgoing mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 
| 
| 
| --
| To unsubscribe, e-mail:
| <mailto:[EMAIL PROTECTED]>
| For additional commands, e-mail:
| <mailto:[EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




[Realm] MBeanException

2002-09-05 Thread Jacob Hookom

Hello,

I've created a Realm that extends RealmBase, but now I'm getting an
exception at startup from the ServerLifecycleListener.

I'm running W2K, 4.1.9 and JDK 1.4

My class DomRealm extends RealmBase and both the start and stop are
overridden, but do call super.start() and super.end().  The jar
containing DomRealm and DomPrincipal are within $CATALINA/server/lib

Here is the exception:

INFO: Initializing Coyote HTTP/1.1 on port 8080
ServerLifecycleListener: createMBeans: MBeanException
java.lang.Exception: ManagedBean is not found with DomRealm
at
org.apache.catalina.mbeans.MBeanUtils.createMBean(MBeanUtils.java:616
)
at
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
rLifecycleListener.java:527)
at
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
rLifecycleListener.java:722)
at
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
rLifecycleListener.java:690)
at
org.apache.catalina.mbeans.ServerLifecycleListener.createMBeans(Serve
rLifecycleListener.java:329)
at
org.apache.catalina.mbeans.ServerLifecycleListener.lifecycleEvent(Ser
verLifecycleListener.java:206)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(Lifecycl
eSupport.java:166)
at
org.apache.catalina.core.StandardServer.start(StandardServer.java:218
1)
at org.apache.catalina.startup.Catalina.start(Catalina.java:510)
at
org.apache.catalina.startup.Catalina.execute(Catalina.java:400)
at
org.apache.catalina.startup.Catalina.process(Catalina.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
Starting service Tomcat-Standalone

Any help would be apprechiated!

-Jacob


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: specify session timeout

2002-09-03 Thread Jacob Hookom

Read the documentation-- odd concept ;-)

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/manager.html

(The page also mentions setting the time out in your app's web.xml)

Or, there's Jakob Nielsen's favorite method of navigation:

http://www.google.com/advanced_search?q=+site:jakarta.apache.org&hl=en&a
s_qdr=all

-Jacob

| -Original Message-
| From: randie ursal [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, September 03, 2002 9:12 PM
| To: Tomcat Users List
| Subject: specify session timeout
| 
| hi,
| 
|can i specify a session timeout value  in Tomcat?
|if yes, how?
| 
|i've done it but it is on the servlet side part, i want if possible
| to set it
|on the web server. so that i would have a centralized session time
|for my web application.
| 
| thanks in advance
| 
|randie
| 
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: [OT] DTD Validation -- Server.xml

2002-08-30 Thread Jacob Hookom

Thanks.  From you comments, I believe I will have to opt out of DTD
validation and just rely on Digester to map any attributes thrown in to
the bean's properties.

| -Original Message-
| From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
| Sent: Friday, August 30, 2002 3:41 PM
| To: Tomcat Users List
| Subject: Re: [OT] DTD Validation -- Server.xml
| 
| 
| 
| On Fri, 30 Aug 2002, Jacob Hookom wrote:
| 
| > Date: Fri, 30 Aug 2002 14:20:40 -0500
| > From: Jacob Hookom <[EMAIL PROTECTED]>
| > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
| > To: Tomcat Users List <[EMAIL PROTECTED]>
| > Subject: [OT] DTD Validation -- Server.xml
| >
| > For container/realm based definitions in the server.xml, I notice
that
| > the Attributes are really fly-by-wire as to the implementing object
| > [MemoryRealm vs. JDBCRealm].
| >
| > If I were to use the Struts Digester and include a DTD for
validation,
| > would any extra Attribute not specified in the DTD be ignored by:
| >
| > A:  The DTD Validation
| 
| No.  Any violation of the list of attributes defined for a particular
| element in a DTD causes the validator to throw an exception on your
| document.  (This, of course, is why there is no such thing as a
complete
| DTD for server.xml files).
| 
| > B:  The Digester itself during parsing
| 
| Yes.  This happens already -- if you have extra attributes on your
| elements that do not match properties on the underlying object, they
are
| silently ignored.
| 
| Note that it's really commons-digester now, and in fact Tomcat 4.1
uses
| this for parsing server.xml files.
| 
| >
| > Best Regards,
| > Jacob Hookom
| > Comprehensive Computer Science
| > University of Wisconsin, Eau Claire
| >
| 
| Craig
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




[OT] DTD Validation -- Server.xml

2002-08-30 Thread Jacob Hookom

For container/realm based definitions in the server.xml, I notice that
the Attributes are really fly-by-wire as to the implementing object
[MemoryRealm vs. JDBCRealm].

If I were to use the Struts Digester and include a DTD for validation,
would any extra Attribute not specified in the DTD be ignored by:

A:  The DTD Validation
B:  The Digester itself during parsing

Best Regards,
Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




RE: Setting up connection pooling via JNDI

2002-08-28 Thread Jacob Hookom

It is, check out the common lib in your tomcat install you will see
the libraries in there.

| -Original Message-
| From: neal [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, August 28, 2002 11:00 PM
| To: Tomcat Users List
| Subject: Setting up connection pooling via JNDI
| 
| I did a search on the Apache site and finally found reference to
"commons"
| ... a subproject that has a bunch of the code referred to in the
how-to
| for
| JDNI setup, including collections, DBCP, and pool.
| 
| Do I really have to setup all this junk?  For crying out loud ... why
is
| this not bundled (or is it) with Tomcat4??!?!?!
| 
| Thanks.
| Neal
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: STILL need help w. Tomcat installation!!

2002-08-28 Thread Jacob Hookom

Steve, I replied to you on this 3 weeks ago, along with everyone else:

My step by step for XP:
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg62993.html

http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg63404.html

http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg60454.html

-Jacob

| -Original Message-
| From: STEVE R BURRUS [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, August 28, 2002 1:40 PM
| To: Tomcat Users List; Jacob Kjome
| Subject: Re: STILL need help w. Tomcat installation!!
| 
|  You are "in luck", my good friend Jakob, I am using the Windows XP
| Operating
| System, so you can certainly help me out!
|

**
| **
| 
| --- Jacob Kjome <[EMAIL PROTECTED]> wrote:
| > Hello STEVE,
| >
| > I forget what OS you are using.  Can you state that?  If you are
using
| > Windows NT/2000/XP and not Windows 95/98/Millenium I can help you.
| > Let me know.
| >
| > Jake
| >
| > Wednesday, August 28, 2002, 12:04:12 PM, you wrote:
| >
| > SRB>  I STILL find myself in some degree of need from someone in
this
| newsgroup
| > SRB> concerning the Tomcat install!!! I THINK that I got everything
| alright with
| > SRB> setting the environment variables in the System applet, but
alas,
| when I
| > tried
| > SRB> again to activate Tomcat, I STILL received the error msg.
saying
| something
| > about
| > SRB> the JAVA_HOME variable was not properly set or missing!! Should
I
| type into
| > the
| > SRB> DOS command line "set JAVA_HOME=j2sdk*" or not to maybe correct
| this?
| >
| > SRB> __
| > SRB> Do You Yahoo!?
| > SRB> Yahoo! Finance - Get real-time stock quotes
| > SRB> http://finance.yahoo.com
| >
| > SRB> --
| > SRB> To unsubscribe, e-mail:
| > 
| > SRB> For additional commands, e-mail:
| > 
| >
| >
| >
| > --
| > Best regards,
| >  Jacobmailto:[EMAIL PROTECTED]
| >
| >
| > --
| > To unsubscribe, e-mail:   
| > For additional commands, e-mail: 
| >
| >
| >
| 
| 
| __
| Do You Yahoo!?
| Yahoo! Finance - Get real-time stock quotes
| http://finance.yahoo.com
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: STILL need help w. Tomcat installation!!

2002-08-28 Thread Jacob Hookom

Are you sure you aren't running Amiga Shell and not DOS?

| -Original Message-
| From: STEVE R BURRUS [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, August 28, 2002 12:04 PM
| To: [EMAIL PROTECTED]
| Subject: STILL need help w. Tomcat installation!!
| 
|  I STILL find myself in some degree of need from someone in this
newsgroup
| concerning the Tomcat install!!! I THINK that I got everything alright
| with
| setting the environment variables in the System applet, but alas, when
I
| tried
| again to activate Tomcat, I STILL received the error msg. saying
something
| about
| the JAVA_HOME variable was not properly set or missing!! Should I type
| into the
| DOS command line "set JAVA_HOME=j2sdk*" or not to maybe correct this?
| 
| __
| Do You Yahoo!?
| Yahoo! Finance - Get real-time stock quotes
| http://finance.yahoo.com
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Java FTP and Tomcat

2002-08-27 Thread Jacob Hookom

Does anyone know if there is a FTP connector(?) for Tomcat?

If not, is it something that's doable with Tomcat?

Regards
-Jacob


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Realm Security Implementation Question [OT]

2002-08-25 Thread Jacob Hookom



| -Original Message-
| From: Will Hartung [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, August 22, 2002 6:14 PM
| To: Tomcat Users List
| Subject: Re: Realm Security Implementation Question [OT]
| 
| From: "Jacob Hookom" <[EMAIL PROTECTED]>
| Sent: Thursday, August 22, 2002 11:19 AM
| 
| 
| > Sorry, I only glanced at the first Pstmt.
| >
| > The roles for our application(s) are complex enough that I'm almost
| > thinking of storing a Document (XML) for the user when they login,
so
| > role validation actually is an XPath statement by which the Realm
| > queries the Principal's DOM for 1 or more nodes and returns true,
| > otherwise false.  This would lead to additional flexibility for
querying
| > out all roles for a specific project, not just validating against
them.
| > Also, future applications can attach themselves to the Document
without
| > affecting current applications.
| 
| Wow! That sounds complicated. Does it really need to be this
complicated?

Everything about container management seems to be URI/Filter based, but
we have issues of "okay, everyone can hit /project.do, but we authorize
based on a param".

| 
| > My only concern is memory, I'm am looking at Dom4j as the
Principal's
| > Document, and from IBM's tests, it's the next best thing to XPP and
it
| > has a memory footprint that's slightly smaller than Xerces.
| 
| You have the memory of the XML document and all of the classes.
| 
| > Either way, String[] vs. Document, there's going to be about 50+
| > elements and with strings, I would end up duplicating information
| > (project/id, project/id/role1, project/id/role2, project/id/role3).
| 
| Sure, but how many users? 10? 1?
| 
| 50 entries * 25 chars per entry = 1250 chars, or 2500 bytes (as chars
are
| 16-bits in Java). Seems pretty cheap to me.
| 
| It just seems expedient is all, the replicated roles are a little
| wasteful,
| perhaps, but it's simple. It works. It's easy to debug if you have
| problems.
| Depending on your load, it certainly gets you over the hump to move on
to
| more interesting problems.

All the data role data is being pulled from SQL, but we are thinking
about proxy'ing the Principal to check XPath role requests against a
single document, so all projects and user roles are actually stored in
one big document, which would also help with read requests like "give me
all of user 54's projects"

-Jacob

| 
| Regards,
| 
| Will Hartung
| ([EMAIL PROTECTED])
| 
| 
| 
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




RE: Realm Security Implementation Question [OT]

2002-08-21 Thread Jacob Hookom

Comments below

| -Original Message-
| From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, August 21, 2002 11:04 PM
| To: Tomcat Users List
| Subject: Re: Realm Security Implementation Question [OT]
| 
| On most reasonable databases, you can create views that organize the
data
| in the way that JDBCRealm needs, and that's a *lot* easier than
writing
| your own LoginMethod implementation in JAAS.
|

It's not a problem to creating views, but I am hesitant to use
JDBCRealm. From looking at the source, it requires one row to contain
all valid roles.  In this case, I would have to setup extensive amounts
of triggers since role management for the site is extremely volatile and
set by users of the site as they go.

I had posted about creating Realms before which you graciously responded
to, but I'm still stuck as to how to handle this schema:

tbl_user
uid email   password

tbl_project
uid name

tbl_project_user
useruid projectuid  role

tbl_resource
uid name

tbl_resource_user
useruid resourceuid role

So, if a user is accessing a project referenced by its uid
(project.do?id=443), I must be able to check a role to see if the user
is even a member of that project, and then get the role(s) he has for
it.  There isn't any uri/directory based validation required.

We are developing only for ourselves so we do have the flexibility of
working directly with our own principal.  The other option is again,
coming up with a String representation that can be tokenized in
representing a role for a particular project id.

-Jacob

| >  Our
| > applications are deployed under a single war to take advantage of a
| > pseudo single sign-on.
| >
| 
| Tomcat 4 supports "real" single sign on if you want it -- see the
section
| entitled "Single Sign On":
| 
| http://jakarta.apache.org/tomcat/tomcat-4.0-doc/config/host.html
| 
| http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/host.html
| 
| 
| 
| > Any suggestions would be apprechiated,
| >
| > Jacob
| >
| 
| Craig
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Realm Security Implementation Question [OT]

2002-08-21 Thread Jacob Hookom

Thanks, I'm looking farther down the road since our application could
also require roles to be pulled from an XML, the more I read about JAAS,
the more I think it's the way to go.  Our deployed larger applications
have roles setup in the DB under separate tables, but with each
additional small project, it might be ideal to setup roles in an XML
file, we could possibly look at stacking LoginModules for a single
Subject.

| -Original Message-
| From: Andrew Conrad [mailto:[EMAIL PROTECTED]]
| Sent: Wednesday, August 21, 2002 5:31 PM
| To: 'Tomcat Users List'
| Subject: RE: Realm Security Implementation Question [OT]
| 
| Your users and roles are in a DB?  It's almost JDBCRealm, except you
| have a table of roles for each application.
| 
| Take a look at the JDBCRealm and I bet you could make your own Realm
| based loosely on that.
| 
| - Andrew
| 
| > -Original Message-
| > From: Hookom, Jacob John [mailto:[EMAIL PROTECTED]]
| > Sent: Wednesday, August 21, 2002 4:20 PM
| > To: [EMAIL PROTECTED]
| > Subject: Realm Security Implementation Question [OT]
| >
| >
| > We are trying to figure out a way to handle realm-based
| > security in a multi-application environement where users and
| > their roles are specified in a DB.  Users are stored in one
| > table with password and there is a table for each application
| > definining permissions for the user.
| >
| > I have been looking at the new JAASRealm the Craig put
| > together, but I'm not sure if it's exactly what we need or if
| > it's going overboard.  Otherwise we have to represent roles
| > in this manner: [applicationName]:[applicationId]:[role] and
| > have a specialized realm do string parsing to validate roles
| > within an application.  Our applications are deployed under a
| > single war to take advantage of a pseudo single sign-on.
| >
| > Any suggestions would be apprechiated,
| >
| > Jacob
| >
| > --
| > To unsubscribe, e-mail:
| >  [EMAIL PROTECTED]>
| > For
| > additional commands,
| > e-mail: 
| >
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Design question

2002-08-19 Thread Jacob Hookom

That's exactly what I was thinking, for every page request, set a really
simple 'digested' token of the user's id and the id of the resource the
link allows.  The receiving servlet on another server peels apart the
token based on the hour time span the token was valid.

But cool, other people are doing the same thing :-)  I just don't want
people to start calling up requests to the second server just by walking
through id's.

-Jacob

| -Original Message-
| From: Mike Jackson [mailto:[EMAIL PROTECTED]]
| Sent: Monday, August 19, 2002 12:17 PM
| To: Tomcat Users List
| Subject: RE: Design question
| 
| An encrypted token is one way of doing it.  We have a system where one
| system
| validates the user and then it redirects the user to another site
passing
| an
| encrypted token (containing amoungst other things a timestamp to allow
| only
| a short "window" of opportunity for the token to be used) as a
parameter.
| 
| --mikej
| -=-
| mike jackson
| [EMAIL PROTECTED]
| 
| > -Original Message-
| > From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| > Sent: Monday, August 19, 2002 10:09 AM
| > To: 'Tomcat Users List'
| > Subject: RE: Design question
| >
| >
| > I'm trying to accomplish the same thing--
| >
| > How do you authenticate on Server A, then have that principal carry
over
| > to Servers B and C for download authorization?
| >
| > Thanks!
| > -Jacob
| >
| > | -Original Message-
| > | From: Luminous Heart [mailto:[EMAIL PROTECTED]]
| > | Sent: Monday, August 19, 2002 12:06 PM
| > | To: Tomcat Users List
| > | Subject: Re: Design question
| > |
| > | Yes Raju,
| > | It should be doable. You can download TC latest and
| > | hack some code. If you want to use some readily
| > | availabe to help in the process, take a look at the
| > | Tag libs available on Jakarta. Also there are a few
| > | File Upload beans floating around the net, go to
| > | google and type JSP File Upload Bean and see what you
| > | will get.
| > |
| > | I have a couple of applications where a user will
| > | upload files to a remote server after authenticating.
| > |
| > | regards.
| > |
| > | --- Raju Lokhande <[EMAIL PROTECTED]> wrote:
| > | > Greetings everybody,
| > | >  I am doing some research on possibility of using
| > | > Tomcat to do a project. General requirements as
| > | > follows
| > | > 1. A user will login to the web application and
| > | > upload a file to a remote server. He or she can only
| > | > access his or her WIN2K/NT domain to upload this
| > | > file.
| > | > 2. User will download a file or a number of files
| > | > from the remote server - again from his or her
| > | > domain.
| > | > I was told that I can do this job using Java Servlet
| > | > and IBM Websphere or BEA Weblogic.
| > | > I am not sure if this is possible in Tomcat. Has
| > | > anybody done similar work using Tomcat. Can you
| > | > share your experiences please?
| > | > Thanks
| > | > Raju Lokhande
| > | >
| > | >
| > | >
| > | >
| > |
| >

| > *
| > | > This message, together with any attachments, is
| > | > intended only
| > | > for the use of the individual or entity to which it
| > | > is addressed. It
| > | > may contain information that is confidential and
| > | > prohibited from
| > | > disclosure.  If you are not the intended recipient,
| > | > you are
| > | > hereby notified that any dissemination or copying of
| > | > this
| > | > message or any attachment is strictly prohibited. If
| > | > you have
| > | > received this message in error, please notify the
| > | > original sender
| > | > immediately by telephone or by return e-mail and
| > | > delete this
| > | > message along with any attachments, from your
| > | > computer.
| > | > Thank you.
| > | >
| > |
| >

| > *
| > | >
| > | >
| > | > --
| > | > To unsubscribe, e-mail:
| > | > <mailto:[EMAIL PROTECTED]>
| > | > For additional commands, e-mail:
| > | > <mailto:[EMAIL PROTECTED]>
| > | >
| > |
| > |
| > | __
| > | Do You Yahoo!?
| > | HotJobs - Search Thousands of New Jobs
| > | http://www.hotjobs.com
| > |
| > | --
| > | To unsubscribe, e-mail:   <mailto:tomcat-user-
| > | [EMAIL PROTECTED]>
| > | For additional commands, e-mail: <mailto:tomcat-user-
| > | [EMAIL PROTECTED]>
| > |
| > | ---
| > | Incoming mail 

RE: Design question

2002-08-19 Thread Jacob Hookom

I'm trying to accomplish the same thing--

How do you authenticate on Server A, then have that principal carry over
to Servers B and C for download authorization?

Thanks!
-Jacob

| -Original Message-
| From: Luminous Heart [mailto:[EMAIL PROTECTED]]
| Sent: Monday, August 19, 2002 12:06 PM
| To: Tomcat Users List
| Subject: Re: Design question
| 
| Yes Raju,
| It should be doable. You can download TC latest and
| hack some code. If you want to use some readily
| availabe to help in the process, take a look at the
| Tag libs available on Jakarta. Also there are a few
| File Upload beans floating around the net, go to
| google and type JSP File Upload Bean and see what you
| will get.
| 
| I have a couple of applications where a user will
| upload files to a remote server after authenticating.
| 
| regards.
| 
| --- Raju Lokhande <[EMAIL PROTECTED]> wrote:
| > Greetings everybody,
| >  I am doing some research on possibility of using
| > Tomcat to do a project. General requirements as
| > follows
| > 1. A user will login to the web application and
| > upload a file to a remote server. He or she can only
| > access his or her WIN2K/NT domain to upload this
| > file.
| > 2. User will download a file or a number of files
| > from the remote server - again from his or her
| > domain.
| > I was told that I can do this job using Java Servlet
| > and IBM Websphere or BEA Weblogic.
| > I am not sure if this is possible in Tomcat. Has
| > anybody done similar work using Tomcat. Can you
| > share your experiences please?
| > Thanks
| > Raju Lokhande
| >
| >
| >
| >
|

*
| > This message, together with any attachments, is
| > intended only
| > for the use of the individual or entity to which it
| > is addressed. It
| > may contain information that is confidential and
| > prohibited from
| > disclosure.  If you are not the intended recipient,
| > you are
| > hereby notified that any dissemination or copying of
| > this
| > message or any attachment is strictly prohibited. If
| > you have
| > received this message in error, please notify the
| > original sender
| > immediately by telephone or by return e-mail and
| > delete this
| > message along with any attachments, from your
| > computer.
| > Thank you.
| >
|

*
| >
| >
| > --
| > To unsubscribe, e-mail:
| > 
| > For additional commands, e-mail:
| > 
| >
| 
| 
| __
| Do You Yahoo!?
| HotJobs - Search Thousands of New Jobs
| http://www.hotjobs.com
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Realm Authentication Across Multiple Servers

2002-08-19 Thread Jacob Hookom

The application we are working on is laid out on the network like so (*
means many):

Apache2

Tomcat4 Web Site Servers*

Tomcat4 File Servers*

Basically the application acts much like sourceforge or another download
site, but I would like to carry authentication from the Web site server
to the request made to the File Servers.

Is this possible?  I did think about a way of creating a timed/digested
certificate that could be passed in the request string, but it would be
ideal to have the Principal be used on all servers.

The user roles for the Web site servers are pulled from a DB, but I have
heard that these servers can share a JNDI context, so couldn't
information be put in there?

Any advice would be appreciated as I'm working in rational rose this
afternoon trying to lay things out :-)

-Jacob


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Need help w. Tomcat Installation

2002-08-18 Thread Jacob Hookom



| -Original Message-
| From: STEVE R BURRUS [mailto:[EMAIL PROTECTED]]
| Sent: Sunday, August 18, 2002 3:55 PM
| To: [EMAIL PROTECTED]
| Subject: Need help w. Tomcat Installation
| 
|   Hello all, this is steve burrus.I am an admitted Tomcat "newbie"
user,
| and I
| find
| myself in need again of some advice from someone/somebody about just
how
| the hell
| do you first install tomcat??! I am trying to install Tomcat 4.0.4,
and I
| get
| everything alright EXCEPT for getting an error msg. in DOS when I try
to
| start it
| up saying that the JAVA-HOME environment isn't properly set!!! 

Make sure you have j2sdk installed

Right click on My Computer
Go to Properties
Click on Advanced Tab
Click on Environment Variables at the bottom
Under system variables, click New
Variable Name: JAVA_HOME
Variable Value: C:\j2sdk. Wherever your root sdk installation is

Note, if you already have a console window open, you will need to close
it and open a new one to get the updated system variable (I don't know
why, it just does).


| I know that
| I have
| set it in the "System" applet correctly!! I am using Win XP. Oh, and
one
| more
| thing: Is there any new version of tomcat beyond v. 4.0.4?

Of course... try looking at jakarta's home page, it reads at the top
"15 August 2002 - Tomcat 4.1.9 Beta Released"

| 
| 
| 
| __
| Do You Yahoo!?
| HotJobs - Search Thousands of New Jobs
| http://www.hotjobs.com
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: anyone recieve this email?

2002-08-18 Thread Jacob Hookom

Respond

| -Original Message-
| From: neal [mailto:[EMAIL PROTECTED]]
| Sent: Sunday, August 18, 2002 2:09 PM
| To: Tomcat Users List
| Subject: anyone recieve this email?
| 
| Can anyone hear me?  Is anyone recieving this email?  Please respond.
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Enterprise Java Beans (EJB)

2002-08-15 Thread Jacob Hookom



| -Original Message-
| From: V. Cekvenich [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, August 15, 2002 10:28 AM
| To: Tomcat Users List
| Subject: Re: Enterprise Java Beans (EJB)
| 
| No
| Here is what:
| Bean (formBean in Struts for example) delegate to DAO for CRUD
| (Insert,Read, Update,Delete to SQL DB) and persistence, done by DAO.
| DAO is an interface.
| The interface could be, inside of the DAO and not known to bean
| (formBean), implemented inside of the DAO a few different ways.
| You could have a DAO implementation using EJB or Castor or Jakrta OJB,
| or RowSet (I use RowSet).

Have you had much luck with RowSet? I check the Sun forums and everyone
complains.  I think it's an awesome framework, but the sun
implementation is really lacking, features such as createCopy, or
createShared don't work well if at all in testing what they "say" it
will do.

RowSet does work with JSTL, so I'm thinking about standardizing RowSet
with my application as the Model Bean to use with my pages.

-Jacob


| If you have an interface, such as DAO pattern, you could change the
| implementation and not affect the rest of your application.
| So ... make your persistance/CRUD and interface.
| 
| This lets you change how it does CRUD. You should be able to switch
from
| JDO to EJB or OJB to RowSet/ResulSet.
| 
| If you have to refactor the whole application to junk EJB or JDO...
that
| would not be great. A simple interface would do ya.
| 
| v.
| 
| 
| Ned Wolpert wrote:
| > When you say 'replace EJB with JDO' you mean replacing EJB's entity
| > beans with DAO, right? (As opposed to session and message beans)
(I've
| > never used DAO, just TopLink and CastorJDO instead of Entity beans
or as
| > BMP entity beans)
| >
| > On Thu, 2002-08-15 at 08:11, V. Cekvenich wrote:
| >
| >>Consider draping a DAO around your persistence.
| >>This way you can replace EJB with JDO or RowSet, should you need to
| >>Ex DAO interface:
| >>http://cvs.sourceforge.net/cgi-
|
bin/viewcvs.cgi/basicportal/src_05d/basicPortal/src/org/apache/commons/D
AO
| /BasicDAO.java?rev=1.1.1.1&content-type=text/vnd.viewcvs-markup
| >>
| >>I found a RowSet implementation of DAO works better than EJB.
| >>
| >>v.
| >>
| >>Ned Wolpert wrote:
| >>
| >>>EJB provides a way to easily encapsulate business logic and reduce
| >>>complexity by moving some difficult functionality/designs into
| >>>deployment instead of development. Transaction requirements defined
in
| >>>the deployment of the EJB beans as opposed to part of the
development
| of
| >>>the EJB beans. (And they are easy to migrate/scale to many
computers
| >>>based on deployment configuration, again, making that task easier
for
| >>>developers since the programmer does not need to do anything
special to
| >>>achieve this.
| >>>
| >>>Session beans contain the business logic (Servlets call them)
| >>>Entity beans persist the info to the database. (Session beans call
| them)
| >>>Message beans respond to JMS queues/topics.
| >>>
| >>>In reality, EJB is simply another design pattern... one that was
| >>>over-hyped by the vendors, but can provide flexibility needed in
some
| >>>cases.
| >>>
| >>>On Wed, 2002-08-14 at 22:34, Josh wrote:
| >>>
| >>>
| Don't suppose anybody can send me a pointer as to what EJB and
Jboss
| actually achieve? All i managed to glean from their website were
some
| pretty
| 3d variations on the usual "our product in the middle and some
arrows"
| diagrams.
| 
| -Josh
| 
| "Rimmer, real dumplings, proper dumplings when they're properly
|  cooked to perfection, proper dumplings, should not bounce."
| 
| - Original Message -
| From: "Nikola Milutinovic" <[EMAIL PROTECTED]>
| To: "Tomcat Users List" <[EMAIL PROTECTED]>
| Sent: Thursday, August 15, 2002 3:31 PM
| Subject: Re: Enterprise Java Beans (EJB)
| 
| 
| 
| 
| >>Does Tomcat support EJB?.
| >
| >No, it is not the task of Tomcat.
| >
| >
| >
| >>if not, is there a project to migrate tomcat to support EJB?...
it
| will
| >
| be
| 
| 
| >>a very nice feature...
| >
| >Other servers, like JBoss, are EJB containers, Tomcat can
| 
| connect/integrate with them. There is a version of JBoss that
comes
| bundled
| with Tomcat. Take a look at http://www.jboss.org/
| 
| 
| >Nix.
| >
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| 
| >>
| >>
| >>--
| >>To unsubscribe, e-mail:   
| >>For additional commands, e-mail: 
| >>
| >>
| 
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by

RE: performance problem

2002-08-15 Thread Jacob Hookom

It looks like you are using custom tags, and usually with XML
transformations, they are quite processor heavy.  You might want to look
at the new Jaxen benchmarks with Dom4j:

www.jaxen.org

-Jacob

| -Original Message-
| From: Alessandro Di Maria [mailto:[EMAIL PROTECTED]]
| Sent: Thursday, August 15, 2002 4:59 AM
| To: tomcat-user
| Subject: performance problem
| 
| Hello!
| 
| I have extremly performance problem!
| 
| I send a http-request to Tomcat, which forwards the request over RMI
to
| a business logic.
| This sends back a XML with the templates to include and values to
place
| in the templates.
| 
| This process takes about 100 - 400ms (not very fast but ok)
| 
| After received the answer, Tomcat processes the XML via a few custom
| tags to include
| templates and write text values in this templates.
| 
| A small (3k) template needs about 500ms to display.
| A little bit larger one (9k), about 20 sec
| 
| For the time the HTML is created (resolving custom tags) , Tomcat is
| using 100% of the CPU!
| 
| Looking at my log files, it seems that the HttpProcessor-Thread on
| Tomcat is blocked
| by another tomcat thread. In intervalls of about 4sec the
| HttpProcessor-Thread can process a little
| bit of its code and than is blocked again.
| 
| Or tomcat is not able to hold the request object and writes it
somewhere
| to disk.
| So every 4sec it has to read or write the information needed for this
| process to disk.
| Must I increment the cache for the context or the server? But where
and
| how?
| 
| Here a snippet of my  log-file:
| 2002-08-14 15:49:36,403 DEBUG [HttpProcessor[8080][3]]
| obsession.juice.out CmsTag doStartTag - CurrentNode = [Element:
| ] looking for child [pers_klassifikation_item] 1
of
| 2
| 
| 2002-08-14 15:49:40,068 DEBUG [HttpProcessor[8080][3]]
| obsession.juice.out SelectTag getOutputText - looking for parent
| 
| the JSP-Code involved in this 4 sec:
| 
| 
| 
| 
| ">
| 
| 
| " >
| 
| 
| 
| 
| 
| 
| 
| the XML needed to populate the custom tags:
| 
| 
|   Lead
|   Honorar
| 
| 
| 4sec to know if the  tag is selected or not!
| 
| Libraries involved jdom.jar and log4j.jar
| 
| Using Tomcat 4.0.3, Java 1.3 on Windows2000 and Linux Debian as well.
| 
| Thx for any help
| Alessandro
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Can this be done...?

2002-08-13 Thread Jacob Hookom

Water Street is my second home, only 2 blocks away :-)

If you do a pure call to XML from your browser, you will need to
reference the XSL document which will be used by your 'browser' to do
the transformation as Jacob Kjome pointed out.

Probably the easiest way to test transformations is to do a simple jsp
with JSTL that takes in the XML and the XSL document as parameters.

Regards,
Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire



| -Original Message-
| From: Tod Thomas [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, August 13, 2002 8:55 PM
| To: Tomcat Users List
| Subject: Re: Can this be done...?
| 
| On Tue, 13 Aug 2002 20:33:38 -0500
| "Jacob Hookom" <[EMAIL PROTECTED]> wrote:
| 
| > You might want to look at installing JSTL under the Taglibs
"Standard"
| >
| > It provides simple xslt transformation by selecting a file as a
source
| > and a file as the xsl document, the download includes deployable
wars
| > that demonstrate this functionality.
| >
| > -Jake
| 
| Thanks, I'll have a look.  But was my original thinking wrong?  Should
I
| expect tomcat to just perform the transform because I've set my
xml/xsl up
| correctly, is there something extra I need to do, or is it just not
| designed to do that elegantly?
| 
| Say hi to Water St. for me.
| 
| 
| > | -Original Message-
| > | From: Tod Thomas [mailto:[EMAIL PROTECTED]]
| > | Sent: Tuesday, August 13, 2002 7:31 PM
| > | To: [EMAIL PROTECTED]
| > | Subject: Can this be done...?
| > |
| > | I want to use tomcat on my machine to test XSLT.
| > |
| > | I have a directory called Tomcat/webapps/testxslt.  There I have
| > placed my
| > | test.xml and test.xsl files.  I have copied xalan.jar,
xml-apis.jar,
| > and
| > | xerces-Impl.jar into my $JAVA_HOME/jre/lib/endorsed directory.
Using
| > | command line Xalan I have validated that both files are well
formed
| > and
| > | work as expected.  Using a browser I can get to both the xml and
xsl
| > pages
| > | and view their contents, but the transformation never occurs.  I
do
| > have
| > | an href in the xml pointing to the xsl file.
| > |
| > | Am I wrong in thinking I can do this?  Is there maybe something I
need
| > to
| > | do to one of the configuration files to make this happen?  I
really
| > don't
| > | need the functionality of Cocoon yet so this scaled down testing
| > platform
| > | using Tomcat only would serve me well.  Any suggestions?
| > |
| > | Thanks in advance.
| > |
| > | --
| > | To unsubscribe, e-mail:   <mailto:tomcat-user-
| > | [EMAIL PROTECTED]>
| > | For additional commands, e-mail: <mailto:tomcat-user-
| > | [EMAIL PROTECTED]>
| > |
| > | ---
| > | Incoming mail is certified Virus Free.
| > | Checked by AVG anti-virus system (http://www.grisoft.com).
| > | Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| > |
| >
| > ---
| > Outgoing mail is certified Virus Free.
| > Checked by AVG anti-virus system (http://www.grisoft.com).
| > Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| >
| >
| >
| > --
| > To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| > For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| >
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




RE: Can this be done...?

2002-08-13 Thread Jacob Hookom

You might want to look at installing JSTL under the Taglibs "Standard"

It provides simple xslt transformation by selecting a file as a source
and a file as the xsl document, the download includes deployable wars
that demonstrate this functionality.

-Jake

| -Original Message-
| From: Tod Thomas [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, August 13, 2002 7:31 PM
| To: [EMAIL PROTECTED]
| Subject: Can this be done...?
| 
| I want to use tomcat on my machine to test XSLT.
| 
| I have a directory called Tomcat/webapps/testxslt.  There I have
placed my
| test.xml and test.xsl files.  I have copied xalan.jar, xml-apis.jar,
and
| xerces-Impl.jar into my $JAVA_HOME/jre/lib/endorsed directory.  Using
| command line Xalan I have validated that both files are well formed
and
| work as expected.  Using a browser I can get to both the xml and xsl
pages
| and view their contents, but the transformation never occurs.  I do
have
| an href in the xml pointing to the xsl file.
| 
| Am I wrong in thinking I can do this?  Is there maybe something I need
to
| do to one of the configuration files to make this happen?  I really
don't
| need the functionality of Cocoon yet so this scaled down testing
platform
| using Tomcat only would serve me well.  Any suggestions?
| 
| Thanks in advance.
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: apache+tomcat?

2002-08-13 Thread Jacob Hookom



| -Original Message-
| From: Lee Zhao [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, August 13, 2002 6:30 PM
| To: Tomcat Users List
| Subject: apache+tomcat?
| 
| Can someone please explain why one needs or wants to use apache in
| addition to tomcat?

Tomcat is great at serving up dynamic content (jsp pages, servlets).
Apache is a great at serving up static content (images, html pages,
etc).

Through using mod_jk or other connectors, we can have Apache filter only
dynamic content off to Tomcat which frees up Tomcat to handle only the
stuff that matters, like JSP's and Servlets.  Let Apache handle static
content because that's what it does best.

Can one just use tomcat as plain web server for
| serving HTML pages?

Not a problem.

Thanks in advance.
| 
| 
| 
| -Original Message-
| From: sibusiso xolo [mailto:[EMAIL PROTECTED]]
| Sent: Tuesday, August 13, 2002 5:05 PM
| To: Tomcat Users List
| Subject: Re: can't find mod_jk.conf
| 
| 
| the best place to find out what to do is here:-
| 
| ~/jakarta-tomcat-4.0.4/webapps/tomcat-docs/config/ajp.html
| about halfway down the page under Using ApacheConfig
| 
| good luck
| 
| On Sunday 11 August 2002 15:35, Scott Adamson wrote:
| > I have been trying to get Tomcat 4.04 to work with Apache (compiled
| > statically with mod_jk). According to the HOWTO on the Apache site
| > mod_jk.conf should be auto-generated with startup, it isnt. My guess
| would
| > be that there is some other configuration I need, but the HOWTO only
| seems
| > to mentions a 'workers.properties' file, which I created as
instructed.
| Can
| > anyone help me with Tomcat 4 + Apache + mod_jk ? I would prefer to
stick
| > with mod_jk (it already works with tomcat3.2.1) but I would consider
| using
| > other connectors.
| >
| >
| > Any help that anyone can offer would be much appreciated.
| >
| > regards,
| >
| > Scott Adamson
| > Systems Administrator
| > Syware Technology
| >
| > [EMAIL PROTECTED]
| > http://upe.com.au
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: [Q] Realms, Principals, et al...

2002-08-12 Thread Jacob Hookom


Again, you are the man.

Thanks for the quick responses,
Jake

| Loading all the roles into GenericPrincipal is just the way that the
| existing Realm implementations do it.  Nothing stops you from using a
| Principal implementation that doesn't contain the roles, and make your
| Realm.hasRole() implementation do database lookups for the particular
role
| in question.  Note that your Realm implementation acts as a Factory
for
| the Principal -- you can override RealmBase.authenticate() to return
| whatever kind of Principal you want, as long as you override hasRole()
| also.  For example, it would be straightforward to create a Realm
| implementation that implemented every call to hasRole() as a database
| lookup -- although this will be slower than the current approach, it
won't
| have the memory overhead of storing all the roles (or the
computational
| overhead of looking all of them up).
|
| 
| > Much Appreciated,
| > Jake Hookom
| >
| 
| Craig
| 
| 
| --
| To unsubscribe, e-mail:   
| For additional commands, e-mail: 
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: [Q] Realms, Principals, et al...

2002-08-12 Thread Jacob Hookom



| -Original Message-
| From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
| Sent: Monday, August 12, 2002 9:27 PM
| To: Tomcat Users List
| Subject: RE: [Q] Realms, Principals, et al...
| 
| 
| 
| On Mon, 12 Aug 2002, Jacob Hookom wrote:
| 
| > Date: Mon, 12 Aug 2002 21:02:15 -0500
| > From: Jacob Hookom <[EMAIL PROTECTED]>
| > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
| > To: 'Tomcat Users List' <[EMAIL PROTECTED]>
| > Subject: RE: [Q] Realms, Principals, et al...
| >
| > | Just as a simple example, consider the concept of "group" that
many
| > | security environments define.  Either of the following mappings
would
| > be
| > | perfectly legal from the perspective of a servlet container (or a
J2EE
| > app
| > | server):
| > |
| > | * "Group == Role" (since Tomcat 3.x and 4.0 do not have any
specific
| > |   concept of a group, this is effectively what they implement).
| > |
| > | * "Group == set of roles inherited by all members of the group"
| > (supported
| > |   explicitly by Tomcat 4.1).
| > |
| > | The details of how role is mapped to real-world things is up to
the
| > | container.
| > |
| >
| > How is group implemented then in 4.1 if we want to take advantage of
| > this feature?  I'm looking at the HttpServletRequest API which
involves
| > getting a requested Principal, but only Role is exposed via Strings.
| >
| 
| If you look at the admin tool, you'll see that you can create users,
| groups, and roles.  Groups can have roles assigned to them (just like
| users can), as well as users who are members.  And, of course, users
can
| be members of more than one group.
| 
| When an isUserInRole() check is performed, Tomcat performs a union of
all
| the roles assigned to the user individually, and all the roles
assigned to
| groups that this user is a member of.
| 
| Stored in the tomcat-users.xml file, you'll see an element for each
| , an element for each , and an element for each .
The
| best wasy to see what's possible is to add some of these through the
admin
| tool, and then go examine $CATALINA_HOME/conf/tomcat-users.xml
afterwards.
| 
| > Is the presumption that we cast to our own Principal (implements
User)
| > and do verification based on the now exposed groups?  Granted I
would
| > start with my own UserRealm extending RealmBase with a UserDatabase
of
| > my own.
| >
| 
| As I said in an earlier email, groups are ***not*** exposed to a
webapp
| through the servlet apis.  The only difference is that you can assign
| roles once to a group instead of having to assign all of them
individually
| to each member, in the user database.
| 
| There is no change to how security constraints are defined, or what
| isUserInRole returns - that all still happens in terms of roles.

So, groups are implemented within the context of Tomcat's
admin/management, not as a feature in a new Servlet API, or Catalina's
general API.

If I were to implement Realm and return a ProxyPrincipal that would be
tied back to my DB, I could theoretically write my own Role schema with
my own group implementation; as long as I could provide accurate
authorization through Realm.hasRole(Principal,String).  Other than that,
Tomcat won't have any issues?

I guess my main concern is writing an implementation that fits the needs
of my project without extending RealmBase or GenericPrincipal and
sticking to the java.security.Principal and org.apache.calalina.Realm
interfaces.  Because of the amount of permissions that must be checked,
it's not ideal to load all roles upon authentication.

Much Appreciated,
Jake Hookom

| 
| > Best Regards,
| > Jake Hookom
| >
| 
| Craig
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


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




RE: [Q] Realms, Principals, et al...

2002-08-12 Thread Jacob Hookom

| Just as a simple example, consider the concept of "group" that many
| security environments define.  Either of the following mappings would
be
| perfectly legal from the perspective of a servlet container (or a J2EE
app
| server):
| 
| * "Group == Role" (since Tomcat 3.x and 4.0 do not have any specific
|   concept of a group, this is effectively what they implement).
| 
| * "Group == set of roles inherited by all members of the group"
(supported
|   explicitly by Tomcat 4.1).
| 
| The details of how role is mapped to real-world things is up to the
| container.
| 

How is group implemented then in 4.1 if we want to take advantage of
this feature?  I'm looking at the HttpServletRequest API which involves
getting a requested Principal, but only Role is exposed via Strings.

Is the presumption that we cast to our own Principal (implements User)
and do verification based on the now exposed groups?  Granted I would
start with my own UserRealm extending RealmBase with a UserDatabase of
my own.

Best Regards,
Jake Hookom
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Shared Drives

2002-08-11 Thread Jacob Hookom

Of which system?  I did get it to network this morning by running it
normally from the start menu while logged in as administrator, but it
would be ideal to get it to run as a service

| -Original Message-
| From: Andrew [mailto:[EMAIL PROTECTED]]
| Sent: Sunday, August 11, 2002 12:29 PM
| To: 'Tomcat Users List'
| Subject: RE: Shared Drives
| 
| Have you tried mapping the drive as administrator?
| 
| > -Original Message-----
| > From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
| > Sent: Sunday, August 11, 2002 2:17 AM
| > To: Tomcat Users List
| > Subject: Shared Drives
| >
| >
| > I had mentioned before that I was looking to access my
| > network within a servlet.  Someone had mentioned that I need
| > to run tomcat as a service under the user that has the mapped drive.
| >
| > ServerA -Win2k
| > Login: Administrator
| > Mapped: F:/ to ServerB via 'TomcatUser' login
| > Running: Tomcat 4.1 Service as user Administrator
| >
| > ServerB -Win2k
| > Login: Administrator
| > Sharing: C:/ with full permissions for 'TomcatUser'
| >
| >
| > Code:
| >
| > File source = new File("F:/");
| > if (!source.exists())
| > log.error("Cannot Access Share");
| >
| > And it logs that it cannot access the share.  Do I need to
| > look at editing my policy file?
| >
| > Best Regards,
| > Jacob Hookom
| > Comprehensive Computer Science
| > University of Wisconsin, Eau Claire
| >
| >
| >
| > ---
| > Outgoing mail is certified Virus Free.
| > Checked by AVG anti-virus system (http://www.grisoft.com).
| > Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
| >
| >
| >
| > --
| > To unsubscribe, e-mail:
| > <mailto:tomcat-user-> [EMAIL PROTECTED]>
| > For
| > additional commands,
| > e-mail: <mailto:[EMAIL PROTECTED]>
| >
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




Shared Drives

2002-08-10 Thread Jacob Hookom

I had mentioned before that I was looking to access my network within a
servlet.  Someone had mentioned that I need to run tomcat as a service
under the user that has the mapped drive.

ServerA -Win2k
Login: Administrator
Mapped: F:/ to ServerB via 'TomcatUser' login
Running: Tomcat 4.1 Service as user Administrator

ServerB -Win2k
Login: Administrator
Sharing: C:/ with full permissions for 'TomcatUser'


Code:

File source = new File("F:/");
if (!source.exists())
log.error("Cannot Access Share");

And it logs that it cannot access the share.  Do I need to look at
editing my policy file?

Best Regards,
Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




RE: Problems with *

2002-08-10 Thread Jacob Hookom



| -Original Message-
| From: Alexander Wallace [mailto:[EMAIL PROTECTED]]
| Sent: Saturday, August 10, 2002 7:56 AM
| To: Tomcat Users List
| Subject: Re: Problems with *
| 
| Ok, but what I mean by access rights are a set of very custom
| permissions (existing in a database table) givent to different roles
| asigned to users of my web app, is that also handled by filters?

You will want to look at using a JdbcRealm which will take care of that
for you.  Realms are the new standard for handling user roles.

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/realm-howto.html#JDBCRea
lm

Otherwise you can do a filter like Craig mentioned which acts as an
intermediary before requests hit your servlet or pages in the first
place.

http://www.javaworld.com/javaworld/jw-06-2001/jw-0622-filters.html

| 
| Also, at this point I my servlet does receive requests (let's say
| /login) and checks if the users (in this case by providing an id in
the
| url) is trying to log in into a valid "company" in the web app, and if
| so, I use a forward to a jsp that actually shows the login form and
| let's them log in. I'm not sure if you meant I was not going to be
able
| to serve anyghing from my servlet, but i do.

I think the assumption was that you were binding to just "/" not
"/login".  If you just do "/" then you will run into major issues as
Craig mentioned.

| 
| I'm I all confused then? I'm sorry if i sound too newbie... I am tho
:/

-Jake

| 
| On Sat, 2002-08-10 at 18:59, Craig R. McClanahan wrote:
| >
| >
| > On 10 Aug 2002, Alexander Wallace wrote:
| >
| > > Date: 10 Aug 2002 12:17:03 +0100
| > > From: Alexander Wallace <[EMAIL PROTECTED]>
| > > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
| > > To: Tomcat Users List <[EMAIL PROTECTED]>
| > > Subject: Re: Problems with *
| > >
| > > What I need to be able to do is to make sure, that every request,
for
| > > any page has enought rights to view the page and use it, So i
thought
| of
| > > using a servlet as a controller. If I understand correctly what
you
| > > talked about in this and your previous post, using the servlet
mapping
| > > to "/" will not work at some point.
| > >
| > > I'm not that experienced yet in these matters, could you ilustrate
to
| me
| > > a bit why this won't cut it?
| > >
| >
| > Using a *servlet* for your purpose (checking access rights) will not
| work
| > at all -- see my previous post for why you should use a Filter
instead.
| >
| > The problem with the "/" mapping in particular is that this mapping
is
| > assigned, by default, to a servlet that serves static content.  So,
when
| > you make a request to a URL like:
| >
| >   http://localhost:8080/myapp/index.html
| >
| > you generally won't have a servlet mapped to this -- and Tomcat
assigns
| it
| > to the default file-serving servlet, which serves the "/index.html"
| static
| > resource from your web application for you.
| >
| > If you map a servlet to "/", you have just *replaced* the standard
| > processing, because Tomcat will map the request to your servlet
instead
| of
| > the standard one.  Now, let's assume that the user has the rights
they
| > need to access that resource and you want to let them have it.  What
| > should your rights-checking servlet do?
| >
| > That's right ... you're stuck.  There is no way to ask Tomcat to
serve
| the
| > resource, because there is no longer any mapping for the default
| > file-serving servlet.
| >
| > The answer is to use a Filter instead, because a Filter can examine
a
| > request *before* it is given to a servlet, and either intercept it
(not
| > enough access rights) or pass it on (access rights are fine).
| >
| > Do some google searches on "servlet filter" and you will find
pointers
| to
| > some articles about how they work.
| >
| > > Thank you!
| >
| > Craig
| >
| >
| > >
| > > On Sat, 2002-08-10 at 00:40, Craig R. McClanahan wrote:
| > > >
| > > >
| > > > On Fri, 9 Aug 2002, Todd Kaplinger wrote:
| > > >
| > > > > Date: Fri, 09 Aug 2002 17:43:36 -0400
| > > > > From: Todd Kaplinger <[EMAIL PROTECTED]>
| > > > > Reply-To: Tomcat Users List <[EMAIL PROTECTED]>,
| > > > >  [EMAIL PROTECTED]
| > > > > To: [EMAIL PROTECTED]
| > > > > Subject: Re: Problems with *
| > > > >
| > > > > define a servlet mapping of just "/". this is the default
servlet
| mapping.
| > > >
| > > > That's still not going to work for what the proposed use case
was --
| > > > because you've just disabled the default file-serving servlet
that
| serves
| > > > static content.
| > > >
| > > > Craig
| > > >
| > > >
| > > > --
| > > > To unsubscribe, e-mail:   
| > > > For additional commands, e-mail: 
| > > >
| > >
| > >
| > >
| > > --
| > > To unsubscribe, e-mail:   
| > > For additional commands, e-mail: 
| > >
| > >
| >
| >
| > --
| > To unsubscribe, e-mail:   

RE: Accessing Mapped Drives

2002-08-09 Thread Jacob Hookom

XP Pro, but I can put 2000 server on it.

| -Original Message-
| From: David Kavanagh [mailto:[EMAIL PROTECTED]]
| Sent: Friday, August 09, 2002 7:34 AM
| To: Tomcat Users List
| Subject: Re: Accessing Mapped Drives
| 
| I saw this problem with a java2 applet running with the plugin The
file
| dialog could not see mapped drives. I only saw it on Win 98. Windows
| 2000 worked fine. What OS are you running?
| 
| David
| 
| Jacob Hookom wrote:
| 
| >What permissions do I need to setup for Tomcat to be able to access
| >shared network drives on win2k?  I'm able to access shares through an
| >IDE of course, but Tomcat returns null for all io calls to these
mapped
| >drives.
| >
| >If anyone has accomplished this or can point me in the right
direction,
| >I would be much obliged :-)
| >
| >Regards,
| >Jacob Hookom
| >Comprehensive Computer Science
| >University of Wisconsin, Eau Claire
| >
| >
| >
| >---
| >Outgoing mail is certified Virus Free.
| >Checked by AVG anti-virus system (http://www.grisoft.com).
| >Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
| >
| >
| >
| >--
| >To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| >For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| >
| 
| 
| 
| --
| To unsubscribe, e-mail:   <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| For additional commands, e-mail: <mailto:tomcat-user-
| [EMAIL PROTECTED]>
| 
| ---
| Incoming mail is certified Virus Free.
| Checked by AVG anti-virus system (http://www.grisoft.com).
| Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
| 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




Accessing Mapped Drives

2002-08-08 Thread Jacob Hookom

What permissions do I need to setup for Tomcat to be able to access
shared network drives on win2k?  I'm able to access shares through an
IDE of course, but Tomcat returns null for all io calls to these mapped
drives.

If anyone has accomplished this or can point me in the right direction,
I would be much obliged :-)

Regards,
Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




RE: howto avoid overuse of session object?

2002-08-02 Thread Jacob Hookom

I agree, stick to the session itself for purposes of scaling later, just
be smart about the objects you put in there, IE, use singletons and
factories for instances, etc.  There's no need to write your own session
handler.

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Ralph Einfeldt [mailto:[EMAIL PROTECTED]] 
Sent: Friday, August 02, 2002 1:46 AM
To: Tomcat Users List
Subject: AW: howto avoid overuse of session object?

Just to throw in anothe opion :)

I agree with you.

As I understand you want to exchange object between 
two requests of the same session.
If you have information that has a scope that is below 
a session, I don't see any reason to store it with a
scope that is above the session (application or context).

I don't see any benefit at all but several disadvantages. 
If you store the information in the session you have 
following advantages:
- If you have errors in your applications that sometimes 
  forget to remove object, you can at least be shure that 
  they will be removed at the end of the session. (Of 
  course you can implement your own code in a Listener
  that destroys the data from the context or application,
  but why implement something that is done by the container
  anyway)
- If you have to scale your site up to use a loadbalancer 
  with distributed session, this will work only if all
  informations that belong to a session are store in the 
  session (Or you have to write code that serializes the 
  data that you store

The only reason to store this data in a scope that is above
the session level, is to store it in a database instead of 
the memory (e.g. to implement your own distributed/failsafe 
sessions).

Of course it's good practice to reduce the objects in the 
session but not at the price to store them just in different 
scope in memory. What you can do, is reuse objects between 
sessions if the object are the same or to use references. 
E.g. if you have an application that implements a shopping
cart you just need the references to the products that are 
in the basket not the products itself.

In your case I would recommend to store the data in the 
session and to remove them on your own as soon as possible.

One additional advice: give the objects names by using a 
naming convention that makes it unlikely that you add, 
change or remove them by accident.

Ralph Einfeldt
Uptime Internet Solution Center GmbH
Hamburg, Germany
Hosting, Content Management, Java Consulting
http://www.uptime-isc.de 

> -Ursprüngliche Nachricht-
> Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Gesendet: Donnerstag, 1. August 2002 22:33
> An: Tomcat Users List
> Betreff: Re: howto avoid overuse of session object?
> 
> Thanks, Cédric and Peter Lin, for your responses.  Both of 
> you seem to be saying that, instead of storing large objects 
> in the session object, 

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




RE: Request Dispatcher

2002-08-01 Thread Jacob Hookom

I wrote some test cases and figured out that you cannot append
parameters, but you can change their properties, so if you do:

/xmlwrapper/newsTest.html?contentType=44&id=59550

I can regexp and forward

/content/news.jsp?contentType=html&id=59550

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Mike Jackson [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, August 01, 2002 5:08 PM
To: Tomcat Users List
Subject: RE: Request Dispatcher

I don't think so, at least I've never been able to do it.  What I've
done is
added
attributes to the request (see the javadocs for details).  Attributes
only
work
with objects, but that's both an advantage and a disadvantage.

--mikej
-=-
mike jackson
[EMAIL PROTECTED]

> -Original Message-
> From: Jacob Hookom [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, August 01, 2002 3:06 PM
> To: Tomcat Users List
> Subject: Request Dispatcher
>
>
> If I grab a request dispatcher, can I append extra parameters to be
used
> at the destination?
>
> Original request: /app/RDServlet?id=3446
>
> RequestDispatcher rd =
> _context.getRequestDispatcher("/jsp/handler.jsp?ar=html");
> rd.forward();
>
> Is this legit to do?
>
> Jacob Hookom
> Comprehensive Computer Science
> University of Wisconsin, Eau Claire
>
>
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
>
>
>
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
>
>



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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




Request Dispatcher

2002-08-01 Thread Jacob Hookom

If I grab a request dispatcher, can I append extra parameters to be used
at the destination?

Original request: /app/RDServlet?id=3446

RequestDispatcher rd =
_context.getRequestDispatcher("/jsp/handler.jsp?ar=html");
rd.forward();

Is this legit to do?

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 7/24/2002
 


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




RE: Xalan performance within Tomcat

2002-07-24 Thread Jacob Hookom

I just posted the source for a TEST with filtering; it basically acts
like cocoon, but doesn't fall into cocoon's big-brother implementation

http://www.swanked.net/xml/axalon/

It's being served off of my cable modem, so excuse speeds

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-----
From: Jacob Hookom [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 10:20 PM
To: 'Tomcat Users List'
Subject: RE: Xalan performance within Tomcat

I just finished a Pooling implementation that works with Servlets and
Filters that works to compile XSL much like JSP's... performance went
from 2900ms to 100ms for formatting of xml documents.

I'm still working on abstracting it to work with FOP in the same manner.

If you are interested in the code, email me directly.

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 

-Original Message-
From: Ralph Einfeldt [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 12:55 AM
To: Tomcat Users List
Subject: AW: Xalan performance within Tomcat

As the original post says that the cpu performance was lower
for the servlet application, it sounds to me as if tomcat 
and the servlet fight for the same restricted resource.

I just can give the advice to monitor the system
to see any differences. (Watch for swapping, paging,
disk io, use a profiler to see what happens, trace 
system calls)

> -Ursprüngliche Nachricht-
> Von: Will Hartung [mailto:[EMAIL PROTECTED]]
> Gesendet: Montag, 22. Juli 2002 19:21
> An: Tomcat Users List
> Betreff: Re: Xalan performance within Tomcat
> 
> > Can anyone think of anything, either java related, Tomcat 
> > related, xalan related, etc. that would cause the time for 
> > the same transform to be much much slower from within a 
> > servlet running in Tomcat as opposed to a test program run 
> > from command line.
> 

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Xalan performance within Tomcat

2002-07-23 Thread Jacob Hookom

I just finished a Pooling implementation that works with Servlets and
Filters that works to compile XSL much like JSP's... performance went
from 2900ms to 100ms for formatting of xml documents.

I'm still working on abstracting it to work with FOP in the same manner.

If you are interested in the code, email me directly.

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 

-Original Message-
From: Ralph Einfeldt [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 12:55 AM
To: Tomcat Users List
Subject: AW: Xalan performance within Tomcat

As the original post says that the cpu performance was lower
for the servlet application, it sounds to me as if tomcat 
and the servlet fight for the same restricted resource.

I just can give the advice to monitor the system
to see any differences. (Watch for swapping, paging,
disk io, use a profiler to see what happens, trace 
system calls)

> -Ursprüngliche Nachricht-
> Von: Will Hartung [mailto:[EMAIL PROTECTED]]
> Gesendet: Montag, 22. Juli 2002 19:21
> An: Tomcat Users List
> Betreff: Re: Xalan performance within Tomcat
> 
> > Can anyone think of anything, either java related, Tomcat 
> > related, xalan related, etc. that would cause the time for 
> > the same transform to be much much slower from within a 
> > servlet running in Tomcat as opposed to a test program run 
> > from command line.
> 

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Filter order of operation

2002-07-23 Thread Jacob Hookom

Cheers, I did a search previously on sun's site but everything seemed to
only skim the surface.

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 1:13 PM
To: Tomcat Users List
Subject: Re: Filter order of operation



On Tue, 23 Jul 2002, Jacob Hookom wrote:

> Date: Tue, 23 Jul 2002 12:54:52 -0500
> From: Jacob Hookom <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: Filter order of operation
>
> I know that a single request can come through multiple Filters in a
> chain, I'm wondering if there's any reliable way to ensure precedence
in
> the chain of operation?
>

Browse to <http://java.sun.com/products/servlet/download.html>.

Download the Servlet 2.3 specification.

Read Chapter 6 -- in particular 6.2.4.

> Jacob Hookom
> Comprehensive Computer Science
> University of Wisconsin, Eau Claire
>

Craig


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




Filter order of operation

2002-07-23 Thread Jacob Hookom

I know that a single request can come through multiple Filters in a
chain, I'm wondering if there's any reliable way to ensure precedence in
the chain of operation?

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Help with chaining servlets via filters

2002-07-23 Thread Jacob Hookom

http://www.javaworld.com/javaworld/jw-06-2001/jw-0622-filters.html

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 10:47 AM
To: Tomcat Users List
Subject: Re: Help with chaining servlets via filters



On Tue, 23 Jul 2002, John Rishea wrote:

> Date: Tue, 23 Jul 2002 06:33:57 -0600
> From: John Rishea <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat User Group <[EMAIL PROTECTED]>
> Subject: Help with chaining servlets via filters
>
> Could someone please point me toward a good resource that shows an
example
> of chaining two servlets using a filter?  I've found lots of filter
examples
> during my google searches but none of them shows exactly how to chain
two
> servlets together with a filter.
>

What are you trying to accomplish by "chaining two servlets using a
filter"?  The traditional definition of servlet chaining (feeding the
output of one servlet into another) has turned out to be a very bad
design
pattern, so it's not supported.

On the other hand, filters themselves can modify input on the way in,
and
output on the way out.  And you can easily configure more than one
filter
to be mapped to a particular request.

It all comes down to what you are trying to accomplish.

> Thanks for the help.
>
> __
> John Rishea

Craig


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Xalan performance within Tomcat

2002-07-23 Thread Jacob Hookom

What are you exactly doing to do the transformations?  There seems to be
about a dozen ways you could go about it setting up the Templates and
the transformation

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Ralph Einfeldt [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 23, 2002 12:55 AM
To: Tomcat Users List
Subject: AW: Xalan performance within Tomcat

As the original post says that the cpu performance was lower
for the servlet application, it sounds to me as if tomcat 
and the servlet fight for the same restricted resource.

I just can give the advice to monitor the system
to see any differences. (Watch for swapping, paging,
disk io, use a profiler to see what happens, trace 
system calls)

> -Ursprüngliche Nachricht-
> Von: Will Hartung [mailto:[EMAIL PROTECTED]]
> Gesendet: Montag, 22. Juli 2002 19:21
> An: Tomcat Users List
> Betreff: Re: Xalan performance within Tomcat
> 
> > Can anyone think of anything, either java related, Tomcat 
> > related, xalan related, etc. that would cause the time for 
> > the same transform to be much much slower from within a 
> > servlet running in Tomcat as opposed to a test program run 
> > from command line.
> 

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




Getting Filter url-pattern

2002-07-22 Thread Jacob Hookom

Is it possible to get the url-pattern of the Filter during the
init(FilterConfig)?

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Xalan performance within Tomcat

2002-07-22 Thread Jacob Hookom

Have you tried translets?

Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 


-Original Message-
From: Will Hartung [mailto:[EMAIL PROTECTED]] 
Sent: Monday, July 22, 2002 12:21 PM
To: Tomcat Users List
Subject: Re: Xalan performance within Tomcat

From: "Mario Felarca" <[EMAIL PROTECTED]>
Sent: Sunday, July 21, 2002 3:50 PM
Subject: Re: Xalan performance within Tomcat


> At 09:57 PM 7/17/2002 +, you wrote:
>
> I am bumping my thread in the hopes that some people may not have seen
it
> before, or that others may have come across some new ideas.
>
> Also, for informational purposes, the time that I am actually
measuring is
> the actual time that the transform call takes. In both cases, the
Source
is
> a StreamSource that has a ByteArrayInputStream at its base, and the
Result
> is a StreamResult that is going to a ByteArrayOutputStream.
>
> Can anyone think of anything, either java related, Tomcat related,
xalan
> related, etc. that would cause the time for the same transform to be
much
> much slower from within a servlet running in Tomcat as opposed to a
test
> program run from command line.

This probably won't help, but it's fuel for the fire.

If you think about it, once code is running, the only real difference
between a command line program and a Servlet running in Tomcat will be
its
environment.

Then, you can think of what in the environment may be affecting your
program.

The key distinctions that come to mind is that in Tomcat you have a
completely different ClassLoader environment and, probably, a much more
complex threading environment.

Now, I'm assuming that your 6-8 minute servlet is simple a single
request
with "nothing else" going on.

But the only thing I can think of is that your servlet is stuck waiting
on
something, though I can't imagine what. I would like to think that the
XLST
engine is distinct from any other, potential, engines within the same
JVM
(perhaps something that Tomcat is using internally).

I can't fathom why the ClassLoaders would be dramatically different.

You may simply need to try some profiling tool to see where your code is
all
hung up, or perhaps start making some stack dumps to see if anything
comes
to the top. Even the basic tools that come with Java should be more that
adequate to point out the culprits.

But, all in all, it just sounds to me that there is some kind of
contention
issue fighting within the code. Somebody is waiting for something.

If you find out what the issue is, be sure to report back so we all can
learn something.

Sorry I couldn't be much more help.

Best Regards,

Will Hartung
([EMAIL PROTECTED])




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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: Changes to File System

2002-07-22 Thread Jacob Hookom

Thanks!

-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]] 
Sent: Monday, July 22, 2002 10:29 AM
To: Tomcat Users List
Subject: Re: Changes to File System



On Mon, 22 Jul 2002, Jacob Hookom wrote:

> Date: Mon, 22 Jul 2002 03:03:41 -0500
> From: Jacob Hookom <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: Tomcat Users List <[EMAIL PROTECTED]>
> Subject: Changes to File System
>
> How does tomcat handle monitoring of changes to the file system?
>
> IE, if the JSP is changed and requires re-compiling, or a class is
> modified
>

The general tool used is to call File.lastModified() on the
corresponding
file.  For JSP pages, this is done on every request.  For classes (in
WEB-INF/classes and WEB-INF/lib only) it is done in a background thread
that is started for webapps that have autoload support turned on.

> Best Regards,
> Jacob Hookom
> Comprehensive Computer Science
> University of Wisconsin, Eau Claire
>

Craig

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




Changes to File System

2002-07-22 Thread Jacob Hookom

How does tomcat handle monitoring of changes to the file system?

IE, if the JSP is changed and requires re-compiling, or a class is
modified

Best Regards,
Jacob Hookom 
Comprehensive Computer Science 
University of Wisconsin, Eau Claire 



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: in web.xml

2002-07-17 Thread Jacob Hookom

Usually servlets are lazy-loaded, meaning, the init() method of the
servlet is not called until a user makes a request to it for the first
time.  By putting the load-on-startup with an integer as a value, then
you force the servlet to call init() on startup.  This may be
advantageous as you may want to read in configuration files or set
application properties with your servlet.



   action
   org.apache.struts.action.ActionServlet
   
 config
 /WEB-INF/struts-config.xml
   
   
 debug
 2
   
   
 detail
 0
   
   2


Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]

Sent: Wednesday, July 17, 2002 2:16 AM
To: Tomcat Users List
Subject:  in web.xml

Hi,

What's the use of the "load-on-startup" element in web.xml?

Thanks.

Jc


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: DataSource Access - Design Question

2002-07-15 Thread Jacob Hookom

Maier Holger wrote:
Wouldn't it be better to read the
data source once in a singleton class
and then just get it back, i.e.

I did the same thing with my application where I did a key/value storage
object that was a singleton in my ServletContext.  I did notice a slight
speed improvement and I've had zero issues.

//example factory configured by properties file
DataSourceFactory dsf =
DataSourceFactory.getInstance(servlet.getServletContext());
DataSource ds = dsf.getDataSource("hrdb");


Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: Maier Holger, ITS-AKIS [mailto:[EMAIL PROTECTED]] 
Sent: Monday, July 15, 2002 9:29 AM
To: 'Tomcat Users List'
Subject: DataSource Access - Design Question

Hi,
I am trying to get my DataSource 
(with Connection Pooling) to run.

In the examples one always gets the 
DataSource from JNDI and I have the 
impression that everytime I want
to get my connection from DataSource
via a Context lookup.

Wouldn't it be better to read the
data source once in a singleton class
and then just get it back, i.e. 

private DataSource ds;
...
public static void getDataSource() {
   // if data source unknown read it from context
   if (ds == null) {
 try {
   Context ctx = new InitialContext();
   ds = (DataSource) ctx.lookup("java:comp/env/jdbc/myDataSource");
 }
 catch (..) {..}
   }
 
   return ds;   
}

This should be faster than accessing the context
every time you need a datasource or a connection.

Could this lead into problems?
Any suggestions?

Cheers,
Holger

-
Holger Maier  Tel.:  (06831) 47-3497
ITS-AKIS  eMail: [EMAIL PROTECTED]

AG der Dillinger Hüttenwerke
Postfach 1580
66748 Dillingen


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: jdk1.4 vs jdk1.2

2002-07-14 Thread Jacob Hookom

I'm running 4.0.4 with 4.1.7's jasper and commons packages with jdk1.4
installed.  I had to make quite a few modifications to my application
code (mainly in my own taglibs because of the difference in the way tag
pooling handled my page execution).  Also, you need to make sure any
changes you make to your system itself, be sure to dump your working
directory for tomcat.

Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: Luminous Heart [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, July 14, 2002 3:51 PM
To: Tomcat Users List; Joe Schiavone
Subject: jdk1.4 vs jdk1.2

Tomcat 4.1.7 fails to compile any jsp files giving
some stupid error about handleException. If I change
the JDK to 1.2 everything works fine. Is tomcat4.1.x
allergic to jdk1.4?


__
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com

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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




[FIXED] RE: how to make tomcat faster [jasper error]

2002-07-13 Thread Jacob Hookom

I had to dump my working directory... thanks though for the speed tips.

Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: Jacob Hookom [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, July 13, 2002 11:21 AM
To: 'Tomcat Users List'
Subject: RE: how to make tomcat faster [jasper error]

I followed your example of importing the 4 jars from 1.7 to 0.4, but my
pages now are not displaying on the basis of:

javax.servlet.ServletException:
org.apache.jasper.runtime.HttpJspBase.getIncludes()Ljava/util/List;
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:243)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.ja
va:566)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
72)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)

I'm just wondering what may be causing this.  My page declare is:

<%@ page language="java" errorPage="errors/error_disp.jsp" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/dds.tld" prefix="dds" %>

if anyone can help me out, I would REALLY appreciate it!

Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: Reynir Hübner [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, July 13, 2002 9:05 AM
To: Tomcat Users List
Subject: RE: how to make tomcat faster

well to install jasper from the 4.1.7 you only need to take 2 or 3 jar
files and replace the old ones in tc 4.0.4.

the jar files are from 
tc.4.1.7 : 

common/lib/jasper-compiler.jar
common/lib/jasper-runtime.jar
common/lib/commons-collections.jar

and if I remember it correctly I also moved the : 
common/lib/ant.jar 

to my tc.4.0.3 installation.


I am sorry but I will not explain connection pooling here, as it's been
done serveral times and you can search the mail-archive for information
on that matter, I use a pool from www.bitmechanic.com, but there are
several others available. Even sometimes a pool is distributed with the
JDBC driver, I'm not sure about the free one from microsoft, but it
might have some pooling implemented.
Caching is something you need to implement into your jsp-pages, it's
usually done by using cache-tags that implement "fine-grain-cacheing",
this will make you able to decide for how long each segment of your
response is cached. I've been using OSCache, from www.opensymphony.org,
there is also a cache-taglib in the jakarta domain. 

My guess is if you do this, your application will get 5 times faster
than it is right now maybe even alot more depending on how you do
it.
About the System.out.println, you should just implement Log4j logging,
it's powerfull, and easy to use. 

There are many things you could look at, for example, if you are using
HashMaps alot, you might find it alot faster to use FastHashMap, or if
you are using Vectors alot you might find it faster to use/iterate
through LinkedLists, if you are using out.write alot, you might want to
make use of StringBuffer, append to it while rendering the jsp, and only
writing that to the response (one out.write instead of many.. it should
be a little bit faster). 

For benchmark-testing I've used both jmeter and "Microsofts
Web-Application Stress Tool", and here I recomend the MS tool, it's very
powerfull, and gives you good reports.

hope it helps

 - [EMAIL PROTECTED]




> -Original Message-
> From: Anoop Kumar V [mailto:[EMAIL PROTECTED]]
> Sent: 13. júlí 2002 13:51
> To: 'Tomcat Users List'
> Subject: RE: how to make tomcat faster
> 
> 
> hi,
> 
> OK..maybe i shd hv included that in my first message..anyway its here.
> 
> This application has considerable database work with a few 
> reports thrown in
> here
> and there. I have just one servlet, remaining are all jsp's 
> (about 50 jsp's)
> and about 25 beans and other class files(MVC). I use MS-SQL 
> Server as the
> database.
> no connection pooling.. as i felt the number of users are too 
> small(100 -
> 250 
> at peak time) and yes, every request fetches info from the 
> database. So i
> guess
> i need to know how to enable connection pooling.
> Also the cache part.. 

RE: how to make tomcat faster [jasper error]

2002-07-13 Thread Jacob Hookom

I followed your example of importing the 4 jars from 1.7 to 0.4, but my
pages now are not displaying on the basis of:

javax.servlet.ServletException:
org.apache.jasper.runtime.HttpJspBase.getIncludes()Ljava/util/List;
at
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:247)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:193)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:243)
at
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.ja
va:566)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:4
72)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)

I'm just wondering what may be causing this.  My page declare is:

<%@ page language="java" errorPage="errors/error_disp.jsp" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/dds.tld" prefix="dds" %>

if anyone can help me out, I would REALLY appreciate it!

Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net
you're not hip enough yet

-Original Message-
From: Reynir Hübner [mailto:[EMAIL PROTECTED]] 
Sent: Saturday, July 13, 2002 9:05 AM
To: Tomcat Users List
Subject: RE: how to make tomcat faster

well to install jasper from the 4.1.7 you only need to take 2 or 3 jar
files and replace the old ones in tc 4.0.4.

the jar files are from 
tc.4.1.7 : 

common/lib/jasper-compiler.jar
common/lib/jasper-runtime.jar
common/lib/commons-collections.jar

and if I remember it correctly I also moved the : 
common/lib/ant.jar 

to my tc.4.0.3 installation.


I am sorry but I will not explain connection pooling here, as it's been
done serveral times and you can search the mail-archive for information
on that matter, I use a pool from www.bitmechanic.com, but there are
several others available. Even sometimes a pool is distributed with the
JDBC driver, I'm not sure about the free one from microsoft, but it
might have some pooling implemented.
Caching is something you need to implement into your jsp-pages, it's
usually done by using cache-tags that implement "fine-grain-cacheing",
this will make you able to decide for how long each segment of your
response is cached. I've been using OSCache, from www.opensymphony.org,
there is also a cache-taglib in the jakarta domain. 

My guess is if you do this, your application will get 5 times faster
than it is right now maybe even alot more depending on how you do
it.
About the System.out.println, you should just implement Log4j logging,
it's powerfull, and easy to use. 

There are many things you could look at, for example, if you are using
HashMaps alot, you might find it alot faster to use FastHashMap, or if
you are using Vectors alot you might find it faster to use/iterate
through LinkedLists, if you are using out.write alot, you might want to
make use of StringBuffer, append to it while rendering the jsp, and only
writing that to the response (one out.write instead of many.. it should
be a little bit faster). 

For benchmark-testing I've used both jmeter and "Microsofts
Web-Application Stress Tool", and here I recomend the MS tool, it's very
powerfull, and gives you good reports.

hope it helps

 - [EMAIL PROTECTED]




> -Original Message-
> From: Anoop Kumar V [mailto:[EMAIL PROTECTED]]
> Sent: 13. júlí 2002 13:51
> To: 'Tomcat Users List'
> Subject: RE: how to make tomcat faster
> 
> 
> hi,
> 
> OK..maybe i shd hv included that in my first message..anyway its here.
> 
> This application has considerable database work with a few 
> reports thrown in
> here
> and there. I have just one servlet, remaining are all jsp's 
> (about 50 jsp's)
> and about 25 beans and other class files(MVC). I use MS-SQL 
> Server as the
> database.
> no connection pooling.. as i felt the number of users are too 
> small(100 -
> 250 
> at peak time) and yes, every request fetches info from the 
> database. So i
> guess
> i need to know how to enable connection pooling.
> Also the cache part.. there are some entries in server.xml 
> which seem to say
> "save session on restart", but i was not sure so i hv left 
> them alone. So
> tell me how
> can i enable cache too. 
> There is hardly any static content in my application, and 
> what i meant was a
> relative
> slow down compared to when Tomcat was stand-alone (or with 
> Apache). Yes,
> even i am using
> AJP1.3 connec

[HELP!!] Tomcat 4.13 PageContextImpl.popBody() Exception

2002-07-12 Thread Jacob Hookom

The taglib I wrote for 4.04 isn't working correctly in 4.13 (big
surprise).  Struts 1.1b executes fine in 4.13.

In my tag library, I use the method:
this.findAncestorWithClass( this, Class.forName("some.Tag") );

This is done get the parent tag and modify its properties.

This works fine in 4.04, but in 4.13 Jasper throws an exception from:
PageContextImpl.popBody().

java.util.EmptyStackException
at java.util.Stack.peek(Stack.java:79)
at java.util.Stack.pop(Stack.java:61)
at
org.apache.jasper.runtime.PageContextImpl.popBody(PageContextImpl.java:4
40)

I notice there's the nested implementation now, is this something I
should be extending or working from instead of the findAncestor?  Maybe
I'm completely off the source of the problem.  I did read that tags are
stored in a map essentially with a "toPop" Boolean value.  If so, what
dictates this value?

Jacob Hookom
CS Student
University of Wisconsin, Eau Claire
===
http://www.swanked.net


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


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




RE: mail server

2002-07-12 Thread Jacob Hookom

JAMES!

-Original Message-
From: Jonathan Zhang [mailto:[EMAIL PROTECTED]] 
Sent: Friday, July 12, 2002 6:06 PM
To: Tomcat Users List
Subject: mail server

hi,  does any know a free and excellent mail server?


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.375 / Virus Database: 210 - Release Date: 7/10/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: How to hide a download file

2002-07-11 Thread Jacob Hookom

I'm going to have to inevitably add it to my site soon, I was going to
approach it the same way, but with a servlet isn't it possible to pipe a
file by setting the response mime type and streaming it out as a PDF or
EXE.  Of course IE does it's own thing no matter the mime type. 

-Original Message-
From: Alex Short [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, July 11, 2002 11:36 AM
To: Tomcat Users List
Subject: Re: How to hide a download file

Certainly not the most elegant solution but you could keep the real file

in a unreachable location, and upon submitting it copy's the file to a 
cookie_date_time_filename.ext and has them download that.  Then you run
a 
cleaner script to erase these temp files after 24 hours.

Alex

 > Hi all, > 
> I need to pick your brains again.
> 
> I need to publish a site that requires a user to fill in a form before
> displaying a download link.
> 
> What I need to do is to hide the file to be downloaded so that it
cannot be
> downloaded without the form being filled in - i.e it can only be
downloaded
> from a particular generated JSP page.
> 
> Can I do this with Tomcat?
> 
> Thanks in advance.
> 
> 
> Kevin 
> 
> --
> To unsubscribe, e-mail:

> For additional commands, e-mail:

> 
> 
> 
> 


--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: log4j:ERROR No appenders could be found for category (org.apache.commons.digester.Digester).

2002-07-09 Thread Jacob Hookom

I ran into this problem when I updated to struts 1.1b1 since it already
includes log4j implementations and my project had separately included
the log4j.jar in my app's lib directory, it was causing problems.  As
soon as I removed the extra log4j.jar, then things ran fine without
errors.

I don't know if it is the same issue, but I was getting the exact same
errors as you.

-Jake

-Original Message-
From: Lenny Sorey [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, July 09, 2002 2:55 PM
To: Tomcat Users Group
Subject: log4j:ERROR No appenders could be found for category
(org.apache.commons.digester.Digester).


The following error is shown in Tomcat 4.1.3 Stderr.log 

log4j:ERROR No appenders could be found for category
(org.apache.commons.digester.Digester).
log4j:ERROR Please initialize the log4j system properly.



*
log4j.properties under the WEB-INF Subdirectory is as follows:

# Set root category priority to DEBUG and its only appender to A1.
log4j.rootCategory=DEBUG, A1
  
# A1 is set to be a ConsoleAppender. 
log4j.appender.A1=org.apache.log4j.ConsoleAppender
  
# A1 uses PatternLayout.
log4j.appender.A1.layout=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n


*
   

Anyone got any suggestions as why log4j is not initializing properly?

Platform is as follows:

Windows 2000 Professional
J2SDK 1.4.0
Tomcat 4.1.3
Log4j Version 1.1.3
Turbine 2.1b4
Velocity -1-2 dev jar

Thanks In Advance

Lenny Sorey



--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.373 / Virus Database: 208 - Release Date: 7/1/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: URGET - NEED HELP

2002-06-30 Thread Jacob Hookom

Do you have any firewall software running like black ice?  Software like
that will give you the same results as you described.

-Original Message-
From: Vlad [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, June 30, 2002 11:55 AM
To: Tomcat Users List
Subject: URGET - NEED HELP

I can't seem to get tomcat to run as a standalone web server. I have a
webapp that is almost entirely dynamic so I do not want to use the
apache/tomcat combo, I just want tomcat. I have two nics in my system, a
public and a private one (this box also functions as a NAT server) when
I configure tomcat to run on port 8080 then everything is fine, but when
I tell it to run on port 80 then I can only access the webapp from
within the private network (even if I use the public ip) but I can't see
the webapp from the public network. I tried telneting to port 80 from
the public network and it connects but when I do "GET /" (which normally
returns something) I get nothing, I looked at the tomcats access logs
and it doesn't have an entry for these requests. ANY HELP WOULD BE GREAT
- THIS IS REALLY URGENT

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Large File Transfer : Coyote Connector Crash [isHexDigit]

2002-06-25 Thread Jacob Hookom

Remy Maucherat wrote:
> Are you actualy using a POST with a URL FORM encoding ? In which case,

> sorry, but it's a really bad idea to do that."

Are there alternatives?  The goal of this process is to ease image
transfer to a publishing server by people who haven't a clue on how to
utilize ftp, or their mail servers do not permit large file attachments.

My implementation is the same as the upload example included with the
struts-upload.war.  File transfers of 141MB will crash the VM at 114MB
for example.  So the file is reaching the server and midway through
'storing it', but crashes the VM midway through.

The only thing I notice is that the Coyote connector throws
java.io.CharConversionException: isHexDigit

Thanks,
Jake



--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Large File Transfer : Coyote Connector Crash

2002-06-25 Thread Jacob Hookom

I'm running 4.0.4 with the Coyote connector.  Part of my site has to do
with large file transfer-- uploaded via page form.   When large files
are uploaded (>50MB), the Coyote connector along with Tomcat will just
crash.  The uploading is done through the newest Struts release.

Has anyone run into this problem?  Or, is there a setting in tomcat to
widen a buffer of some sorts?

Regards,
Jake Hookom

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Design Question: Static vs. Dynamic

2002-06-24 Thread Jacob Hookom

Hello All,

I've been constructing a site for a corporate intranet using, of course,
JSP and Struts Actions.  The functionality of the site is basically a
wrapper for a Database whereby each table of information has the
Insert/Modify/Delete operation available through JSPs.  I can expect
30-50 concurrent users on the site at any given time.

Is it traditional practice to write long term data to static html like
large scale sites such as cnet, or zdnet (links such as
1109200304,43904043A,44032.html)?  If so, how do they bring in dynamic
elements?  Or, in your own experience, have you found benefits from
transferring bits of page content to static hmtl (OSCache for example)?

Best Regards,
Jake

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Tomcat 4 performance issues - Trying Tomcat 4.1.3 Beta

2002-06-23 Thread Jacob Hookom

I have found performance problems with the new Coyote connector, it runs
fine initially, but after about 2 hours of simple operation, it hangs on
page requests at 4-6 seconds while at the same time, I can hit the
standard HTTP connector on a different port, and requests are handled as
expected (ms level).

-Original Message-
From: Remy Maucherat [mailto:[EMAIL PROTECTED]] 
Sent: Sunday, June 23, 2002 3:04 PM
To: Tomcat Users List
Subject: Re: Tomcat 4 performance issues - Trying Tomcat 4.1.3 Beta

Reynir Hübner wrote:
> Victor & the others..
> 
> I've tested tc 4.1.5 and I get very similar problems as I did with tc.
4.1.3.
> 
> if I stress/load my application with 10*10 threads I get messages like
this on the stdout log : 
> 
> ThreadPool: Caught exception executing
org.apache.tomcat.util.net.TcpWorkerThread@422a3b, terminating thread
> java.lang.OutOfMemoryError
> <>
> java.lang.OutOfMemoryError
> <>
> 
> I increased the memory for jvm to 256mb and now tomcat "runs", but
executes everything alot (aprox 15-20 times) slower than tc 4.03 so I'm
sticking to that for now, at least I would not use tc4.1.5 for
production as it is right now. 

I would be interested in finding out the cause of the leak (obviously). 
Fixing it is probably going to be really obvious once we find it.

I assume it is Jasper. Did you find anything which would indicate 
otherwise ?

Remy


--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Tyrex Driver Renamed

2002-06-21 Thread Jacob Hookom

Hello,

I just downloaded Tomcat 4.0.2 and I installed the Tyrex driver and
properly configured my Server.xml.  The problem is that Tomcat is
looking for tyrex.jdbc.xa.EnabledDataSource
(java.lang.NoClassDefFoundError), but the 1.0 release of Tyrex (the only
one available at their site) has renamed it to
tyrex.resources.jdbc.xa.EnabledDataSource.

Does anyone know of a work around for this without recompiling Tomcat?
Or, if someone has an earlier version of the Driver they can provide me?

Best Regards,
Jake Hookom

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.371 / Virus Database: 206 - Release Date: 6/13/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: PAUL ...customize error page ini Servlet

2002-05-17 Thread Jacob Hookom

Since you want to only setup your error pages once in the XML, on the
servlet you can do (I believe)

HttpServletResponse.sendError( int );

HttpServletResponse.sendError( HttpServletResponse.SC_FORBIDDEN );

And it will automatically forward to the appropriate pre-configured 404,
405, etc error pages.  

-Original Message-
From: Paul Balanoiu [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, May 17, 2001 7:31 AM
To: Tomcat Users List
Subject: Re: PAUL ...customize error page ini Servlet

In the request (javax.servlet.request) you have the following method:
public RequestDispatcher getRequestDispatcher(java.lang.String path)

where you specify the new path.
With the RequestDispatcher you can do the forwarding. Simply call the

public void forward(ServletRequest request, ServletResponse response)

method.
Be carefull not to commit any writes in the initial servlet (uncommited
data
is automatically cleared, commited data results in an exception).

Paul

PS: The path should be something like this: "/pathtoerrorpage", and is
interpreted as a relative path in the application (a relative path
starting
from the context root).


- Original Message -
From: "Vaneet Sharma" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Friday, May 17, 2002 3:20 PM
Subject: RE: PAUL ...customize error page ini Servlet


i am using servlets .. can you tell me the code .. how to do in servlets
chao

-Original Message-
From: Paul Balanoiu [mailto:[EMAIL PROTECTED]]
Sent: 17 May 2001 13:18
To: Tomcat Users List
Subject: Re: customize error page ini Servlet


1. If you intend to use custom error pages for errors that are generated
by
tomcat (page not found for example), in the XML descriptor of the web
application you can add tags like this one:

  
404
ErrorPage.jsp
  

2. If you want to send the user to a page (i.e. LoginError.jsp for
example,
when your code detected that the user/pass combination is invalid), the
 tag will do just fine.

Paul

- Original Message -
From: "Vaneet Sharma" <[EMAIL PROTECTED]>
To: "'Tomcat Users List'" <[EMAIL PROTECTED]>
Sent: Friday, May 17, 2002 1:32 PM
Subject: RE: customize error page ini Servlet




-Original Message-
From: Vaneet Sharma [mailto:[EMAIL PROTECTED]]
Sent: 17 May 2002 12:27
To: 'Tomcat Users List'
Subject: customize error page ini Servlet


Dear
  friends
  can anyone tell me how to customize error page in Servlet. when an
error
comes in my application, i want the user to redirected to my error page
displaying the error.
   i am using velocity with Servlets on Tomcat 4.0.2 with JDK1.3


-Original Message-
From: Luca Ventura [mailto:[EMAIL PROTECTED]]
Sent: 17 May 2002 09:42
To: Tomcat Users List
Subject: R: Ref. : How can I redirect only JSP pages to Tomcat?


ThanksI will try you solution but I hope someone else has already
solved
this problem:-)
Sorry..but I don't know how to put IIS and tomcat on different machine:
I am
curious to know how to do too! :-(

Regards,

   Luca

-Messaggio originale-
Da: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Inviato: venerdi 17 maggio 2002 8.55
A: Tomcat Users List
Oggetto: Ref. : How can I redirect only JSP pages to Tomcat?



I have the same problem.
You can try to add :forwardAll="false" noRoot="false" in the
IIS listener of your context in server.xml
I've seen in tomcat doc this manip permits to redirect only Jsp&servlets
but it doesn't work for me.
Good luck!

Jc

ps: Do you know how can I put IIs & tomcat on different machines?


--
To unsubscribe, e-mail:

For additional commands, e-mail:




--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:




--
To unsubscribe, e-mail:

For additional commands, e-mail:


--
To unsubscribe, e-mail:

For additional commands, e-mail:




--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: User LogIn/LogOut

2002-05-17 Thread Jacob Hookom

You could put an object in the session and in its finalize, it calls a
static method on another object that is the 'logger' in this case,
sending the user's UID.

-Original Message-
From: RamNivas [mailto:[EMAIL PROTECTED]] 
Sent: Friday, May 17, 2002 5:35 AM
To: [EMAIL PROTECTED]
Subject: User LogIn/LogOut

Dear All,

I am having Tomcat Running on WinNT4.0.

i want to track the user loggins and logouts  time  for inserrting in
database.Using jsp how can i track the time user closes the browser or
logout .
i tried using JSP distroy method . but i'm having some troubles with
htat
can someone send me a working example of JSP distroy or any good method
of
tackling this problem
regards  Ram




--
To unsubscribe, e-mail:

For additional commands, e-mail:


---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Heap Size for Tomcat

2002-05-16 Thread Jacob Hookom

So the correct solution is to modify the startup/shutdown command line
or to setup TOMCAT_OPTS/CATALINA_OPTS?

Thanks again for the replies!
Jake Hookom

-Original Message-
From: Phillip Morelock [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, May 16, 2002 6:46 PM
To: Tomcat Users List
Subject: Re: Heap Size for Tomcat

i actually sent an email regarding this to the list about two weeks ago.

I believe you are correct -- but I have found (only anecdotally) that
the
shutdown one doesn't have a negative impact, because on my platform at
least
(linux) -- even though the Virtual size allocated is huge, the resident
set
size doesn't grow any more quickly than it actually should (apparently
at
least, again I've only experimented with this on Linux).

cheers
fillup


On 5/16/02 4:46 PM, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:

> 
> Well, yeah except  he wants to get more memory... and wouldn't setting
the
> XXXOPTS variable set the heap size not just for startup but also
shutdown?
> In other words, this way you could get tomcat to start with 512mb of
heap,
> but if you call shutdown.bat/shutdown.sh,  the shutdown vm grabs its
own
> 512mb heap... I dunno...
> 
> troy
> 
> 
> 
> 
>  
> Phillip Morelock
>  List <[EMAIL PROTECTED]>
> relock.com>  cc:
>  Subject: Re: Heap
Size
> for Tomcat   
> 05/16/2002 06:19 PM
> Please respond to
> "Tomcat Users List"
>  
>  
> 
> 
> 
> 
> The "official" way to do it is to set a
> TOMCAT_OPTS
> or
> CATALINA_OPTS
> 
> variable with the string that you would normally feed the VM.  (like
-Xms
> or
> whatever).  TOMCAT is for 3.x, CATALINA is for 4.x
> 
> cheers
> fillup
> 
> 
> 
> On 5/16/02 3:57 PM, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> 
>> 
>> my understanding is that any parameters you pass to bin/startup.bat
or
>> bin/startup.sh on the command line will be passed through to the java
vm,
>> such as mx128m or -D property=something .
>> 
>> 
>> 
>> 
>> 
>> 
>> "Jacob Hookom"
>> <[EMAIL PROTECTED] To:  "'Tomcat Users
> List'"
>> <[EMAIL PROTECTED]>
>> du>  cc:
>>  Subject: Heap Size for
> Tomcat
>> 05/16/2002 01:57
>> PM
>> Please respond
>> to "Tomcat Users
>> List"
>> 
>> 
>> 
>> 
>> 
>> 
>> Hello All,
>> 
>> I was wondering where I can modify the initial heap size settings for
>> tomcat to use.  Or more primarily, where the command line is that
tomcat
>> uses to initialize its VM.
>> 
>> Thanks,
>> Jake Hookom
>> 
>> ---
>> Outgoing mail is certified Virus Free.
>> Checked by AVG anti-virus system (http://www.grisoft.com).
>> Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
>> 
>> 
>> 
>> --
>> To unsubscribe, e-mail:   <
>> mailto:[EMAIL PROTECTED]>
>> For additional commands, e-mail: <
>> mailto:[EMAIL PROTECTED]>
>> 
>> 
>> 
>> 
>> 
>> 
>> --
>> To unsubscribe, e-mail:   <
> mailto:[EMAIL PROTECTED]>
>> For additional commands, e-mail: <
> mailto:[EMAIL PROTECTED]>
>> 
> 
> 
> --
> To unsubscribe, e-mail:   <
> mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <
> mailto:[EMAIL PROTECTED]>
> 
> 
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
> 


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

---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
 


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




  1   2   >