[opc@pdr-cregas reportesGN]$ cat matrizGNC.jsp
<%@page contentType="text/html; charset=iso-8859-1" language="java" errorPage="errorpage.jsp" import="java.sql.*,co.gov.creg.util.*" %>
<%@page import="co.gov.creg.BuilderHTML.*"%>
<%
  /**
   * @author CREG, 05-05-2003
   * @author CREG, 06-05-2003
   * modify CREG, 11-01-2008
   * modify CREG, 20-01-2008
   * modify CREG, 09-03-2010
   * modify CREG AE, 22-01-2021
   * modify CREG AE, 04-02-2022
   * modify CREG AE, 30-01-2023
   */
  String depOrig                = (request.getParameter("depOrig")!=null)?request.getParameter("depOrig"):new String("05000");
  String depDes         = (request.getParameter("depDes")!=null)?request.getParameter("depDes"):new String("05000");
  String origen         = (request.getParameter("origen")!=null)?request.getParameter("origen"):new String("05001");
  String destino       = (request.getParameter("destino")!=null)?request.getParameter("destino"):new String("05001");
  String vehiculo = (request.getParameter("vehiculo")!=null)?request.getParameter("vehiculo"):new String("CIL_UNI");

  double fIpc2023       = 378.11;
  double fIpc2022       = 346.01;
  double fIpc2021       = 305.87;//04-02-2021
  double fIpc2020       = 289.59;//22-01-2021
  double fIpc2019       = 284.98;//17-01-2020
  double fIpc2018       = 274.55;//14-01-2019
  double fIpc2017       = 266.08;//17-01-2018
  double fIpc2016       = 255.63;//11-01-2017
  double fIpc2015       = 241.74;//21-01-2016
  double fIpc2014       = 226.410845;//16-01-2014
  double fIpc2013       = 218.419874;//15-01-2014
  double fIpc2012       = 214.28;//10-01-2013
  double fIpc2011       = 209.18;//11-01-2012
  double fIpc2010       = 201.67;//13-01-2011
  double fIpc2009       = 195.46;//09-03-2010
  double fIpc2008       = 191.63;//20-01-2008
  double fIpc2007       = 177.97;
  double fIpc2006       = 168.38;
  double fIpc2005       = 161.16;
  double fIpc2004       = 153.7;
  double fIpc2003       = 145.69;
  double fIpc2002       = 136.81;

%>
<html>
<head>
<title>Reporte</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<LINK REL=STYLESHEET TYPE="text/css" HREF="css/estilos.css">
   </head>
   <body class="page"><b><font face="arial" size="1" color="#000000">
     <div align="center">

       <form action="" method='post' >
               <table width="90%">
                        <tr>
                     <td>&nbsp;</td>
                   </tr>
                  <tr   >
                     <td ALIGN="CENTER" class="roweven">
                                         <strong>
                                         Costos  de Transporte Para GNC.
                                        </strong>
                     </td>
                  </tr>
         </table>

                 <table width="427" align="cent<th align="left"><b>
                                    </b>
                                 </th>
                 <tr>
                     <td width="205">&nbsp;</td>
                   </tr>
                        <tr>
                     <td>&nbsp;</td>
                   </tr>
                 </table >

                  <table width="427" align="center">
                  <tr>
                    <td colspan="2" align="left" class="roweven2"><div align="center">Origen</div></td>
                    <td colspan="2" align="left" class="roweven2"><div align="center">Destino</div></td>
                    </tr>
                  <tr >
                  <%
                                TSelectHtmlDB SDBDepOrig=new TSelectHtmlDB("<select name=\"depOrig\" onchange=\"javascript:submit();\">","glp");
                                {
                                        String SentenciaSQL="Select Dep.A50CODIGO_DANE,Dep.A50NOMBRE from ADMIN.T50DEPARTAMENTO Dep";
                                        SDBDepOrig.GenerarOpciones(SentenciaSQL,"A50CODIGO_DANE","A50NOMBRE",depOrig);
                                }
                  %>
                  <td align="left" width="101" class="roweven2">
                                        Departamento:
                                  </td>
                                  <td align="left" width="101" class="roweven2">
                                        <%=SDBDepOrig.PrintSelect()%>
                                  </td>

                                  <%
                                TSelectHtmlDB SDBDepDes=new TSelectHtmlDB("<select name=\"depDes\" onchange=\"javascript:submit();\">","glp");
                                {
                                        String SentenciaSQL="Select Dep.A50CODIGO_DANE,Dep.A50NOMBRE from ADMIN.T50DEPARTAMENTO Dep";
                                SDBDepDes.GenerarOpciones(SentenciaSQL,"A50CODIGO_DANE","A50NOMBRE",depDes);
                            }
                  %>

                  <td align="left" width="101" class="roweven2">
                                        Departamento:
                                  </td>
                                  <td align="left" width="107" class="roweven2">
                                  <%=SDBDepDes.PrintSelect()%>
                                  </td>

                                  </tr>
                  <tr>
                  <%
                                TSelectHtmlDB SDBCiuOri=new TSelectHtmlDB("<select name=\"origen\">","glp");

                                {
                                        String SentenciaSQL="Select Ciu.A51CODIGO_DANE,Ciu.A51NOMBRE from ADMIN.T51MUNICIPIO Ciu";
                                                         SentenciaSQL+=" Where Ciu.A03CODIGO_DEPARTAMENTO='"+depOrig+"'";
                                        SDBCiuOri.GenerarOpciones(SentenciaSQL,"A51CODIGO_DANE","A51NOMBRE",origen);
                                }
                  %>
                  <td align="left" width="101" class="roweven2">
                                        Ciudad:
                                  </td>
                  <td align="left" width="101" class="roweven2">
                                        <%=SDBCiuOri.PrintSelect()%>
                                  </td>

                                  <%
                                TSelectHtmlDB SDBCiuDes=new TSelectHtmlDB("<select name=\"destino\" >","glp");
                                {
                                        String SentenciaSQL="Select Ciu.A51CODIGO_DANE,Ciu.A51NOMBRE from ADMIN.T51MUNICIPIO Ciu";
                                                         SentenciaSQL+=" Where Ciu.A03CODIGO_DEPARTAMENTO='"+depDes+"'";
                                        SDBCiuDes.GenerarOpciones(SentenciaSQL,"A51CODIGO_DANE","A51NOMBRE",destino);
                                }
                  %>
                                  <td align="left" width="101" class="roweven2">
                                        Ciudad:
                                  </td>
                                  <td align="left" width="107" class="roweven2">
                                        <%=SDBCiuDes.PrintSelect()%>
                                  </td>

                                </tr>

                 </table>
                                <table>
                                <tr>
                     <td>&nbsp;</td>
                  </tr>
                                <tr>
                                        <td align='center' class="roweven2">
                                                Vehiculo:
                                        </td>
                    <td align='center' class="roweven2">
                    <%

                         TSelectHtml SelectPesoCilindro=new TSelectHtml("<select name=\"vehiculo\">");

                         SelectPesoCilindro.GenerarOpcion("CIL_UNI","No Articulado",vehiculo.equals("CIL_UNI")?true:false);
                         SelectPesoCilindro.GenerarOpcion("CIL_ART","Articulado",vehiculo.equals("CIL_ART")?true:false);


                    %>
                    <%=SelectPesoCilindro.PrintSelect()%>
                    <!--
                    <select name='pesoCilindro'>
                        <option value='8.79'>20 lbs</option>
                        <option value='13.2'>30 lbs</option>
                        <option value='14.08'>40 lbs</option>
                        <option value='24.8'>80 lbs</option>
                        <option value='35.19'>100 lbs</option>
                      </select>
                    -->
                      &nbsp;&nbsp;<INPUT type='submit' name='Consultar' value='Consultar'/>
                    </td>
                  </tr>
         </table>
                 <table>
                  <tr>
                     <td>&nbsp;</td>
                  </tr>
                  <tr>
                     <td>&nbsp;</td>
                   </tr>
                        <tr>
                     <td>&nbsp;</td>
                   </tr>
                  <tr>
                     <td>
                        <center>
                           <table border="0" cellpadding="4" class="table">
                              <tr>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Depto</font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="coleven">Mpio</font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Depto</font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="coleven">Mpio</font>
                                    </b>
                                 </th>

                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2004 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2005 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2006 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2007 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2008 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2009 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                        <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2010 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                             <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2011 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                             <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2012 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                 <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2013 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2014 $/m<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2015 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2016 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2017 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2018 $/M<sup>3</sup></font>
                                    </b>
                                 </th></th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2019 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2020 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
                                <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2021 $/M<sup>3</sup></font>
                                    </b>
                                 </th>
            <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2022 $/M<sup>3</sup></font>
                                 </b>
                              </th>
            <th align="left"><b><font face="arial" size="1" color="#006699" class="colodd">Costo IPC DIC 2023 $/M<sup>3</sup></font>
                                 </b>
                              </th>

                              </tr>
<%
  if (origen != null && destino != null)
  {
    DBQuery dbq = null;
    try
    {
      dbq = new DBQuery("glp");
      String sQuery = "SELECT DORIG.A50NOMBRE DORIGEN, " +
                      "       ORIG.A51NOMBRE MORIGEN, " +
                      "       DDEST.a50nombre DDESTINO, " +
                      "       DEST.a51nombre MDESTINO, " +
                      "       COSTO " +
                      "  FROM  " +
                      "( " +
                      "select ORIGEN ORIGEN,  " +
                      "       DESTINO DESTINO, " +
                      "       "+vehiculo+" COSTO " +
                      "FROM T31COSTOS_TRANSPORTE " +
                      "WHERE ORIGEN = '" + origen + "' " +
                      "AND DESTINO = '" + destino + "' " +
                      "UNION " +
                      "select DESTINO ORIGEN, " +
                      "       ORIGEN DESTINO,  " +
                      "       "+vehiculo+" COSTO " +
                      "FROM T31COSTOS_TRANSPORTE " +
                      "WHERE ORIGEN = '" + destino + "' " +
                      "      AND DESTINO = '" + origen + "' " +
                      ") INNER JOIN ADMIN.T51MUNICIPIO ORIG ON ORIGEN = ORIG.A51CODIGO_DANE  " +
                      "    INNER JOIN ADMIN.T50DEPARTAMENTO DORIG ON ORIG.A03CODIGO_DEPARTAMENTO = DORIG.A50CODIGO_DANE " +
                      " INNER JOIN ADMIN.T51MUNICIPIO DEST ON DESTINO = DEST.A51CODIGO_DANE  " +
                      "    INNER JOIN ADMIN.T50DEPARTAMENTO DDEST ON DEST.A03CODIGO_DEPARTAMENTO = DDEST.A50CODIGO_DANE";
      ResultSet rs = dbq.executeQuery(sQuery);
      String temp = "";
      String rowClassOdd  = "rowodd";
      String rowClassEven = "roweven";
      String rowClass     = "";
      int nRow = 0;
      while(rs.next())
      {
        nRow++;
        if (nRow % 2 == 0)
          rowClass = rowClassEven;
        else
          rowClass = rowClassOdd;
%>
                                    <tr class="<%= rowClass %>">
                                       <td class="colodd"><b><font face="arial" size="1" color="#000000"><%= rs.getString("DORIGEN") %></font>
                                          </b>
                                       </td>
                                       <td class="coleven"><b><font face="arial" size="1" color="#000000"><%= rs.getString("MORIGEN") %></font>
                                          </b>
                                       </td>
                                       <td class="colodd"><b><font face="arial" size="1" color="#000000"><%= rs.getString("DDESTINO") %></font>
                                          </b>
                                       </td>
                                       <td class="coleven"><b><font face="arial" size="1" color="#000000"><%= rs.getString("MDESTINO") %></font>
                                          </b>
                                       </td>

                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2004/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2005/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2006/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>
                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2007/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>
                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2008/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>

                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2009/fIpc2002))%>
                                                                           </font>
                                          </b>
                                       </td>
                                           <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2010/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>

                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2011/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>

                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2012/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>

                                       <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2013/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>

                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2014/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2015/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2016/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2017/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2018/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2019/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2020/fIpc2002))%>
                                                  </font>
                                          </b>
                                       </td>
                                        <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                                                <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2021/fIpc2002))%>
                                                  </font>
               <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                     <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2022/fIpc2002))%>
                       </font>
                                          </b>
                                       </td>
               <td class="colodd" align="right"><b><font face="arial" size="1" color="#000000">
                     <%= util.formatear(rs.getDouble("COSTO")*0.012*(fIpc2023/fIpc2002))%>
                       </font>
                                          </b>
                                       </td>

                                    </tr>
<%
      }
    }
    catch (Exception ex)
    {
      if (dbq != null)
        dbq.closeAll();
      if (ex.getMessage() == null)
        throw new Exception("Error al tratar de consultar costos.<BR>");
      else
        throw new Exception("Error al tratar de consultar costos.<BR>" + ex.getMessage());
    }
    if (dbq != null)
      dbq.closeAll();
  }
%>
                           </table>
                        </center>
                     </td>
                  </tr>
               </table>
       </form>
            </div>
         </font>
      </b>
   </body>
</html>
Mar 5, 2024 5:10:54 PM co.gov.creg.util.DBConnectionManager2 getConnection
SEVERE: null
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (IO Error: The Network Adapter could not establish the connection)
        at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1225)
        at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:880)
        at co.gov.creg.util.DBConnectionManager2.getConnection(DBConnectionManager2.java:96)
        at co.gov.creg.util.DBQuery.<init>(DBQuery.java:40)
        at org.apache.jsp.matrizGNC_jsp._jspService(matrizGNC_jsp.java:342)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
        at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:835)
        at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:640)
        at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1286)
        at java.lang.Thread.run(Thread.java:662)
Caused by: java.sql.SQLRecoverableException: IO Error: The Network Adapter could not establish the connection
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:743)
        at oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:662)
        at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:560)
        at org.apache.tomcat.dbcp.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:38)
        at org.apache.tomcat.dbcp.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294)
        at org.apache.tomcat.dbcp.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:1247)
        at org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1221)
        ... 22 more
Caused by: oracle.net.ns.NetException: The Network Adapter could not establish the connection
        at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:470)
        at oracle.net.resolver.AddrResolution.resolveAndExecute(AddrResolution.java:506)
        at oracle.net.ns.NSProtocol.establishConnection(NSProtocol.java:595)
        at oracle.net.ns.NSProtocol.connect(NSProtocol.java:230)
        at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1452)
        at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:496)
        ... 29 more
Caused by: java.net.NoRouteToHostException: No route to host
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
        at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213)
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
        at java.net.Socket.connect(Socket.java:529)
        at oracle.net.nt.TcpNTAdapter.connect(TcpNTAdapter.java:161)
        at oracle.net.nt.ConnOption.connect(ConnOption.java:159)
        at oracle.net.nt.ConnStrategy.execute(ConnStrategy.java:428)
        ... 34 more
ayudame a arreglar este error ten en cuenta que es apache tomcat 5.5