3. Araxis Merge File Comparison Report

Produced by Araxis Merge on Mon Mar 6 16:03:37 2006 UTC. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a reasonably standards compliant browser such as the latest version of Firefox or Internet Explorer. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

3.1 Files compared

# Location File Last Modified
1 C:\Merge Test Files\4.0.6\catalina\src\share\org\apache\catalina\connector\http HttpProcessor.java Tue Oct 8 15:15:34 2002 UTC
2 C:\Merge Test Files\4.1.18\catalina\src\share\org\apache\catalina\connector\http HttpProcessor.java Thu Dec 19 13:49:42 2002 UTC

3.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 18 1232
Changed 9 27
Inserted 7 40
Removed 2 2

3.3 Comparison options

Whitespace All differences in whitespace within lines are ignored
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

3.4 Active regular expressions

No regular expressions were active.

3.5 Comparison detail

1   /*   *   $Header:   /home/cvs/ jakarta-to mcat-4.0/c atalina/sr c/share/or g/apache/c atalina/co nnector/ht tp/HttpPro cessor.jav a,v   1. 3 6 .2.5   2002/04/04   17: 46: 0 8   remm   Exp   $   1   /*   *   $Header:   /home/cvs/ jakarta-to mcat-4.0/c atalina/sr c/share/or g/apache/c atalina/co nnector/ht tp/HttpPro cessor.jav a,v   1. 4 6
  2002/04/04   17: 5 0 :34   remm   Exp   $
2     *   $Revision:   1. 3 6 .2.5   $   2     *   $Revision:   1. 4 6
  $
3     *   $Date:   2002/04/04   17: 46: 0 8   $   3     *   $Date:   2002/04/04   17: 5 0 :34   $
4    *   4    *
5    * ======= ========== ========== ========== ========== ========== ========== =   5    * ======= ========== ========== ========== ========== ========== ========== =
6    *   6    *
7    * The Apa che Softwa re License , Version  1.1   7    * The Apa che Softwa re License , Version  1.1
8    *   8    *
9    * Copyrig ht (c) 199 9 The Apac he Softwar e Foundati on.  All r ights   9    * Copyrig ht (c) 199 9 The Apac he Softwar e Foundati on.  All r ights
10    * reserve d.   10    * reserve d.
11    *   11    *
12    * Redistr ibution an d use in s ource and  binary for ms, with o r without   12    * Redistr ibution an d use in s ource and  binary for ms, with o r without
13    * modific ation, are  permitted  provided  that the f ollowing c onditions   13    * modific ation, are  permitted  provided  that the f ollowing c onditions
14    * are met :   14    * are met :
15    *   15    *
16    * 1. Redi stribution s of sourc e code mus t retain t he above c opyright   16    * 1. Redi stribution s of sourc e code mus t retain t he above c opyright
17    *    noti ce, this l ist of con ditions an d the foll owing disc laimer.   17    *    noti ce, this l ist of con ditions an d the foll owing disc laimer.
18    *   18    *
19    * 2. Redi stribution s in binar y form mus t reproduc e the abov e copyrigh t   19    * 2. Redi stribution s in binar y form mus t reproduc e the abov e copyrigh t
20    *    noti ce, this l ist of con ditions an d the foll owing disc laimer in   20    *    noti ce, this l ist of con ditions an d the foll owing disc laimer in
21    *    the  documentat ion and/or  other mat erials pro vided with  the   21    *    the  documentat ion and/or  other mat erials pro vided with  the
22    *    dist ribution.   22    *    dist ribution.
23    *   23    *
24    * 3. The  end-user d ocumentati on include d with the  redistrib ution, if   24    * 3. The  end-user d ocumentati on include d with the  redistrib ution, if
25    *    any,  must incl ude the fo llowing ac knowlegeme nt:   25    *    any,  must incl ude the fo llowing ac knowlegeme nt:
26    *       " This produ ct include s software  developed  by the   26    *       " This produ ct include s software  developed  by the
27    *         Apache Sof tware Foun dation (ht tp://www.a pache.org/ )."   27    *         Apache Sof tware Foun dation (ht tp://www.a pache.org/ )."
28    *    Alte rnately, t his acknow legement m ay appear  in the sof tware itse lf,   28    *    Alte rnately, t his acknow legement m ay appear  in the sof tware itse lf,
29    *    if a nd whereve r such thi rd-party a cknowlegem ents norma lly appear .   29    *    if a nd whereve r such thi rd-party a cknowlegem ents norma lly appear .
30    *   30    *
31    * 4. The  names "The  Jakarta P roject", " Tomcat", a nd "Apache  Software   31    * 4. The  names "The  Jakarta P roject", " Tomcat", a nd "Apache  Software
32    *    Foun dation" mu st not be  used to en dorse or p romote pro ducts deri ved   32    *    Foun dation" mu st not be  used to en dorse or p romote pro ducts deri ved
33    *    from  this soft ware witho ut prior w ritten per mission. F or written   33    *    from  this soft ware witho ut prior w ritten per mission. F or written
34    *    perm ission, pl ease conta ct apache@ apache.org .   34    *    perm ission, pl ease conta ct apache@ apache.org .
35    *   35    *
36    * 5. Prod ucts deriv ed from th is softwar e may not  be called  "Apache"   36    * 5. Prod ucts deriv ed from th is softwar e may not  be called  "Apache"
37    *    nor  may "Apach e" appear  in their n ames witho ut prior w ritten   37    *    nor  may "Apach e" appear  in their n ames witho ut prior w ritten
38    *    perm ission of  the Apache  Group.   38    *    perm ission of  the Apache  Group.
39    *   39    *
40    * THIS SO FTWARE IS  PROVIDED ` `AS IS'' A ND ANY EXP RESSED OR  IMPLIED   40    * THIS SO FTWARE IS  PROVIDED ` `AS IS'' A ND ANY EXP RESSED OR  IMPLIED
41    * WARRANT IES, INCLU DING, BUT  NOT LIMITE D TO, THE  IMPLIED WA RRANTIES   41    * WARRANT IES, INCLU DING, BUT  NOT LIMITE D TO, THE  IMPLIED WA RRANTIES
42    * OF MERC HANTABILIT Y AND FITN ESS FOR A  PARTICULAR  PURPOSE A RE   42    * OF MERC HANTABILIT Y AND FITN ESS FOR A  PARTICULAR  PURPOSE A RE
43    * DISCLAI MED.  IN N O EVENT SH ALL THE AP ACHE SOFTW ARE FOUNDA TION OR   43    * DISCLAI MED.  IN N O EVENT SH ALL THE AP ACHE SOFTW ARE FOUNDA TION OR
44    * ITS CON TRIBUTORS  BE LIABLE  FOR ANY DI RECT, INDI RECT, INCI DENTAL,   44    * ITS CON TRIBUTORS  BE LIABLE  FOR ANY DI RECT, INDI RECT, INCI DENTAL,
45    * SPECIAL , EXEMPLAR Y, OR CONS EQUENTIAL  DAMAGES (I NCLUDING,  BUT NOT   45    * SPECIAL , EXEMPLAR Y, OR CONS EQUENTIAL  DAMAGES (I NCLUDING,  BUT NOT
46    * LIMITED  TO, PROCU REMENT OF  SUBSTITUTE  GOODS OR  SERVICES;  LOSS OF   46    * LIMITED  TO, PROCU REMENT OF  SUBSTITUTE  GOODS OR  SERVICES;  LOSS OF
47    * USE, DA TA, OR PRO FITS; OR B USINESS IN TERRUPTION ) HOWEVER  CAUSED AND   47    * USE, DA TA, OR PRO FITS; OR B USINESS IN TERRUPTION ) HOWEVER  CAUSED AND
48    * ON ANY  THEORY OF  LIABILITY,  WHETHER I N CONTRACT , STRICT L IABILITY,   48    * ON ANY  THEORY OF  LIABILITY,  WHETHER I N CONTRACT , STRICT L IABILITY,
49    * OR TORT  (INCLUDIN G NEGLIGEN CE OR OTHE RWISE) ARI SING IN AN Y WAY OUT   49    * OR TORT  (INCLUDIN G NEGLIGEN CE OR OTHE RWISE) ARI SING IN AN Y WAY OUT
50    * OF THE  USE OF THI S SOFTWARE , EVEN IF  ADVISED OF  THE POSSI BILITY OF   50    * OF THE  USE OF THI S SOFTWARE , EVEN IF  ADVISED OF  THE POSSI BILITY OF
51    * SUCH DA MAGE.   51    * SUCH DA MAGE.
52    * ======= ========== ========== ========== ========== ========== ========== =   52    * ======= ========== ========== ========== ========== ========== ========== =
53    *   53    *
54    * This so ftware con sists of v oluntary c ontributio ns made by  many   54    * This so ftware con sists of v oluntary c ontributio ns made by  many
55    * individ uals on be half of th e Apache S oftware Fo undation.   For more   55    * individ uals on be half of th e Apache S oftware Fo undation.   For more
56    * informa tion on th e Apache S oftware Fo undation,  please see   56    * informa tion on th e Apache S oftware Fo undation,  please see
57    * <http:/ /www.apach e.org/>.   57    * <http:/ /www.apach e.org/>.
58    *   58    *
59    * [Additi onal notic es, if req uired by p rior licen sing condi tions]   59    * [Additi onal notic es, if req uired by p rior licen sing condi tions]
60    *   60    *
61    */   61    */
62     62  
63     63  
64   package or g.apache.c atalina.co nnector.ht tp;   64   package or g.apache.c atalina.co nnector.ht tp;
65     65  
66     66  
67   import jav a.io.Buffe redInputSt ream;   67   import jav a.io.Buffe redInputSt ream;
68   import jav a.io.EOFEx ception;   68   import jav a.io.EOFEx ception;
69   import jav a.io.Inter ruptedIOEx ception;   69   import jav a.io.Inter ruptedIOEx ception;
70   import jav a.io.Input Stream;   70   import jav a.io.Input Stream;
71   import jav a.io.IOExc eption;   71   import jav a.io.IOExc eption;
72   import jav a.io.Outpu tStream;   72   import jav a.io.Outpu tStream;
73   import jav a.net.Inet Address;   73   import jav a.net.Inet Address;
74   import jav a.net.Sock et;   74   import jav a.net.Sock et;
75   import jav a.util.Arr ayList;   75   import jav a.util.Arr ayList;
76   import jav a.util.Ite rator;   76   import jav a.util.Ite rator;
77   import jav a.util.Loc ale;   77   import jav a.util.Loc ale;
78   import jav a.util.Str ingTokeniz er;   78   import jav a.util.Str ingTokeniz er;
79   import jav a.util.Tre eMap;   79   import jav a.util.Tre eMap;
80   import jav ax.servlet .ServletEx ception;   80   import jav ax.servlet .ServletEx ception;
81   import jav ax.servlet .http.Cook ie;   81   import jav ax.servlet .http.Cook ie;
82   import jav ax.servlet .http.Http ServletReq uest;   82   import jav ax.servlet .http.Http ServletReq uest;
83   import jav ax.servlet .http.Http ServletRes ponse;   83   import jav ax.servlet .http.Http ServletRes ponse;
84   import org .apache.ca talina.Con nector;   84   import org .apache.ca talina.Con nector;
85   import org .apache.ca talina.Con tainer;   85   import org .apache.ca talina.Con tainer;
86   import org .apache.ca talina.Glo bals;   86   import org .apache.ca talina.Glo bals;
87   import org .apache.ca talina.Htt pRequest;   87   import org .apache.ca talina.Htt pRequest;
88   import org .apache.ca talina.Htt pResponse;   88   import org .apache.ca talina.Htt pResponse;
89   import org .apache.ca talina.Lif ecycle;   89   import org .apache.ca talina.Lif ecycle;
90   import org .apache.ca talina.Lif ecycleEven t;   90   import org .apache.ca talina.Lif ecycleEven t;
91   import org .apache.ca talina.Lif ecycleExce ption;   91   import org .apache.ca talina.Lif ecycleExce ption;
92   import org .apache.ca talina.Lif ecycleList ener;   92   import org .apache.ca talina.Lif ecycleList ener;
93   import org .apache.ca talina.Log ger;   93   import org .apache.ca talina.Log ger;
94   import   org.apache .catalina. util. Reque st U t il ;   94   import   org.apache .catalina. util. Fa st HttpDateFo rma t
;
95   import org .apache.ca talina.uti l.Lifecycl eSupport;   95   import org .apache.ca talina.uti l.Lifecycl eSupport;
    96   import org .apache.ca talina.uti l.RequestU til;
    97   import org .apache.ca talina.uti l.ServerIn fo;
96   import org .apache.ca talina.uti l.StringMa nager;   98   import org .apache.ca talina.uti l.StringMa nager;
97   import org .apache.ca talina.uti l.StringPa rser;   99   import org .apache.ca talina.uti l.StringPa rser;
98     100  
99     101  
100   /**   102   /**
101    * Impleme ntation of  a request  processor  (and its  associated  thread) t hat may   103    * Impleme ntation of  a request  processor  (and its  associated  thread) t hat may
102    * be used  by an Htt pConnector  to proces s individu al request s.  The co nnector   104    * be used  by an Htt pConnector  to proces s individu al request s.  The co nnector
103    * will al locate a p rocessor f rom its po ol, assign  a particu lar socket  to it,   105    * will al locate a p rocessor f rom its po ol, assign  a particu lar socket  to it,
104    * and the  processor  will then  execute t he process ing requir ed to comp lete   106    * and the  processor  will then  execute t he process ing requir ed to comp lete
105    * the req uest.  Whe n the proc essor is c ompleted,  it will re cycle itse lf.   107    * the req uest.  Whe n the proc essor is c ompleted,  it will re cycle itse lf.
106    *   108    *
107    * @author  Craig R.  McClanahan   109    * @author  Craig R.  McClanahan
108    * @author  Remy Mauc herat   110    * @author  Remy Mauc herat
109     *   @version   $Revision:   1. 3 6 .2.5   $   $Date:   2002/04/04   17: 46: 0 8   $   111     *   @version   $Revision:   1. 4 6
  $   $Date:   2002/04/04   17: 5 0 :34   $
    112    * @deprec ated
110    */   113    */
111     114  
112   final clas s HttpProc essor   115   final clas s HttpProc essor
113       implem ents Lifec ycle, Runn able {   116       implem ents Lifec ycle, Runn able {
114     117  
115     118  
    119       // --- ---------- ---------- ---------- ---------- ----------  Manifest  Constants
    120  
    121  
    122       /**
    123        * Ser ver inform ation stri ng for thi s server.
    124        */
    125       privat e static f inal Strin g SERVER_I NFO =
    126           Se rverInfo.g etServerIn fo() + " ( HTTP/1.1 C onnector)" ;
    127  
    128  
116       // --- ---------- ---------- ---------- ---------- ---------- ------ Con structors   129       // --- ---------- ---------- ---------- ---------- ---------- ------ Con structors
117     130  
118     131  
119       /**   132       /**
120        * Con struct a n ew HttpPro cessor ass ociated wi th the spe cified con nector.   133        * Con struct a n ew HttpPro cessor ass ociated wi th the spe cified con nector.
121        *   134        *
122        * @pa ram connec tor HttpCo nnector th at owns th is process or   135        * @pa ram connec tor HttpCo nnector th at owns th is process or
123        * @pa ram id Ide ntifier of  this Http Processor  (unique pe r connecto r)   136        * @pa ram id Ide ntifier of  this Http Processor  (unique pe r connecto r)
124        */   137        */
125       public  HttpProce ssor(HttpC onnector c onnector,  int id) {   138       public  HttpProce ssor(HttpC onnector c onnector,  int id) {
126     139  
127           su per();   140           su per();
128           th is.connect or = conne ctor;   141           th is.connect or = conne ctor;
129           th is.debug =  connector .getDebug( );   142           th is.debug =  connector .getDebug( );
130           th is.id = id ;   143           th is.id = id ;
131           th is.proxyNa me = conne ctor.getPr oxyName();   144           th is.proxyNa me = conne ctor.getPr oxyName();
132           th is.proxyPo rt = conne ctor.getPr oxyPort();   145           th is.proxyPo rt = conne ctor.getPr oxyPort();
133           th is.request  = (HttpRe questImpl)  connector .createReq uest();   146           th is.request  = (HttpRe questImpl)  connector .createReq uest();
134           th is.respons e = (HttpR esponseImp l) connect or.createR esponse();   147           th is.respons e = (HttpR esponseImp l) connect or.createR esponse();
135           th is.serverP ort = conn ector.getP ort();   148           th is.serverP ort = conn ector.getP ort();
136           th is.threadN ame =   149           th is.threadN ame =
137              "HttpProce ssor[" + c onnector.g etPort() +  "][" + id  + "]";   150              "HttpProce ssor[" + c onnector.g etPort() +  "][" + id  + "]";
138     151  
139       }   152       }
140     153  
141     154  
142       // --- ---------- ---------- ---------- ---------- ----------  Instance  Variables   155       // --- ---------- ---------- ---------- ---------- ----------  Instance  Variables
143     156  
144     157  
145       /**   158       /**
146        * Is  there a ne w socket a vailable?   159        * Is  there a ne w socket a vailable?
147        */   160        */
148       privat e boolean  available  = false;   161       privat e boolean  available  = false;
149     162  
150     163  
151       /**   164       /**
152        * The  HttpConne ctor with  which this  processor  is associ ated.   165        * The  HttpConne ctor with  which this  processor  is associ ated.
153        */   166        */
154       privat e HttpConn ector conn ector = nu ll;   167       privat e HttpConn ector conn ector = nu ll;
155     168  
156     169  
157       /**   170       /**
158        * The  debugging  detail le vel for th is compone nt.   171        * The  debugging  detail le vel for th is compone nt.
159        */   172        */
160       privat e int debu g = 0;   173       privat e int debu g = 0;
161     174  
162     175  
163       /**   176       /**
(752 unchanged lines omitted)
916        * Sen d a confir mation tha t a reques t has been  processed  when pipe lining.   929        * Sen d a confir mation tha t a reques t has been  processed  when pipe lining.
917        * HTT P/1.1 100  Continue i s sent bac k to the c lient.   930        * HTT P/1.1 100  Continue i s sent bac k to the c lient.
918        *   931        *
919        * @pa ram output  Socket ou tput strea m   932        * @pa ram output  Socket ou tput strea m
920        */   933        */
921       privat e void ack Request(Ou tputStream  output)   934       privat e void ack Request(Ou tputStream  output)
922           th rows IOExc eption {   935           th rows IOExc eption {
923           if  (sendAck)   936           if  (sendAck)
924                output.w rite(ack);   937                output.w rite(ack);
925       }   938       }
926     939  
927     940  
928       /**   941       /**
929        * Pro cess an in coming HTT P request  on the Soc ket that h as been as signed   942        * Pro cess an in coming HTT P request  on the Soc ket that h as been as signed
930        * to  this Proce ssor.  Any  exception s that occ ur during  processing  must be   943        * to  this Proce ssor.  Any  exception s that occ ur during  processing  must be
931        * swa llowed and  dealt wit h.   944        * swa llowed and  dealt wit h.
932        *   945        *
933        * @pa ram socket  The socke t on which  we are co nnected to  the clien t   946        * @pa ram socket  The socke t on which  we are co nnected to  the clien t
934        */   947        */
935       privat e void pro cess(Socke t socket)  {   948       privat e void pro cess(Socke t socket)  {
936     949  
937           bo olean ok =  true;   950           bo olean ok =  true;
938           bo olean fini shResponse  = true;   951           bo olean fini shResponse  = true;
939           So cketInputS tream inpu t = null;   952           So cketInputS tream inpu t = null;
940           Ou tputStream  output =  null;   953           Ou tputStream  output =  null;
941     954  
942           //  Construct  and initi alize the  objects we  will need   955           //  Construct  and initi alize the  objects we  will need
943           tr y {   956           tr y {
944                input =  new Socket InputStrea m(socket.g etInputStr eam(),   957                input =  new Socket InputStrea m(socket.g etInputStr eam(),
945                                                 connecto r.getBuffe rSize());   958                                                 connecto r.getBuffe rSize());
946           }  catch (Exc eption e)  {   959           }  catch (Exc eption e)  {
947                log("pro cess.creat e", e);   960                log("pro cess.creat e", e);
948                ok = fal se;   961                ok = fal se;
949           }   962           }
950     963  
951           ke epAlive =  true;   964           ke epAlive =  true;
952     965  
953           wh ile (!stop ped && ok  && keepAli ve) {   966           wh ile (!stop ped && ok  && keepAli ve) {
954     967  
955                finishRe sponse = t rue;   968                finishRe sponse = t rue;
956