From 6ecff7923df638155ce8c005bfd314fa7fcc5d0e Mon Sep 17 00:00:00 2001 From: Katerina Iatropoulou Date: Wed, 5 Jul 2017 11:01:25 +0000 Subject: [PATCH] Moving webapp from uoa-users-management project to dnet-openaire-users --- pom.xml | 9 +- .../webapp/WEB-INF/applicationContext.xml | 37 ++++++++ .../webapp/WEB-INF/dispatcher-servlet.xml | 6 ++ src/main/webapp/WEB-INF/log4j.properties | 21 +++++ src/main/webapp/WEB-INF/security-context.xml | 34 +++++++ src/main/webapp/WEB-INF/web.xml | 94 +++++++++++++++++-- 6 files changed, 193 insertions(+), 8 deletions(-) create mode 100644 src/main/webapp/WEB-INF/applicationContext.xml create mode 100644 src/main/webapp/WEB-INF/dispatcher-servlet.xml create mode 100644 src/main/webapp/WEB-INF/log4j.properties create mode 100644 src/main/webapp/WEB-INF/security-context.xml diff --git a/pom.xml b/pom.xml index 0600364..f945aee 100644 --- a/pom.xml +++ b/pom.xml @@ -2,7 +2,7 @@ eu.dnetlib - dnet-container-parent + dnet45-container-parent 1.0.0 4.0.0 @@ -14,10 +14,15 @@ scm:svn:https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/dnet-openaire-users/trunk + + eu.dnetlib + uoa-user-management + [2.0.0-SNAPSHOT, 3.0.0) + eu.dnetlib dnet-runtime - [1.0.0] + [1.0.0, 2.0.0) org.apache.cxf diff --git a/src/main/webapp/WEB-INF/applicationContext.xml b/src/main/webapp/WEB-INF/applicationContext.xml new file mode 100644 index 0000000..944e6dc --- /dev/null +++ b/src/main/webapp/WEB-INF/applicationContext.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + classpath*:/eu/**/applicationContext*.properties + classpath*:/eu/dnetlib/applicationContext-defaultProperties.properties + classpath*:/eu/**/springContext-userManagementService.properties + + classpath*:/uoa-override.properties + classpath*:/dnet-override.properties + + + + + + + diff --git a/src/main/webapp/WEB-INF/dispatcher-servlet.xml b/src/main/webapp/WEB-INF/dispatcher-servlet.xml new file mode 100644 index 0000000..4a4405f --- /dev/null +++ b/src/main/webapp/WEB-INF/dispatcher-servlet.xml @@ -0,0 +1,6 @@ + + + diff --git a/src/main/webapp/WEB-INF/log4j.properties b/src/main/webapp/WEB-INF/log4j.properties new file mode 100644 index 0000000..ff817af --- /dev/null +++ b/src/main/webapp/WEB-INF/log4j.properties @@ -0,0 +1,21 @@ +log4j.rootLogger = DEBUG, R + +log4j.logger.eu.dnetlib = DEBUG +log4j.logger.org.mitre.openid = DEBUG +log4j.logger.org.springframework = DEBUG, S + +#log4j.additivity.org.springframework = false + +log4j.appender.R=org.apache.log4j.RollingFileAppender +log4j.appender.R.File=/var/log/dnet/user-management/user-management.log +log4j.appender.R.MaxFileSize=10MB +log4j.appender.R.MaxBackupIndex=10 +log4j.appender.R.layout=org.apache.log4j.PatternLayout +log4j.appender.R.layout.ConversionPattern= %d %p %t [%c] - %m%n + +log4j.appender.S=org.apache.log4j.RollingFileAppender +log4j.appender.S.File=/var/log/dnet/user-management/user-management-spring.log +log4j.appender.S.MaxFileSize=10MB +log4j.appender.S.MaxBackupIndex=10 +log4j.appender.S.layout=org.apache.log4j.PatternLayout +log4j.appender.S.layout.ConversionPattern= %d %p %t [%c] - %m%n \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/security-context.xml b/src/main/webapp/WEB-INF/security-context.xml new file mode 100644 index 0000000..649c702 --- /dev/null +++ b/src/main/webapp/WEB-INF/security-context.xml @@ -0,0 +1,34 @@ + + + + + + + diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml index 9f88c1f..d67f1d1 100644 --- a/src/main/webapp/WEB-INF/web.xml +++ b/src/main/webapp/WEB-INF/web.xml @@ -1,7 +1,89 @@ - - + - Archetype Created Web Application - + + uoa-user-management + + webAppRootKey + uoa-user-management + + + contextConfigLocation + + /WEB-INF/applicationContext.xml + /WEB-INF/security-context.xml + + + + log4jConfigLocation + /WEB-INF/log4j.properties + + + + org.springframework.web.util.Log4jConfigListener + + + org.springframework.web.context.ContextLoaderListener + + + + + User API + com.sun.jersey.spi.spring.container.servlet.SpringServlet + + com.sun.jersey.config.property.packages + eu.dnetlib.openaire.user.api.services + + + + User API + /api/* + + + + + CorsFilter + org.apache.catalina.filters.CorsFilter + + cors.allowed.origins + * + + + cors.allowed.methods + GET, POST + + + cors.exposed.headers + Access-Control-Allow-Origin,Access-Control-Allow-Credentials,Access-Control-Allow-Methods + + + cors.support.credentials + true + + + + CorsFilter + /* + + + + + springSecurityFilterChain + org.springframework.web.filter.DelegatingFilterProxy + + + + springSecurityFilterChain + /* + + + \ No newline at end of file