summaryrefslogtreecommitdiffstats
path: root/epsdk-app-onap/src/main/webapp/WEB-INF/web.xml
blob: 6007fdc227ddab41a90e309d8316b65efbea8509 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
         version="3.1">
	<display-name>ecomp-sdk-app-os</display-name>

	<!-- The app can function on a HA cluster -->
	<distributable />

	<session-config>
		<session-timeout>30</session-timeout>
		<tracking-mode>COOKIE</tracking-mode>
	</session-config>

	<filter>
    <filter-name>SecurityXssFilter</filter-name>
    <filter-class>org.onap.portalapp.filter.SecurityXssFilter</filter-class>
   </filter> 
    <filter-mapping>
    <filter-name>SecurityXssFilter</filter-name>
    <url-pattern>/*</url-pattern>
  </filter-mapping>

  <!--
  `vid-webpack-master` servlet and it's servlet mapping below, serves
  Angular's index.html for any requests like the following, letting
  the JavaScript router do its magic:
  * /vid/app/ui/
  * /vid/app/ui/servicePlanning
  * /vid/app/ui/browseSdc
  -->
  <servlet>
    <servlet-name>vid-webpack-master</servlet-name>
    <jsp-file>/app/ui/index.html</jsp-file>
  </servlet>

  <servlet-mapping>
    <servlet-name>vid-webpack-master</servlet-name>
    <url-pattern>/app/ui/</url-pattern>
  </servlet-mapping>

  <!--
  All the files under the paths below are served as static files, using
  tomcat's `default` servlet. This overrides the `vid-webpack-master`
  url-pattern.
  The filter `charset-to-utf8-filter` adds "charset=UTF-8" to these files
  content type, as the default content-type is platform-dependant (which
  is not ok for Windows stations).
  -->
  <servlet-mapping>
    <servlet-name>default</servlet-name>
    <url-pattern>/app/ui/*</url-pattern>
  </servlet-mapping>

  <filter>
    <filter-name>charset-to-utf8-filter</filter-name>
    <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
    <init-param>
      <param-name>encoding</param-name>
      <param-value>UTF-8</param-value>
    </init-param>
    <init-param>
      <param-name>forceEncoding</param-name>
      <param-value>true</param-value>
    </init-param>
  </filter>

  <filter-mapping>
    <filter-name>charset-to-utf8-filter</filter-name>
    <url-pattern>/app/ui/*</url-pattern>
  </filter-mapping>

</web-app>