<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE web-app
    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
    "http://java.sun.com/j2ee/dtds/web-app_2.2.dtd">

<web-app>



    <servlet>

        <!-- Defines the CDSServlet -->
        <servlet-name>
            cofaxCDS
        </servlet-name>
        <servlet-class>
            org.cofax.cds.CDSServlet
        </servlet-class>

	<!-- Defines glossary variables that template designers 
             can use across the site.  You can add new
             variables to this set by creating a new init-param, with 
             the param-name prefixed with "configGlossary:". -->         
        <init-param>
          <param-name>configGlossary:installationAt</param-name>
	  <param-value>Philadelphia, PA</param-value>
        </init-param>
        <init-param>
          <param-name>configGlossary:adminEmail</param-name>
	  <param-value>ksm@pobox.com</param-value>
        </init-param>
        <init-param>
          <param-name>configGlossary:poweredBy</param-name>
	  <param-value>Cofax</param-value>
        </init-param>
        <init-param>
          <param-name>configGlossary:poweredByIcon</param-name>
	  <param-value>/images/cofax.gif</param-value>
        </init-param>
        <init-param>
          <param-name>configGlossary:staticPath</param-name>
	  <param-value>/content/static</param-value>
        </init-param>



	<!-- Defines the template loader and template processor 
             classes.  These are implementations of org.cofax.TemplateProcessor 
             and org.cofax.TemplateLoader respectively.  Simply create new 
             implementation of these classes and set them here if the default 
             implementations do not suit your needs.  Leave these alone 
             for the defaults. -->
        <init-param>
          <param-name>templateProcessorClass</param-name>
	  <param-value>org.cofax.WysiwygTemplate</param-value>
        </init-param>

	<init-param>
          <param-name>templateLoaderClass</param-name>
	  <param-value>org.cofax.FilesTemplateLoader</param-value>
        </init-param>

 
        <!-- templatePath is a relative path from $TOMCAT_HOME/webapps/content 
             to look for WYSIWYG templates.  templateOverridePath is a full path 
             to a template location.  Normally you will leave these 
             at their defaults. -->
        <init-param>
          <param-name>templatePath</param-name>
	  <param-value>templates</param-value>
        </init-param>

        <init-param>
          <param-name>templateOverridePath</param-name>
	  <param-value></param-value>
        </init-param>


        <!-- Defines the names of the default templates to look for 
             when aquiring WYSIWYG templates.  Leave these at their 
             defaults for most usage. -->
	<init-param>
          <param-name>defaultListTemplate</param-name>
	  <param-value>listTemplate.htm</param-value>
        </init-param>

       <init-param>
          <param-name>defaultFileTemplate</param-name>
	  <param-value>articleTemplate.htm</param-value>
        </init-param>
	
       <!-- New! useJSP switches on JSP template processing.  
            jspListTemplate and jspFileTemplate are the names
            of the default templates to look for when aquiring JSP 
            templates.  Cofax currently in production at KR has useJSP 
            set to false, since our sites currently use WYSIWYG
            templating exclusively. -->
       <init-param>
          <param-name>useJSP</param-name>
	  <param-value>false</param-value>
        </init-param>

	<init-param>
          <param-name>jspListTemplate</param-name>
	  <param-value>listTemplate.jsp</param-value>
        </init-param>

       <init-param>
          <param-name>jspFileTemplate</param-name>
	  <param-value>articleTemplate.jsp</param-value>
        </init-param>


	
	<!--  Defines the packageTag cache.  This cache keeps
              Cofax from needing to interact with the database
              to look up packageTag commands.  -->
	<init-param>
          <param-name>cachePackageTagsTrack</param-name>
	  <param-value>200</param-value>
        </init-param>

	<init-param>
          <param-name>cachePackageTagsStore</param-name>
	  <param-value>200</param-value>
        </init-param>

	<init-param>
          <param-name>cachePackageTagsRefresh</param-name>
	  <param-value>60</param-value>
        </init-param>

	<!-- Defines the template cache.  Keeps Cofax from needing
             to go to the file system to load a raw template from
             the file system. -->
	<init-param>
          <param-name>cacheTemplatesTrack</param-name>
	  <param-value>100</param-value>
        </init-param>

	<init-param>
          <param-name>cacheTemplatesStore</param-name>
	  <param-value>50</param-value>
        </init-param>

	<init-param>
          <param-name>cacheTemplatesRefresh</param-name>
	  <param-value>15</param-value>
        </init-param>

	<!-- Defines the page cache.  Keeps Cofax from processing
             templates to deliver to users.  -->
	<init-param>
          <param-name>cachePagesTrack</param-name>
	  <param-value>200</param-value>
        </init-param>

	<init-param>
          <param-name>cachePagesStore</param-name>
	  <param-value>100</param-value>
        </init-param>

	<init-param>
          <param-name>cachePagesRefresh</param-name>
	  <param-value>10</param-value>
        </init-param>

	<init-param>
          <param-name>cachePagesDirtyRead</param-name>
	  <param-value>10</param-value>
        </init-param>

    
	<!-- Defines the templates Cofax will use when
             being browsed by a search engine identified in 
             searchEngineRobotsDb  -->
	<init-param>
          <param-name>searchEngineListTemplate</param-name>
	  <param-value>forSearchEnginesList.htm</param-value>
        </init-param>

       <init-param>
          <param-name>searchEngineFileTemplate</param-name>
	  <param-value>forSearchEngines.htm</param-value>
        </init-param>

       <init-param>
          <param-name>searchEngineRobotsDb</param-name>
	  <param-value>WEB-INF/robots.db</param-value>
        </init-param>


	<!-- New!  useDataStore enables/disables the Cofax database pool -->	
	<init-param>
          <param-name>useDataStore</param-name>
	  <param-value>true</param-value>
        </init-param>

        <!-- Defines the implementation of org.cofax.DataStore that Cofax
             will use.  If this DataStore class does not suit your needs
             simply implement a new DataStore class and set here. -->
	<init-param>
          <param-name>dataStoreClass</param-name>
	  <param-value>org.cofax.SqlDataStore</param-value>
        </init-param>

        <!-- Defines the implementation of org.cofax.Redirection that
             Cofax will use.  If this Redirection class does not suit
             your needs simply implenet a new Redirection class
             and set here. -->
	<init-param>
          <param-name>redirectionClass</param-name>
	  <param-value>org.cofax.SqlRedirection</param-value>
        </init-param>

        <!-- Defines the data store name.   Keep this at the default -->
        <init-param> 
          <param-name>dataStoreName</param-name>
	  <param-value>cofax</param-value>
        </init-param>


        <!-- Defines the JDBC driver that Cofax's database pool 
             will use -->
        <init-param>
          <param-name>dataStoreDriver</param-name>
	  <param-value>com.microsoft.jdbc.sqlserver.SQLServerDriver</param-value>
        </init-param>

        <!-- Defines the JDBC connection URL to connect to the database -->
        <init-param>
          <param-name>dataStoreUrl</param-name>
	  <param-value>jdbc:microsoft:sqlserver://LOCALHOST:1433;DatabaseName=goon</param-value>
        </init-param>


        <!-- Defines the user name to connect to the database -->
	<init-param>
          <param-name>dataStoreUser</param-name>
	  <param-value>sa</param-value>
        </init-param>

        <!-- Defines the password to connect to the database -->
	<init-param>
          <param-name>dataStorePassword</param-name>
	  <param-value></param-value>
        </init-param>

        <!-- A query that will run to test the validity of the 
             connection in the pool.  -->
	<init-param>
          <param-name>dataStoreTestQuery</param-name>
	  <param-value>SET NOCOUNT ON;select test='test';</param-value>
        </init-param>

        <!-- A log file to print out database information -->
	<init-param>
          <param-name>dataStoreLogFile</param-name>
	  <param-value>/usr/local/tomcat/logs/datastore.log</param-value>
        </init-param>

        <!-- The number of connection to initialize on startup -->
	<init-param>
          <param-name>dataStoreInitConns</param-name>
	  <param-value>10</param-value>
        </init-param>
	
        <!-- The maximum number of connection to use in the pool -->
	<init-param>
          <param-name>dataStoreMaxConns</param-name>
	  <param-value>100</param-value>
        </init-param>

        <!-- The number of times a connection will be utilized from the
             pool before disconnect -->
	<init-param>
          <param-name>dataStoreConnUsageLimit</param-name>
	  <param-value>100</param-value>
        </init-param>

        <!-- The level of information to print to the log -->
	<init-param>
          <param-name>dataStoreLogLevel</param-name>
	  <param-value>debug</param-value>
        </init-param>

	<!-- The maximum URL length allowable by the CDS Servlet 
             Helps to prevent hacking  -->
	<init-param>
          <param-name>maxUrlLength</param-name>
	  <param-value>500</param-value>
        </init-param>
		
    </servlet>

    <!-- Defines the Email Servlet -->
    <servlet>
        <servlet-name>
            cofaxEmail
        </servlet-name>
        <servlet-class>
            org.cofax.cds.EmailServlet
        </servlet-class>
     
        <!-- The mail host to be used by the mail servlet -->
        <init-param>
          <param-name>mailHost</param-name>
	  <param-value>mail1</param-value>
        </init-param>

        <!-- An override -->
        <init-param>
          <param-name>mailHostOverride</param-name>
	  <param-value>mail2</param-value>
        </init-param>
    </servlet>

   <!-- Defines the Admin Servlet - used to refresh cache on 
        demand and see statistics -->
   <servlet>
        <servlet-name>
            cofaxAdmin
        </servlet-name>
        <servlet-class>
            org.cofax.cds.AdminServlet
        </servlet-class>
    </servlet>


   <!-- Defines the File Servlet - used to display files like Apache -->
 	<servlet>
         <servlet-name>
             fileServlet
         </servlet-name>
         <servlet-class>
             org.cofax.cds.FileServlet
         </servlet-class>        
 	</servlet>



   <servlet>
        <servlet-name>
            cofaxTools
        </servlet-name>
        <servlet-class>
            org.cofax.cms.CofaxToolsServlet
        </servlet-class>        

		<!-- Path to the template folder relative to the tools tomcat installation. -->
		<init-param>
		  <param-name>templatePath</param-name>
		  <param-value>toolstemplates/</param-value>
		</init-param>


		<!-- Logging boolean 1 = on, 0 = off -->
		<init-param>
		  <param-name>log</param-name>
		  <param-value>1</param-value>
		</init-param>

		<!-- Location of log. If empty, log will be written System.out -->
		<init-param>
		  <param-name>logLocation</param-name>
		  <param-value>/usr/local/tomcat/logs/CofaxTools.log</param-value>
		</init-param>

		<!-- Max size of log in BITS. If size is empty, no limit to log. -->
		<!-- If size is defined, log will be overwritten upon reaching defined size. -->
		<init-param>
		  <param-name>logMaxSize</param-name>
		  <param-value></param-value>
		</init-param>


		<!-- DataStore logging boolean 1 = on, 0 = off -->
		<init-param>
		  <param-name>dataLog</param-name>
		  <param-value>1</param-value>
		</init-param>

		<!-- DataStore location of log. If empty, log will be written System.out -->
		<init-param>
		  <param-name>dataLogLocation</param-name>
		  <param-value>/usr/local/tomcat/logs/dataLog.log</param-value>
		</init-param>

		<!-- Max size of log in BITS. If size is empty, no limit to log. -->
		<!-- If size is defined, log will be overwritten upon reaching defined size. -->
		<init-param>
		  <param-name>dataLogMaxSize</param-name>
		  <param-value></param-value>
		</init-param>

		<!-- Http string relative to server root to call for page cache removal to Cofax Servlet. -->
		<init-param>
		  <param-name>removePageCache</param-name>
		  <param-value>/content/admin/remove?cache=pages&amp;id=</param-value>
		</init-param>


		<!-- Http string relative to server root to call for template cache removal to Cofax Servlet. -->
		<init-param>
		  <param-name>removeTemplateCache</param-name>
		  <param-value>/content/admin/remove?cache=templates&amp;id=</param-value>
		</init-param>


		<!-- Location of folder from root of drive that will be used for ftp transfer from beta server -->
		<!-- or user hard drive to live servers. Note that Edit Article will not function without this variable -->
		<!-- set correctly. MultiPart request relies upon access to this folder. -->
		<init-param>
		  <param-name>fileTransferFolder</param-name>
		  <param-value>/usr/local/tomcat/webapps/content/fileTransferFolder</param-value>
		</init-param>


		<!-- Defines whether the Server should look in another path for config files or variables. -->
		<init-param>
		  <param-name>lookInContext</param-name>
		  <param-value>1</param-value>
		</init-param>	

		<!-- Number of the ID of the top level administration group in tblPermGroups. -->
		<init-param>
		  <param-name>adminGroupID</param-name>
		  <param-value>4</param-value>
		</init-param>

		<!-- Is the tools app running on  the 'beta server'. -->
		<init-param>
		  <param-name>betaServer</param-name>
		  <param-value>true</param-value>
		</init-param>



    </servlet>



    <!-- URL mapping for the CDS Servlet -->
    <servlet-mapping>
	<servlet-name>
	cofaxCDS
	</servlet-name>
	<url-pattern>
	/
	</url-pattern>
    </servlet-mapping>

    <!-- URL mapping for the Email Servlet -->
    <servlet-mapping>
	<servlet-name>
	cofaxEmail
	</servlet-name>
	<url-pattern>
	/cofaxutil/aemail/*
	</url-pattern>
    </servlet-mapping>

    <!-- URL mapping for the Admin servlet -->
    <servlet-mapping>
        <servlet-name>
        cofaxAdmin
        </servlet-name>
        <url-pattern>
        /admin/*
        </url-pattern>
    </servlet-mapping>

    <!-- URL mapping for the Files servlet -->
     <servlet-mapping>
         <servlet-name>
         fileServlet
         </servlet-name>
         <url-pattern>
         /static/*
         </url-pattern>
     </servlet-mapping>

  <servlet-mapping>
        <servlet-name>
        cofaxTools
        </servlet-name>
        <url-pattern>
        /tools/*
        </url-pattern>
    </servlet-mapping>



   <!-- New! The cofax taglib descriptor file -->
   <taglib>
      <taglib-uri>cofax.tld</taglib-uri>
      <taglib-location>/WEB-INF/tlds/cofax.tld</taglib-location>
   </taglib>



</web-app>
