1
|
<!DOCTYPE web-app PUBLIC
|
2
|
"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
|
3
|
"http://java.sun.com/dtd/web-app_2_3.dtd" >
|
4
|
<web-app>
|
5
|
<display-name>uoa-search</display-name>
|
6
|
<context-param>
|
7
|
<param-name>webAppRootKey</param-name>
|
8
|
<param-value>uoa-search</param-value>
|
9
|
</context-param>
|
10
|
<context-param>
|
11
|
<param-name>contextConfigLocation</param-name>
|
12
|
<param-value>/WEB-INF/applicationContext.xml</param-value>
|
13
|
</context-param>
|
14
|
<context-param>
|
15
|
<param-name>log4jConfigLocation</param-name>
|
16
|
<param-value>/WEB-INF/log4j.properties</param-value>
|
17
|
</context-param>
|
18
|
|
19
|
<listener>
|
20
|
<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
|
21
|
</listener>
|
22
|
<listener>
|
23
|
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
|
24
|
</listener>
|
25
|
<servlet>
|
26
|
<servlet-name>CXFServlet</servlet-name>
|
27
|
<display-name>CXF Servlet</display-name>
|
28
|
<servlet-class>org.apache.cxf.transport.servlet.CXFServlet</servlet-class>
|
29
|
<load-on-startup>1</load-on-startup>
|
30
|
</servlet>
|
31
|
|
32
|
<servlet>
|
33
|
<servlet-name>dispatcher</servlet-name>
|
34
|
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
|
35
|
<load-on-startup>1</load-on-startup>
|
36
|
</servlet>
|
37
|
|
38
|
<servlet-mapping>
|
39
|
<servlet-name>CXFServlet</servlet-name>
|
40
|
<url-pattern>/services/*</url-pattern>
|
41
|
</servlet-mapping>
|
42
|
|
43
|
<servlet-mapping>
|
44
|
<servlet-name>dispatcher</servlet-name>
|
45
|
<url-pattern>/</url-pattern>
|
46
|
</servlet-mapping>
|
47
|
|
48
|
<servlet>
|
49
|
<servlet-name>jersey-serlvet</servlet-name>
|
50
|
<servlet-class>com.sun.jersey.spi.spring.container.servlet.SpringServlet</servlet-class>
|
51
|
<init-param>
|
52
|
<param-name>com.sun.jersey.config.property.packages</param-name>
|
53
|
<param-value>eu.dnetlib.data.search.web.api</param-value>
|
54
|
</init-param>
|
55
|
<load-on-startup>1</load-on-startup>
|
56
|
</servlet>
|
57
|
<servlet-mapping>
|
58
|
<servlet-name>jersey-serlvet</servlet-name>
|
59
|
<url-pattern>/rest/*</url-pattern>
|
60
|
</servlet-mapping>
|
61
|
|
62
|
<filter>
|
63
|
<filter-name>CorsFilter</filter-name>
|
64
|
<filter-class>org.apache.catalina.filters.CorsFilter</filter-class>
|
65
|
<init-param>
|
66
|
<param-name>cors.allowed.origins</param-name>
|
67
|
<param-value>*</param-value>
|
68
|
</init-param>
|
69
|
<init-param>
|
70
|
<param-name>cors.allowed.methods</param-name>
|
71
|
<param-value>GET,POST,HEAD,OPTIONS,DELETE</param-value>
|
72
|
</init-param>
|
73
|
<init-param>
|
74
|
<param-name>cors.exposed.headers</param-name>
|
75
|
<param-value>Access-Control-Allow-Origin,Access-Control-Allow-Credentials,Access-Control-Allow-Methods</param-value>
|
76
|
</init-param>
|
77
|
<init-param>
|
78
|
<param-name>cors.support.credentials</param-name>
|
79
|
<param-value>true</param-value>
|
80
|
</init-param>
|
81
|
</filter>
|
82
|
|
83
|
<filter-mapping>
|
84
|
<filter-name>CorsFilter</filter-name>
|
85
|
<url-pattern>/*</url-pattern>
|
86
|
</filter-mapping>
|
87
|
<filter>
|
88
|
<filter-name>encodingFilter</filter-name>
|
89
|
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
|
90
|
<init-param>
|
91
|
<param-name>encoding</param-name>
|
92
|
<param-value>UTF-8</param-value>
|
93
|
</init-param>
|
94
|
<init-param>
|
95
|
<param-name>forceEncoding</param-name>
|
96
|
<param-value>true</param-value>
|
97
|
</init-param>
|
98
|
</filter>
|
99
|
|
100
|
<filter-mapping>
|
101
|
<filter-name>encodingFilter</filter-name>
|
102
|
<url-pattern>/*</url-pattern>
|
103
|
</filter-mapping>
|
104
|
|
105
|
|
106
|
<filter>
|
107
|
<filter-name>headerFilter</filter-name>
|
108
|
<filter-class>eu.dnetlib.data.search.HeaderFilter</filter-class>
|
109
|
</filter>
|
110
|
|
111
|
<filter-mapping>
|
112
|
<filter-name>headerFilter</filter-name>
|
113
|
<url-pattern>/*</url-pattern>
|
114
|
</filter-mapping>
|
115
|
|
116
|
</web-app>
|