<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd "
         metadata-complete="false"
         version="2.5">

    <display-name>LTS Admin</display-name>

    <welcome-file-list>
        <welcome-file>index.htm</welcome-file>
    </welcome-file-list>

    <context-param>
        <param-name>contextConfigLocation</param-name>
        <param-value>classpath:spring-core.xml</param-value>
    </context-param>

    <filter>
        <filter-name>loginAuthFilter</filter-name>
        <filter-class>com.lts.admin.web.filter.LoginAuthFilter</filter-class>
        <init-param>
            <param-name>auth-config</param-name>
            <param-value>auth.cfg</param-value>
        </init-param>
    </filter>
    <filter-mapping>
        <filter-name>loginAuthFilter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <servlet>
        <servlet-name>spring</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <init-param>
            <param-name>contextConfigLocation</param-name>
            <param-value>classpath:spring-web.xml</param-value>
        </init-param>
        <load-on-startup>1</load-on-startup>
    </servlet>

    <servlet-mapping>
        <servlet-name>spring</servlet-name>
        <url-pattern>/api/*</url-pattern>
    </servlet-mapping>

    <servlet-mapping>
        <servlet-name>spring</servlet-name>
        <url-pattern>*.htm</url-pattern>
    </servlet-mapping>

    <listener>
        <listener-class>com.lts.admin.support.SystemInitListener</listener-class>
    </listener>

    <listener>
        <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>

    <!--<servlet>-->
        <!--<servlet-name>H2Console</servlet-name>-->
        <!--<servlet-class>com.lts.admin.web.support.H2ConsoleWebServlet</servlet-class>-->
        <!--<load-on-startup>1</load-on-startup>-->
    <!--</servlet>-->
    <!--<servlet-mapping>-->
        <!--<servlet-name>H2Console</servlet-name>-->
        <!--<url-pattern>/h2/*</url-pattern>-->
    <!--</servlet-mapping>-->

</web-app>
