----- Original Message -----
From: " Reynardine" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, November 22, 2002 7:39 AM
Subject: Happyaxis.jsp fails when upgrading to Java 1.4


> Hello,
>
> Please can someone help.  My axis 1.0 installation was fine under Tomcat
4.0.4 and Java 1.3.  Then because of some JSTL problems with Java 1.3 I
upgraded to Java 1.4.  Tomcat 4.0.4 is still ok and I can compile and run
jsp's and servlets.  However, Axis is now broken when I validate and I can't
work out why.  I've read the Axis installation guide concerning Java 1.4 and
have copied all available jars to Tomcat/common/lib without success.
>
> Has anyone else suffered from and then solved this problem ?
>
> Any help gratefully received and my happyaxis,jsp errors are below ..
>

try this version of happyaxis instead, that has better error handling (its
the current CVS version). The key point to know is yes, you have some
problems.
Title: Axis Happiness Page
<%@ page import="java.io.InputStream, java.io.IOException, javax.xml.parsers.SAXParser, javax.xml.parsers.SAXParserFactory" session="false" %> <% /* * The Apache Software License, Version 1.1 * * Copyright (c) 2002 The Apache Software Foundation. All rights * reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The end-user documentation included with the redistribution, if * any, must include the following acknowlegement: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowlegement may appear in the software itself, * if and wherever such third-party acknowlegements normally appear. * * 4. The names "The Jakarta Project", "Ant", and "Apache Software * Foundation" must not be used to endorse or promote products derived * from this software without prior written permission. For written * permission, please contact [EMAIL PROTECTED] * * 5. Products derived from this software may not be called "Apache" * nor may "Apache" appear in their names without prior written * permission of the Apache Group. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation. For more * information on the Apache Software Foundation, please see * . */ %>

Axis Happiness Page

Examining webapp configuration

Needed Components

<% int needed=0,wanted=0; /** * the essentials, without these Axis is not going to work */ needed=needClass(out, "javax.xml.soap.SOAPMessage", "saaj.jar", "SAAJ API", "Axis will not work", "http://xml.apache.org/axis/"); needed+=needClass(out, "javax.xml.rpc.Service", "jaxrpc.jar", "JAX-RPC API", "Axis will not work", "http://xml.apache.org/axis/"); needed+=needClass(out, "org.apache.axis.transport.http.AxisServlet", "axis.jar", "Apache-Axis", "Axis will not work", "http://xml.apache.org/axis/"); needed+=needClass(out, "org.apache.commons.discovery.Resource", "commons-discovery.jar", "Jakarta-Commons Discovery", "Axis will not work", "http://jakarta.apache.org/commons/discovery.html"); needed+=needClass(out, "org.apache.commons.logging.Log", "commons-logging.jar", "Jakarta-Commons Logging", "Axis will not work", "http://jakarta.apache.org/commons/logging.html"); //should we search for a javax.wsdl file here, to hint that it needs //to go into an approved directory? because we dont seem to need to do that. needed+=needClass(out, "com.ibm.wsdl.factory.WSDLFactoryImpl", "wsdl4j.jar", "IBM's WSDL4Java", "Axis will not work", null); needed+=needClass(out, "javax.xml.parsers.SAXParserFactory", "xerces.jar", "JAXP implementation", "Axis will not work", "http://xml.apache.org/xerces-j/"); needed+=needClass(out,"javax.activation.DataHandler", "activation.jar", "Activation API", "Axis will not work", "http://java.sun.com/products/javabeans/glasgow/jaf.html"); %>

Optional Components

<% /* * now the stuff we can live without */ wanted+=wantClass(out,"javax.mail.internet.MimeMessage", "mail.jar", "Mail API", "Attachments will not work", "http://java.sun.com/products/javamail/"); wanted+=wantClass(out,"org.apache.xml.security.Init", "xmlsec.jar", "XML Security API", "XML Security is not supported", "http://xml.apache.org/security/"); /* * resources on the classpath path */ /* broken; this is a file, not a resource wantResource(out,"/server-config.wsdd", "There is no server configuration file;" +"run AdminClient to create one"); */ /* add more libraries here */ out.write("

"); //is everythng we need here if(needed==0) { //yes, be happy out.write("The core axis libraries are present. "); } else { //no, be very unhappy response.setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR); out.write("" +needed +" core axis librar" +(needed==1?"y is":"ies are") +" missing"); } //now look at wanted stuff if(wanted>0) { out.write("" +wanted +" optional axis librar" +(wanted==1?"y is":"ies are") +" missing"); } else { out.write("The optional components are present."); } out.write("

"); //hint if anything is missing if(needed>0 || wanted>0 ) { out.write(getInstallHints(request)); } %>

Note: Even if everything this page probes for is present, there is no guarantee your web service will work, because there are many configuration options that we do not check for. These tests are necessary but not sufficient


Examining Application Server

<% String servletVersion=getServletVersion(); String xmlParser=getParserName(); %>
Servlet version<%= servletVersion %>
XML Parser<%= xmlParser %>
<% if(xmlParser.indexOf("crimson")>=0) { %>

We recommend Xerces 2 over Crimson as the XML parser for Axis

<% } %>

Examining System Properties

<% /** * Dump the system properties */ java.util.Enumeration e=null; try { e= System.getProperties().propertyNames(); } catch (SecurityException se) { } if(e!=null) { out.write("
");
        for (;e.hasMoreElements();) {
            String key = (String) e.nextElement();
            out.write(key + "=" + System.getProperty(key)+"\n");
        }
        out.write("

"); } else { out.write("System properties are not accessible

"); } %>


Platform: <%= getServletConfig().getServletContext().getServerInfo() %>

Reply via email to