Author: fmui
Date: Wed Oct 1 17:07:44 2014
New Revision: 1628777
URL: http://svn.apache.org/r1628777
Log:
CMIS-842: added CORS configuration examples to the server-bindings-war and the
server-archetype projects
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-archetype/src/main/resources/archetype-resources/pom.xml
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/pom.xml
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/src/main/webapp/WEB-INF/web.xml
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-fileshare/pom.xml
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/pom.xml
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-archetype/src/main/resources/archetype-resources/pom.xml
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-archetype/src/main/resources/archetype-resources/pom.xml?rev=1628777&r1=1628776&r2=1628777&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-archetype/src/main/resources/archetype-resources/pom.xml
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-archetype/src/main/resources/archetype-resources/pom.xml
Wed Oct 1 17:07:44 2014
@@ -107,6 +107,13 @@
<artifactId>chemistry-opencmis-server-support</artifactId>
<version>\${opencmis.version}</version>
</dependency>
+ <!-- Uncomment for CORS support
+ <dependency>
+ <groupId>com.thetransactioncompany</groupId>
+ <artifactId>cors-filter</artifactId>
+ <version>2.1.2</version>
+ </dependency>
+ -->
<dependency><!-- for development only -->
<groupId>org.apache.chemistry.opencmis</groupId>
<artifactId>chemistry-opencmis-server-bindings</artifactId>
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/pom.xml
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/pom.xml?rev=1628777&r1=1628776&r2=1628777&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/pom.xml
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/pom.xml
Wed Oct 1 17:07:44 2014
@@ -33,6 +33,13 @@
<artifactId>chemistry-opencmis-server-bindings</artifactId>
<version>${project.version}</version>
</dependency>
+ <!-- Uncomment for CORS support
+ <dependency>
+ <groupId>com.thetransactioncompany</groupId>
+ <artifactId>cors-filter</artifactId>
+ <version>2.1.2</version>
+ </dependency>
+ -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/src/main/webapp/WEB-INF/web.xml
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/src/main/webapp/WEB-INF/web.xml?rev=1628777&r1=1628776&r2=1628777&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/src/main/webapp/WEB-INF/web.xml
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings-war/src/main/webapp/WEB-INF/web.xml
Wed Oct 1 17:07:44 2014
@@ -113,6 +113,59 @@
</filter-mapping>
-->
+ <!--
+ Uncomment the following filter to enable CORS support for the browser
binding.
+ See http://software.dzhuvinov.com/cors-filter.html for details.
+ Put the CORS libraries into the WEB-INF/lib directory or uncomment the
CORS depenedency in the pom.xml.
+ -->
+ <!--
+ <filter>
+ <filter-name>CORS</filter-name>
+ <filter-class>com.thetransactioncompany.cors.CORSFilter</filter-class>
+ <init-param>
+ <param-name>cors.allowGenericHttpRequests</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.allowOrigin</param-name>
+ <param-value>*</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.allowSubdomains</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.supportedMethods</param-name>
+ <param-value>GET, POST</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.supportedHeaders</param-name>
+ <param-value>*</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.exposedHeaders</param-name>
+ <param-value></param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.supportsCredentials</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.maxAge</param-name>
+ <param-value>3600</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cors.tagRequests</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ </filter>
+
+ <filter-mapping>
+ <filter-name>CORS</filter-name>
+ <servlet-name>cmisbrowser</servlet-name>
+ </filter-mapping>
+ -->
+
<servlet>
<servlet-name>cmisws10</servlet-name>
<servlet-class>org.apache.chemistry.opencmis.server.impl.webservices.CmisWebServicesServlet</servlet-class>
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-fileshare/pom.xml
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-fileshare/pom.xml?rev=1628777&r1=1628776&r2=1628777&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-fileshare/pom.xml
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-fileshare/pom.xml
Wed Oct 1 17:07:44 2014
@@ -100,6 +100,13 @@
<artifactId>slf4j-log4j12</artifactId>
<version>${slf4j.version}</version>
</dependency>
+ <!-- Uncomment for CORS support
+ <dependency>
+ <groupId>com.thetransactioncompany</groupId>
+ <artifactId>cors-filter</artifactId>
+ <version>2.1.2</version>
+ </dependency>
+ -->
<dependency><!-- for development only -->
<groupId>${project.groupId}</groupId>
<artifactId>chemistry-opencmis-server-bindings</artifactId>
Modified:
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/pom.xml
URL:
http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/pom.xml?rev=1628777&r1=1628776&r2=1628777&view=diff
==============================================================================
---
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/pom.xml
(original)
+++
chemistry/opencmis/trunk/chemistry-opencmis-server/chemistry-opencmis-server-inmemory/pom.xml
Wed Oct 1 17:07:44 2014
@@ -164,6 +164,13 @@
<scope>provided</scope>
<type>war</type>
</dependency>
+ <!-- Uncomment for CORS support
+ <dependency>
+ <groupId>com.thetransactioncompany</groupId>
+ <artifactId>cors-filter</artifactId>
+ <version>2.1.2</version>
+ </dependency>
+ -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>