Changeset 10127


Ignore:
Timestamp:
2005-06-16T15:31:25+12:00 (19 years ago)
Author:
kjdon
Message:

axis is now installed as part of the greenstone web app - otherwise axis has trouble finding greenstone classes, and greenstone has trouble finding axis classes. the servlet definitions are now included in greenstones web.xml file. also moved to version 1.2.1 of axis. need to make it so that axis is optional

Location:
trunk/gsdl3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl3/build.xml

    r10116 r10127  
    302302    <available file="${basedir}/gs2build" property="gs2build.present"/>
    303303    <available file="${basedir}/comms/soap/axis" property="axis.present"/>
    304     <available file="${catalina.home}/webapps/axis" property="axis.installed"/>
    305304    <condition property="gsdl2.islocal">
    306305      <or>
     
    437436      <fileset dir="${basedir}/comms/jakarta/jakarta-tomcat-5.5.7"/>
    438437    </move>
     438    <copy file="${basedir}/comms/jakarta/setclasspath.bat"
     439      tofile="${basedir}/comms/jakarta/tomcat/bin/setclasspath.bat"
     440      overwrite="true"/>
     441    <copy file="${basedir}/comms/jakarta/setclasspath.sh"
     442      tofile="${basedir}/comms/jakarta/tomcat/bin/setclasspath.sh"
     443      overwrite="true"/>
    439444    <!-- make sure we have execute permission for the .sh files -->
    440445    <chmod dir="${basedir}/comms/jakarta/tomcat/bin" perm="ugo+rx"
    441446      includes="*.sh"/>
    442     <copy file="${basedir}/comms/jakarta/setclasspath.bat"
    443       tofile="${basedir}/comms/jakarta/tomcat/bin/setclasspath.bat"
    444       overwrite="true"/>
    445447  </target>
    446448
     
    678680  <target name="prepare-axis" depends="init">
    679681    <mkdir dir="${basedir}/comms/soap"/>
    680     <get src="http://www.greenstone.org/gs3files/axis-1_1.zip"
    681       dest="${basedir}/comms/soap/axis-1_1.zip"
     682    <get src="http://www.greenstone.org/gs3files/axis-bin-1_2_1.zip"
     683      dest="${basedir}/comms/soap/axis-bin-1_2_1.zip"
    682684      usetimestamp="true"/>
    683685    <delete dir="${basedir}/comms/soap/axis.bak"/>
     
    685687      <fileset dir="${basedir}/comms/soap/axis"/>
    686688    </move>
    687     <unzip src="${basedir}/comms/soap/axis-1_1.zip"
     689    <unzip src="${basedir}/comms/soap/axis-bin-1_2_1.zip"
    688690      dest="${basedir}/comms/soap/"/>
    689691    <move todir="${basedir}/comms/soap/axis">
    690       <fileset dir="${basedir}/comms/soap/axis-1_1"/>
     692      <fileset dir="${basedir}/comms/soap/axis-1_2_1"/>
    691693    </move>
    692     <!-- install the webapp into tomcat -->
    693     <copy todir="${catalina.home}/webapps/axis">
    694       <fileset dir="${basedir}/comms/soap/axis/webapps/axis"/>
     694    <!-- install axis into greenstone web app -->
     695    <copy todir="${web.lib}">
     696      <fileset dir="${basedir}/comms/soap/axis/webapps/axis/WEB-INF/lib/*.jar"/>
     697    </copy>
     698    <copy todir="${web.home}">
     699      <fileset dir="${basedir}/comms/soap/axis/webapps/axis/*.jsp"/>
     700      <fileset dir="${basedir}/comms/soap/axis/webapps/axis/*.jws"/>
     701    </copy>
     702    <copy tofile="${web.home}/axis.html" file="${basedir}/comms/soap/axis/webapps/axis/index.html"/>
     703    <copy todir="${web.classes}">
     704      <fileset dir="${basedir}/comms/soap/axis/webapps/axis/WEB-INF/classes/*.properties"/>
    695705    </copy>
    696706  </target>
     
    700710    <java classname="org.apache.axis.client.AdminClient">
    701711      <classpath refid="compile.classpath"/>
    702       <arg value="-p"/>
    703       <arg value="${tomcat.port}"/>
     712      <arg value="-l"/>
     713      <arg value="http://${tomcat.server}:${tomcat.port}${app.path}/servlet/AxisServlet"/>
    704714      <arg file="${basedir}/resources/soap/${axis.sitename}.wsdd"/>
    705715    </java>   
     
    710720    <java classname="org.apache.axis.client.AdminClient">
    711721      <classpath refid="compile.classpath"/>
    712       <arg value="-p"/>
    713       <arg value="${tomcat.port}"/>
     722      <arg value="-l"/>
     723      <arg value="http://${tomcat.server}:${tomcat.port}${app.path}/servlet/AxisServlet"/>
    714724      <arg file="${basedir}/resources/soap/undeploy-${axis.sitename}.wsdd"/>
    715725    </java>
  • trunk/gsdl3/web/WEB-INF/web.xml.in

    r7833 r10127  
    1111
    1212
    13     <!-- General description of your web application -->
    14 
    15     <display-name>GSDL3</display-name>
     13  <!-- General description of your web application -->
     14 
     15  <display-name>GSDL3</display-name>
     16  <description>
     17    Greenstone digital library version 3.
     18  </description>
     19 
     20 
     21  <!-- Context initialization parameters that define shared
     22  String constants used within your application, which
     23  can be customized by the system administrator who is
     24  installing your application.  The values actually
     25  assigned to these parameters can be retrieved in a
     26  servlet or JSP page by calling:
     27 
     28  String value =
     29  getServletContext().getInitParameter("name");
     30 
     31  where "name" matches the <param-name> element of
     32  one of these initialization parameters.
     33 
     34  You can define any number of context initialization
     35  parameters, including zero.
     36  -->
     37 
     38  <context-param>
     39    <param-name>webmaster</param-name>
     40    <param-value>[email protected]</param-value>
    1641    <description>
    17       Greenstone digital library version 3.
     42      The EMAIL address of the administrator to whom questions
     43      and comments about this application should be addressed.
    1844    </description>
    19 
    20 
    21     <!-- Context initialization parameters that define shared
    22          String constants used within your application, which
    23          can be customized by the system administrator who is
    24          installing your application.  The values actually
    25          assigned to these parameters can be retrieved in a
    26          servlet or JSP page by calling:
    27 
    28              String value =
    29                getServletContext().getInitParameter("name");
    30 
    31          where "name" matches the <param-name> element of
    32          one of these initialization parameters.
    33 
    34          You can define any number of context initialization
    35          parameters, including zero.
    36     -->
    37 
    38     <context-param>
    39       <param-name>webmaster</param-name>
    40       <param-value>[email protected]</param-value>
    41       <description>
    42         The EMAIL address of the administrator to whom questions
    43         and comments about this application should be addressed.
    44       </description>
    45     </context-param>
    46 
    47 
    48     <!-- Servlet definitions for the servlets that make up
    49          your web application, including initialization
    50          parameters.  With Tomcat, you can also send requests
    51          to servlets not listed here with a request like this:
    52 
    53            http://localhost:8080/{context-path}/servlet/{classname}
    54 
    55          but this usage is not guaranteed to be portable.  It also
    56          makes relative references to images and other resources
    57          required by your servlet more complicated, so defining
    58          all of your servlets (and defining a mapping to them with
    59          a servlet-mapping element) is recommended.
    60 
    61          Servlet initialization parameters can be retrieved in a
    62          servlet or JSP page by calling:
    63 
    64              String value =
    65                getServletConfig().getInitParameter("name");
    66 
    67          where "name" matches the <param-name> element of
    68          one of these initialization parameters.
    69 
    70          You can define any number of servlets, including zero.
    71     -->
    72     <!-- Note: I have left this one in as an example -kjdon -->
    73     <!--
    74     <servlet>
    75       <servlet-name>controller</servlet-name>
    76       <description>
    77         This servlet plays the "controller" role in the MVC architecture
    78         used in this application.  It is generally mapped to the ".do"
    79         filename extension with a <servlet-mapping> element, and all form
    80         submits in the app will be submitted to a request URI like
    81         "saveCustomer.do", which will therefore be mapped to this servlet.
    82 
    83         The initialization parameter namess for this servlet are the
    84         "servlet path" that will be received by this servlet (after the
    85         filename extension is removed).  The corresponding value is the
    86         name of the action class that will be used to process this request.
    87       </description>
    88       <servlet-class>com.mycompany.mypackage.ControllerServlet</servlet-class>
    89       <init-param>
    90         <param-name>listOrders</param-name>
    91         <param-value>com.mycompany.myactions.ListOrdersAction</param-value>
    92       </init-param>
    93       <init-param>
    94         <param-name>saveCustomer</param-name>
    95         <param-value>com.mycompany.myactions.SaveCustomerAction</param-value>
    96       </init-param>
    97       <! Load this servlet at server startup time >
    98       <load-on-startup>5</load-on-startup>
    99     </servlet>
    100     -->
    101     <servlet>
    102       <servlet-name>tester</servlet-name>
    103       <description>a test servlet</description>
    104       <servlet-class>TestServlet</servlet-class>
    105     </servlet>
    106 
    107     <servlet>
    108       <servlet-name>library</servlet-name>
    109       <description>gsdl3 library program</description>
    110       <servlet-class>org.greenstone.gsdl3.LibraryServlet</servlet-class>
    111       <init-param>
    112         <param-name>library_name</param-name>
    113     <param-value>library</param-value>
    114       </init-param>
    115       <init-param>
    116         <param-name>gsdl3_home</param-name>
    117         <param-value>@gsdl3home@</param-value>
    118       </init-param>
    119       <init-param>
    120         <param-name>site_name</param-name>
    121         <param-value>localsite</param-value>
    122       </init-param>
    123       <init-param>
    124         <param-name>interface_name</param-name>
    125         <param-value>default</param-value>
    126       </init-param>
    127       <init-param>
    128         <param-name>default_lang</param-name>
    129         <param-value>en</param-value>
    130       </init-param>
    131      </servlet>
    132 
    133     <servlet>
    134       <servlet-name>gateway</servlet-name>
    135       <description>gsdl3 library program</description>
    136       <servlet-class>org.greenstone.gsdl3.LibraryServlet</servlet-class>
    137       <init-param>
    138         <param-name>library_name</param-name>
    139     <param-value>gateway</param-value>
    140       </init-param>
    141       <init-param>
    142         <param-name>gsdl3_home</param-name>
    143         <param-value>@gsdl3home@</param-value>
    144       </init-param>
     45  </context-param>
     46 
     47
     48  <!-- Servlet definitions for the servlets that make up
     49  your web application, including initialization
     50  parameters.  With Tomcat, you can also send requests
     51  to servlets not listed here with a request like this:
     52
     53  http://localhost:8080/{context-path}/servlet/{classname}
     54 
     55  but this usage is not guaranteed to be portable.  It also
     56  makes relative references to images and other resources
     57  required by your servlet more complicated, so defining
     58  all of your servlets (and defining a mapping to them with
     59  a servlet-mapping element) is recommended.
     60 
     61  Servlet initialization parameters can be retrieved in a
     62  servlet or JSP page by calling:
     63 
     64  String value =
     65  getServletConfig().getInitParameter("name");
     66 
     67  where "name" matches the <param-name> element of
     68  one of these initialization parameters.
     69 
     70  You can define any number of servlets, including zero.
     71  -->
     72  <!-- Note: I have left this one in as an example -kjdon -->
     73  <!--
     74  <servlet>
     75    <servlet-name>controller</servlet-name>
     76    <description>
     77      This servlet plays the "controller" role in the MVC architecture
     78      used in this application.  It is generally mapped to the ".do"
     79      filename extension with a <servlet-mapping/> element, and all form
     80      submits in the app will be submitted to a request URI like
     81      "saveCustomer.do", which will therefore be mapped to this servlet.
     82     
     83      The initialization parameter namess for this servlet are the
     84      "servlet path" that will be received by this servlet (after the
     85      filename extension is removed).  The corresponding value is the
     86      name of the action class that will be used to process this request.
     87     
     88    </description>
     89    <servlet-class>com.mycompany.mypackage.ControllerServlet</servlet-class>
     90    <init-param>
     91      <param-name>listOrders</param-name>
     92      <param-value>com.mycompany.myactions.ListOrdersAction</param-value>
     93    </init-param>
     94    <init-param>
     95      <param-name>saveCustomer</param-name>
     96      <param-value>com.mycompany.myactions.SaveCustomerAction</param-value>
     97    </init-param>
     98    <! Load this servlet at server startup time >
     99    <load-on-startup>5</load-on-startup>
     100  </servlet>
     101  -->
     102  <servlet>
     103    <servlet-name>tester</servlet-name>
     104    <description>a test servlet</description>
     105    <servlet-class>TestServlet</servlet-class>
     106  </servlet>
     107 
     108  <servlet>
     109    <servlet-name>library</servlet-name>
     110    <description>gsdl3 library program</description>
     111    <servlet-class>org.greenstone.gsdl3.LibraryServlet</servlet-class>
     112    <init-param>
     113      <param-name>library_name</param-name>
     114      <param-value>library</param-value>
     115    </init-param>
     116    <init-param>
     117      <param-name>gsdl3_home</param-name>
     118      <param-value>@gsdl3home@</param-value>
     119    </init-param>
     120    <init-param>
     121      <param-name>site_name</param-name>
     122      <param-value>localsite</param-value>
     123    </init-param>
     124    <init-param>
     125      <param-name>interface_name</param-name>
     126      <param-value>default</param-value>
     127    </init-param>
     128    <init-param>
     129      <param-name>default_lang</param-name>
     130      <param-value>en</param-value>
     131    </init-param>
     132  </servlet>
     133 
     134  <servlet>
     135    <servlet-name>gateway</servlet-name>
     136    <description>gsdl3 library program</description>
     137    <servlet-class>org.greenstone.gsdl3.LibraryServlet</servlet-class>
     138    <init-param>
     139      <param-name>library_name</param-name>
     140      <param-value>gateway</param-value>
     141    </init-param>
     142    <init-param>
     143      <param-name>gsdl3_home</param-name>
     144      <param-value>@gsdl3home@</param-value>
     145    </init-param>
    145146      <init-param>
    146147        <param-name>site_name</param-name>
     
    155156        <param-value>en</param-value>
    156157      </init-param>
    157     </servlet>
    158   <servlet>
     158  </servlet>
     159 
     160  <servlet>
     161   
    159162    <servlet-name>classic-library</servlet-name>
    160163    <description>gsdl3 library program</description>
     
    186189  </servlet>
    187190
     191  <!-- axis servlets -->
     192  <servlet>
     193    <servlet-name>AxisServlet</servlet-name>
     194    <display-name>Apache-Axis Servlet</display-name>
     195    <servlet-class>
     196        org.apache.axis.transport.http.AxisServlet
     197    </servlet-class>
     198  </servlet>
     199
     200  <servlet>
     201    <servlet-name>AdminServlet</servlet-name>
     202    <display-name>Axis Admin Servlet</display-name>
     203    <servlet-class>
     204        org.apache.axis.transport.http.AdminServlet
     205    </servlet-class>
     206    <load-on-startup>100</load-on-startup>
     207  </servlet>
     208
     209  <servlet>
     210    <servlet-name>SOAPMonitorService</servlet-name>
     211    <display-name>SOAPMonitorService</display-name>
     212    <servlet-class>
     213        org.apache.axis.monitor.SOAPMonitorService
     214    </servlet-class>
     215    <init-param>
     216      <param-name>SOAPMonitorPort</param-name>
     217      <param-value>5001</param-value>
     218    </init-param>
     219    <load-on-startup>100</load-on-startup>
     220 
    188221    <!-- Define mappings that are used by the servlet container to
    189222         translate a particular request URI (context-relative) to a
     
    216249    </servlet-mapping>
    217250    -->
    218 
    219     <servlet-mapping>
    220       <servlet-name>tester</servlet-name>
    221       <url-pattern>/testing</url-pattern>
    222     </servlet-mapping>
    223 
    224     <servlet-mapping>
    225       <servlet-name>library</servlet-name>
    226       <url-pattern>/library</url-pattern>
    227     </servlet-mapping>
    228 
    229     <servlet-mapping>
    230       <servlet-name>gateway</servlet-name>
    231       <url-pattern>/gateway</url-pattern>
    232     </servlet-mapping>
    233  
    234     <servlet-mapping>
    235       <servlet-name>classic-library</servlet-name>
    236       <url-pattern>/classic</url-pattern>
    237     </servlet-mapping>
    238    
    239     <!-- Define the default session timeout for your application,
    240          in minutes.  From a servlet or JSP page, you can modify
    241          the timeout for a particular session dynamically by using
    242          HttpSession.getMaxInactiveInterval(). -->
    243 
    244     <session-config>
    245       <session-timeout>30</session-timeout>    <!-- 30 minutes -->
    246     </session-config>
    247 
    248 
     251 
     252  <servlet-mapping>
     253    <servlet-name>tester</servlet-name>
     254    <url-pattern>/testing</url-pattern>
     255  </servlet-mapping>
     256 
     257  <servlet-mapping>
     258    <servlet-name>library</servlet-name>
     259    <url-pattern>/library</url-pattern>
     260  </servlet-mapping>
     261 
     262  <servlet-mapping>
     263    <servlet-name>gateway</servlet-name>
     264    <url-pattern>/gateway</url-pattern>
     265  </servlet-mapping>
     266 
     267  <servlet-mapping>
     268    <servlet-name>classic-library</servlet-name>
     269    <url-pattern>/classic</url-pattern>
     270  </servlet-mapping>
     271 
     272  <!-- axis mappings -->
     273  <servlet-mapping>
     274    <servlet-name>AxisServlet</servlet-name>
     275    <url-pattern>/servlet/AxisServlet</url-pattern>
     276  </servlet-mapping>
     277
     278  <servlet-mapping>
     279    <servlet-name>AxisServlet</servlet-name>
     280    <url-pattern>*.jws</url-pattern>
     281  </servlet-mapping>
     282
     283  <servlet-mapping>
     284    <servlet-name>AxisServlet</servlet-name>
     285    <url-pattern>/services/*</url-pattern>
     286  </servlet-mapping>
     287
     288  <!-- uncomment this if you want to use the SOAPMonitorService. You will also
     289  need to copy the SOAPMonitorService*.class files from
     290  comms/soap/axis/web/WEB-INF/classes to the web directory. See the
     291  commms/soap/axis/docs/install.html Appendix for details about how to use this -->
     292  <!--
     293  <servlet-mapping>
     294    <servlet-name>SOAPMonitorService</servlet-name>
     295    <url-pattern>/SOAPMonitor</url-pattern>
     296  </servlet-mapping>
     297  -->
     298  <!-- uncomment this if you want the admin servlet -->
     299  <!--
     300  <servlet-mapping>
     301    <servlet-name>AdminServlet</servlet-name>
     302    <url-pattern>/servlet/AdminServlet</url-pattern>
     303  </servlet-mapping>
     304  -->
     305
     306  <!-- Define the default session timeout for your application,
     307  in minutes.  From a servlet or JSP page, you can modify
     308  the timeout for a particular session dynamically by using
     309  HttpSession.getMaxInactiveInterval(). -->
     310
     311  <session-config>
     312    <session-timeout>30</session-timeout>    <!-- 30 minutes -->
     313  </session-config>
     314
     315  <!-- axis mime-mappings -->
     316  <mime-mapping>
     317    <extension>wsdl</extension>
     318    <mime-type>text/xml</mime-type>
     319  </mime-mapping>
     320 
     321  <mime-mapping>
     322    <extension>xsd</extension>
     323    <mime-type>text/xml</mime-type>
     324  </mime-mapping>
     325 
    249326</web-app>
    250327
Note: See TracChangeset for help on using the changeset viewer.