<?xml version="1.0"?>
<!--
  ~ JBoss, Home of Professional Open Source
  ~ Copyright 2009 Red Hat Inc. and/or its affiliates and other
  ~ contributors as indicated by the @author tags. All rights reserved.
  ~ See the copyright.txt in the distribution for a full listing of
  ~ individual contributors.
  ~
  ~ This is free software; you can redistribute it and/or modify it
  ~ under the terms of the GNU Lesser General Public License as
  ~ published by the Free Software Foundation; either version 2.1 of
  ~ the License, or (at your option) any later version.
  ~
  ~ This software is distributed in the hope that it will be useful,
  ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
  ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  ~ Lesser General Public License for more details.
  ~
  ~ You should have received a copy of the GNU Lesser General Public
  ~ License along with this software; if not, write to the Free
  ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
  ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
  -->
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
        "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>

   <display-name>Infinispan cache REST server</display-name>

   <context-param>
      <param-name>resteasy.resources</param-name>
      <param-value>org.infinispan.rest.Server</param-value>
   </context-param>


   <listener>
      <listener-class>org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap</listener-class>
   </listener>

   <servlet>
      <servlet-name>InitServlet</servlet-name>
      <servlet-class>org.infinispan.rest.StartupListener</servlet-class>

      <!-- Specify your cache configuration file -->
      <init-param>
         <param-name>infinispan.config</param-name>
         <param-value>config-samples/sample.xml</param-value>
      </init-param>

      <!-- Managed bean name to look up when the REST server is running an app server -->
      <init-param>
         <param-name>infinispan.cachemanager.bean</param-name>
         <param-value>DefaultCacheManager</param-value>
      </init-param>

      <load-on-startup>1</load-on-startup>
   </servlet>

   <servlet>
      <servlet-name>Resteasy</servlet-name>
      <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>
   </servlet>

   <servlet-mapping>
      <servlet-name>Resteasy</servlet-name>
      <url-pattern>/rest/*</url-pattern>
   </servlet-mapping>

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


</web-app>

