You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Remy Maucherat <re...@exoffice.com> on 2000/04/29 08:05:36 UTC

[Catalina] [Patch] Small tweaks and fixes

I had a look at Catalina, and first of all, I must say I'm impressed by how
clean the code is.
I'm still not very familiar with it, though.

Random facts :
- After toying a bit with the config, the DummyContainer works :-)

While I was toying with Catalina, I fixed the following (diffs follow) :
- Typo at line 357 of ContextConfig.java
- Missing strings in core.LocalStrings.properties
- Temporary fix to init of the StandardWrapper
- setBasic(Valve) never updates the basic valve if basic == null before
calling the function. I think it was not a normal behavior, so I fixed that.
- Fixed a bug in AccessLogValve (StringIndexOutOfBoundsException: String
index out of range: -6)
at org.apache.tomcat.valves.AccessLogValve.replace(AccessLogValve.java:524)
at org.apache.tomcat.valves.AccessLogValve.invoke(AccessLogValve.java,
Compiled Code)

Remy

RCS file:
/home/cvspublic/jakarta-tomcat/proposals/catalina/src/share/org/apache/tomca
t/core/StandardWrapper.java,v
retrieving revision 1.5
diff -r1.5 StandardWrapper.java
248a249,264
> /**
> * Set the load-on-startup order value (negative value means
> * load on first call).
> *
> * @param value New load-on-startup value
> */
> public void setLoadOnStartup(String value) {
>
> try {
> setLoadOnStartup((new Integer(value)).intValue());
> } catch (NumberFormatException e) {
> setLoadOnStartup(0);
> }
>
> }
>

RCS file:
/home/cvspublic/jakarta-tomcat/proposals/catalina/src/share/org/apache/tomca
t/core/LocalStrings.properties,v
retrieving revision 1.9
diff -r1.9 LocalStrings.properties
2a3

> containerBase.notConfigured=Container has not been properly configured

7a9

> standardContext.notFound=Context not found

RCS file:
/home/cvspublic/jakarta-tomcat/proposals/catalina/src/share/org/apache/tomca
t/core/ContainerBase.java,v
retrieving revision 1.13
diff -r1.13 ContainerBase.java
307a308

> basic = valve;
RCS file:
/home/cvspublic/jakarta-tomcat/proposals/catalina/src/share/org/apache/tomca
t/valves/AccessLogValve.java,v
retrieving revision 1.6
diff -r1.6 AccessLogValve.java
524c524

< temp.append(timestamp.substring(8, 2)); // Day

---

> temp.append(timestamp.substring(8, 10)); // Day

526c526

< temp.append(lookup(timestamp.substring(5, 2))); // Month

---

> temp.append(lookup(timestamp.substring(5, 7))); // Month

530c530

< temp.append(timestamp.substring(11, 8)); // Time

---

> temp.append(timestamp.substring(11, 19)); // Time


Re: [Catalina] Static pages

Posted by Arshad Mahmood <ar...@rohas.com>.
Hi,

Would it be possible to version stamp each of the files under
release/??/bin. As it is each version is simply called
"jakarta-tomcat.tar.gz".

I realise you have all probably got much better things to do, and if it is
too much effort then I fully understand.

Regards,
Arshad



[Catalina] Static pages

Posted by Remy Maucherat <re...@exoffice.com>.
> Remy Maucherat wrote:
>
> > I had a look at Catalina, and first of all, I must say I'm impressed by
how
> > clean the code is.
> > I'm still not very familiar with it, though.
>
> Thanks Remy ... I just checked in patches that include yours (some I ran
into
> yesterday as well) plus a bunch of other ones.

Yep, I saw that. I saw you fixed the setLoadOnStartup too (which shouldn't
happen anyway either).

> > Random facts :
> > - After toying a bit with the config, the DummyContainer works :-)
>
> If you start Catalina now and ask for "http://localhost:8080/index.html"
it
> should now serve you the Tomcat home page.  Today's task is to finish
cleaning
> up the default servlet and add the invoker servlet.

:-)
It works, but only the first impression of the page. If I hit refresh on my
browser, I get an error (code 304).
Here's the log (it's working now, cool :-) :
127.0.0.1 - - [29/Apr/2000:10:43:22 -0800] "GET / HTTP/1.1" 400 -
127.0.0.1 - - [29/Apr/2000:10:43:24 -0800] "GET / HTTP/1.1" 400 -
127.0.0.1 - - [29/Apr/2000:10:43:25 -0800] "GET / HTTP/1.1" 400 -
127.0.0.1 - - [29/Apr/2000:10:43:25 -0800] "GET / HTTP/1.1" 400 -
127.0.0.1 - - [29/Apr/2000:10:43:35 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:36 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:37 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:38 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:38 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:45 -0800] "GET /index.html HTTP/1.1" 200
2527
127.0.0.1 - - [29/Apr/2000:10:43:45 -0800] "GET /tomcat.gif HTTP/1.1" 200
1934
127.0.0.1 - - [29/Apr/2000:10:43:47 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:43:49 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:44:31 -0800] "GET /index.html HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:10:44:44 -0800] "GET /examples/index.html
HTTP/1.1" 200 2527
127.0.0.1 - - [29/Apr/2000:10:44:44 -0800] "GET /examples/tomcat.gif
HTTP/1.1" 200 1934
127.0.0.1 - - [29/Apr/2000:11:20:40 -0800] "GET /examples/index.html
HTTP/1.1" 304 -
127.0.0.1 - - [29/Apr/2000:11:21:10 -0800] "GET
/servlet/org.exolab.slide.webdav.Webdav HTTP/1.1" 200 -
127.0.0.1 - - [29/Apr/2000:11:21:15 -0800] "GET
/servlet/org.exolab.slide.webdav.Webdav HTTP/1.1" 200 -

304 - Not Modified, seems like it's related to that : "Still messes up on
the If-Modified-Since check".

Remy


Re: [Catalina] [Patch] Small tweaks and fixes

Posted by "Craig R. McClanahan" <Cr...@eng.sun.com>.
Remy Maucherat wrote:

> I had a look at Catalina, and first of all, I must say I'm impressed by how
> clean the code is.
> I'm still not very familiar with it, though.
>

Thanks Remy ... I just checked in patches that include yours (some I ran into
yesterday as well) plus a bunch of other ones.

>
> Random facts :
> - After toying a bit with the config, the DummyContainer works :-)
>

If you start Catalina now and ask for "http://localhost:8080/index.html" it
should now serve you the Tomcat home page.  Today's task is to finish cleaning
up the default servlet and add the invoker servlet.

Craig