Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
Hi, My servlet generates a page containing embedded JavaScript and sometimes the page received in the browser comes with CRLFs stripped from the text, starting at some point in the text. This creates a big problem if the script contains CRLF as statement separator instead of semi-colon. It's

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Daniel Mikusa
On Jan 13, 2014, at 6:09 AM, Asok Chattopadhyay da.a...@gmail.com wrote: Hi, My servlet generates a page containing embedded JavaScript and sometimes the page received in the browser comes with CRLFs stripped from the text, starting at some point in the text. This creates a big problem if

Re: serialization and newest tomcat

2014-01-13 Thread Daniel Mikusa
On Jan 12, 2014, at 8:45 AM, Ray Holme rayho...@yahoo.com wrote: I haven't been following this thread, but I wanted to clarify a couple comments here just to make sure someone reading this in the future doesn't get the wrong ideas. serialization causes some problems in apache-tomcat-7.0.35

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
I checked the string, say, s, just before and after writing it to the PrintWriter. PrintWriter out=response.getWriter(); Print(before=+s); out.println(s); out.flush(); out.close(); Print(after=+s); where Print is a static method printing on the log file localhost...log And the log shows no

Re: serialization and newest tomcat

2014-01-13 Thread Ray Holme
OK, that makes perfect sense. We are NOT talking about SESSION objects (where I am defining session as login to logout of a USER as I mentioned before, perhaps you are defining this as while tomcat is up - I can see either def.). These type beans are all fine, but I would actually never want

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Daniel Mikusa
On Jan 13, 2014, at 8:26 AM, Asok Chattopadhyay da.a...@gmail.com wrote: I checked the string, say, s, just before and after writing it to the PrintWriter. PrintWriter out=response.getWriter(); Print(before=+s); out.println(s); out.flush(); out.close(); Print(after=+s); where Print

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
No, I don't have any filter, except for a session counter listener. I am going to make a demo servlet and post it soon once I am back at home, Thanks Dan. I really appreciate your help, Sent from my iPhone On 13 Jan, 2014, at 9:36 PM, Daniel Mikusa dmik...@gopivotal.com wrote: On Jan 13,

Re: serialization and newest tomcat

2014-01-13 Thread Ray Holme
Oh, I missed one comment from Daniel before (embedded and I did not see on the first pass, sorry). No, you don't know the application so I would like to explain that some information kept in the shared application beans is very static, needs to be loaded from the DB and is used everywhere by

Re: serialization and newest tomcat

2014-01-13 Thread Daniel Mikusa
On Jan 13, 2014, at 8:37 AM, Ray Holme rayho...@yahoo.com wrote: OK, that makes perfect sense. We are NOT talking about SESSION objects (where I am defining session as login to logout of a USER as I mentioned before, perhaps you are defining this as while tomcat is up - I can see either

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread André Warnier
Asok Chattopadhyay wrote: Hi, My servlet generates a page containing embedded JavaScript and sometimes the page received in the browser comes with CRLFs stripped from the text, starting at some point in the text. This creates a big problem if the script contains CRLF as statement separator

Re: Mod_jk error

2014-01-13 Thread Alex Lucard
Thank you so much i have it working now i had to change the httpd.com from JkMount /Hello/*loadbalancer1 To JkMount /Hello*workspace1 On Jan 12, 2014 9:31 PM, 侯树成 chain...@gmail.com wrote: Hi, Alex What is your mod_jk.conf file that used for mod_jk configuration. You can config it as

Re: serialization and newest tomcat

2014-01-13 Thread Johan Compagner
IS THERE A WAY TO STOP WARNINGS AND TELL TOMCAT NOT TO SERIALIZE A BEAN? Right now, I have stopped warnings but caused other problems. just don't add those beans to a session or if you do add them make sure that they are in containers and that those fields are transient then those fields

Re: serialization and newest tomcat

2014-01-13 Thread Ray Holme
I have (in the past) dealt with transient so OK, makes sense. Not familiar with putting in container to shield from Apache serialization. Will look for writeup. Thanks. On Monday, January 13, 2014 10:12 AM, Johan Compagner jcompag...@servoy.com wrote: IS THERE A WAY TO STOP WARNINGS AND

Re: serialization and newest tomcat

2014-01-13 Thread Daniel Mikusa
On Jan 13, 2014, at 9:02 AM, Ray Holme rayho...@yahoo.com wrote: Oh, I missed one comment from Daniel before (embedded and I did not see on the first pass, sorry). No, you don't know the application so I would like to explain that some information kept in the shared application beans is

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
I am attaching the Test servlet and the text file that contains the page. The Test servlet simply reads the file and sends out to the browser. When I run this servlet, it strips all CRLFs from line 153 onward. Thanks. On Mon, Jan 13, 2014 at 9:57 PM, Asok Chattopadhyay da.a...@gmail.comwrote:

Re: serialization and newest tomcat

2014-01-13 Thread David kerber
Another option would be to read them from the db once, at system startup, and then keep them static from there. You're still hitting your db, but not on an ongoing basis. On 1/13/2014 9:02 AM, Ray Holme wrote: Oh, I missed one comment from Daniel before (embedded and I did not see on the

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
You can see the test servlet working at http://workshop.dreamapps.com/da/test Thanks again On Mon, Jan 13, 2014 at 11:36 PM, Asok Chattopadhyay da.a...@gmail.comwrote: I am attaching the Test servlet and the text file that contains the page. The Test servlet simply reads the file and sends

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Daniel Mikusa
On Jan 13, 2014, at 10:36 AM, Asok Chattopadhyay da.a...@gmail.com wrote: I am attaching the Test servlet and the text file that contains the page. The Test servlet simply reads the file and sends out to the browser. When I run this servlet, it strips all CRLFs from line 153 onward. Your

RE: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Konstantin Preißer
Hi, -Original Message- From: Asok Chattopadhyay [mailto:da.a...@gmail.com] Sent: Monday, January 13, 2014 4:52 PM To: Tomcat Users List Subject: Re: Tomcat strips CRLFs from the generated page I am attaching the Test servlet and the text file that contains the page. The Test

Oracle Application Server 10g R3 works fine with RK-1048 codepage but Tomcat 7.0.47 does not.

2014-01-13 Thread Тимур Кулибаев
Dears, I have checked documentation/FAQ/WEB/archives but it didn't help to resolve the following trouble: I have a java servlet which is currently deployed on Oracle Application Server 10g R3 with jdk 1.5u19 on RHEl 5.7 and one works fine with Oracle Application Server. The servlet works with

Re: serialization and newest tomcat

2014-01-13 Thread Ray Holme
Nice, I do that for many things, but not all of it. You are right, I probably could do that. Nice food for thought! :=] On Monday, January 13, 2014 11:31 AM, Daniel Mikusa dmik...@gopivotal.com wrote: On Jan 13, 2014, at 8:37 AM, Ray Holme rayho...@yahoo.com wrote: OK, that makes

META-INF/Context.xml path question

2014-01-13 Thread Bob DeRemer
We're trying to determine if it's possible to build a WAR with an embedded META-INF/Context.xml that defines the webapp path to be different then the WAR file name. Let's say we have AppServer-version.war, but we want to access it as: http://host/Server. In addition, we want to support

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
Hi, Sorry about that. Here are the locations of the two files: (1) http://workshop.dreamapps.com/da/docs/Test.java (2) http://workshop.dreamapps.com/da/docs/test.html Thanks. On Tue, Jan 14, 2014 at 12:39 AM, Konstantin Preißer kpreis...@apache.orgwrote: Hi, -Original Message-

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
Andre: I changed the out.println(s) to out.print(s), but that did not make any difference. Regards. On Tue, Jan 14, 2014 at 1:40 AM, Asok Chattopadhyay da.a...@gmail.comwrote: Hi, Sorry about that. Here are the locations of the two files: (1) http://workshop.dreamapps.com/da/docs/Test.java

Re: Packet misses in Tomcat

2014-01-13 Thread Stefan Mayr
Am 13.01.2014 07:22, schrieb Divyaprakash Y: -Original Message- From: Stefan Mayr [mailto:ste...@mayr-stefan.de] Sent: 10 January 2014 23:26 To: users@tomcat.apache.org Subject: Re: Packet misses in Tomcat Hi Am 09.01.2014 14:21, schrieb Divyaprakash Y: -Original Message-

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Konstantin Kolinko
2014/1/13 Asok Chattopadhyay da.a...@gmail.com: You can see the test servlet working at http://workshop.dreamapps.com/da/test 1. Downloading the page with WGET tool, all CRLFs (on line 153 and below) are OK 2. Opening the page in Firefox, and doing View page source shows HTML markup errors

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread André Warnier
Asok Chattopadhyay wrote: You can see the test servlet working at http://workshop.dreamapps.com/da/test According to what I see when I save this page and view it with an editor that can show the end-of-lines used, you have a terrible mixture of lines terminated by CR/LF, and lines

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread André Warnier
Asok Chattopadhyay wrote: Hi, Sorry about that. Here are the locations of the two files: (1) http://workshop.dreamapps.com/da/docs/Test.java (2) http://workshop.dreamapps.com/da/docs/test.html Same comment as before, for the file test.html : the file itself contains a mixture of end-of-line

RE: META-INF/Context.xml path question

2014-01-13 Thread Caldarale, Charles R
From: Bob DeRemer [mailto:bob.dere...@thingworx.com] Subject: META-INF/Context.xml path question We're trying to determine if it's possible to build a WAR with an embedded META-INF/Context.xml that defines the webapp path to be different then the WAR file name. Short answer: no. Let's

RE: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Konstantin Preißer
Hi, -Original Message- From: Asok Chattopadhyay [mailto:da.a...@gmail.com] Sent: Monday, January 13, 2014 6:41 PM To: Tomcat Users List Subject: Re: Tomcat strips CRLFs from the generated page Hi, Sorry about that. Here are the locations of the two files: (1)

Re: META-INF/Context.xml path question

2014-01-13 Thread Mark Thomas
On 13/01/2014 17:38, Bob DeRemer wrote: We're trying to determine if it's possible to build a WAR with an embedded META-INF/Context.xml It is context.xml, not Context.xml. Case matters. that defines the webapp path to be different then the WAR file name. No, it is not possible to do this.

Re: META-INF/Context.xml path question

2014-01-13 Thread Konstantin Kolinko
2014/1/13 Bob DeRemer bob.dere...@thingworx.com: Tomcat version =? We're trying to determine if it's possible to build a WAR with an embedded META-INF/Context.xml that defines the webapp path to be different then the WAR file name. Not possible. BTW, the file name is context.xml (case

Re: Oracle Application Server 10g R3 works fine with RK-1048 codepage but Tomcat 7.0.47 does not.

2014-01-13 Thread Christopher Schultz
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Тимур, On 1/13/14, 11:34 AM, Тимур Кулибаев wrote: Dears, I have checked documentation/FAQ/WEB/archives but it didn't help to resolve the following trouble: I have a java servlet which is currently deployed on Oracle Application Server 10g R3

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Mark Eggers
On 1/13/2014 9:40 AM, Asok Chattopadhyay wrote: Hi, Sorry about that. Here are the locations of the two files: (1) http://workshop.dreamapps.com/da/docs/Test.java (2) http://workshop.dreamapps.com/da/docs/test.html Thanks. On Tue, Jan 14, 2014 at 12:39 AM, Konstantin Preißer

RE: Would a developer please add this mime type to the distro?

2014-01-13 Thread Jeffrey Janner
-Original Message- From: Konstantin Kolinko [mailto:knst.koli...@gmail.com] Sent: Friday, January 10, 2014 9:04 PM To: Tomcat Users List Subject: Re: Would a developer please add this mime type to the distro? 2014/1/11 Jeffrey Janner jeffrey.jan...@polydyne.com: Tomcat 7 did a

tomcat gracefull shutdown problem

2014-01-13 Thread Ja kub
I modified conf/context.xml Context unloadDelay=6 I hoped tomcat would wait 60 seconds for request to end. But there are some problems with spring app, I get HTTP Status 503 - Servlet jsp is currently unavailable: I use tomcat 7.42 64 bit on windows 7 steps to reproduce: use app from

Re: Tomcat strips CRLFs from the generated page

2014-01-13 Thread Asok Chattopadhyay
As I said before, I have no control over the input text. In the test servlet I am simply reading text from a file and sending it out to the browser. No other processing has been done to the text by the servlet. The browser, however, receives a page with CRLF stripped starting from a certain point

Re: Oracle Application Server 10g R3 works fine with RK-1048 codepage but Tomcat 7.0.47 does not.

2014-01-13 Thread Тимур Кулибаев
Hello, Christopher ! The user.language and user.country system properties for my running Tomcat instance are not set. In Oracle Apllication Server I also do not see these properties set in ps -ef | grep java output. I set both properties in JAVA_OPTS env.var: [oracle@n36 logs]$ echo $JAVA_OPTS