From 8db7d394badf6b6bbeb7255f23b4bb33efcee47f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vedran=20Pavi=C4=87?= Date: Fri, 2 Sep 2016 20:44:17 +0200 Subject: [PATCH] Fix broken samples (#606) --- build.gradle | 4 ++-- gradle/tomcat.gradle | 11 +++++------ gradle/tomcat7.gradle | 8 +++----- samples/custom-cookie/build.gradle | 4 ---- samples/custom-cookie/src/main/webapp/index.jsp | 3 ++- samples/hazelcast-spring/build.gradle | 4 ---- samples/hazelcast-spring/src/main/webapp/index.jsp | 3 ++- samples/hazelcast/build.gradle | 4 ---- samples/hazelcast/src/main/webapp/index.jsp | 3 ++- .../httpsession-gemfire-clientserver-xml/build.gradle | 4 ---- .../src/main/webapp/WEB-INF/web.xml | 1 - .../src/main/webapp/index.jsp | 3 ++- samples/httpsession-gemfire-clientserver/build.gradle | 4 ---- .../src/main/webapp/index.jsp | 3 ++- samples/httpsession-gemfire-p2p-xml/build.gradle | 4 ---- .../src/main/webapp/WEB-INF/web.xml | 7 +++---- .../src/main/webapp/index.jsp | 3 ++- samples/httpsession-gemfire-p2p/build.gradle | 4 ---- .../httpsession-gemfire-p2p/src/main/webapp/index.jsp | 3 ++- samples/httpsession-jdbc-xml/build.gradle | 6 +----- .../src/main/webapp/WEB-INF/web.xml | 5 ++--- .../httpsession-jdbc-xml/src/main/webapp/index.jsp | 3 ++- samples/httpsession-jdbc/build.gradle | 4 ---- samples/httpsession-jdbc/src/main/webapp/index.jsp | 3 ++- samples/httpsession-xml/build.gradle | 6 +----- .../httpsession-xml/src/main/webapp/WEB-INF/web.xml | 4 ++-- samples/httpsession-xml/src/main/webapp/index.jsp | 3 ++- samples/httpsession/build.gradle | 4 ---- samples/httpsession/src/main/webapp/index.jsp | 4 +++- samples/security/build.gradle | 4 ---- samples/security/src/main/webapp/index.jsp | 3 ++- samples/users/build.gradle | 4 ---- samples/users/src/main/webapp/index.jsp | 9 ++++++--- samples/users/src/main/webapp/link.jsp | 9 ++++++--- 34 files changed, 56 insertions(+), 95 deletions(-) diff --git a/build.gradle b/build.gradle index 0e245f16..cb006b75 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ buildscript { maven { url "https://repo.spring.io/plugins-release" } } dependencies { - classpath("org.gradle.api.plugins:gradle-tomcat-plugin:1.2.3") + classpath("com.bmuschko:gradle-tomcat-plugin:2.2.5") classpath("org.springframework.build.gradle:propdeps-plugin:0.0.7") classpath("io.spring.gradle:spring-io-plugin:0.0.4.RELEASE") classpath('me.champeau.gradle:gradle-javadoc-hotfix-plugin:0.1') @@ -69,4 +69,4 @@ task docsZip(type: Zip, dependsOn: 'configDocsZip') { artifacts { archives docsZip -} \ No newline at end of file +} diff --git a/gradle/tomcat.gradle b/gradle/tomcat.gradle index 087778c4..88f69325 100644 --- a/gradle/tomcat.gradle +++ b/gradle/tomcat.gradle @@ -3,19 +3,18 @@ buildscript { maven { url "https://repo.spring.io/plugins-release" } } dependencies { - classpath("org.gradle.api.plugins:gradle-tomcat-plugin:1.2.3") + classpath("com.bmuschko:gradle-tomcat-plugin:2.2.5") } } apply plugin: 'war' -apply plugin: 'tomcat' +apply plugin: 'com.bmuschko.tomcat' [tomcatRun,tomcatRunWar]*.contextPath = '/' -task integrationTomcatRun(type: org.gradle.api.plugins.tomcat.tasks.TomcatRun) { +task integrationTomcatRun(type: com.bmuschko.gradle.tomcat.tasks.TomcatRun) { onlyIf { !sourceSets.integrationTest.allSource.empty } - buildscriptClasspath = tomcatRun.buildscriptClasspath contextPath = tomcatRun.contextPath daemon = true tomcatClasspath = tomcatRun.tomcatClasspath @@ -36,7 +35,7 @@ task integrationTomcatRun(type: org.gradle.api.plugins.tomcat.tasks.TomcatRun) { } } -task integrationTomcatStop(type: org.gradle.api.plugins.tomcat.tasks.TomcatStop) { +task integrationTomcatStop(type: com.bmuschko.gradle.tomcat.tasks.TomcatStop) { onlyIf { !sourceSets.integrationTest.allSource.empty } doFirst { stopPort = integrationTomcatRun.stopPort @@ -61,4 +60,4 @@ def reservePorts(int count) { def result = sockets*.localPort sockets*.close() result -} \ No newline at end of file +} diff --git a/gradle/tomcat7.gradle b/gradle/tomcat7.gradle index c1a2c615..4f41f943 100644 --- a/gradle/tomcat7.gradle +++ b/gradle/tomcat7.gradle @@ -3,8 +3,6 @@ apply from: TOMCAT_GRADLE dependencies { def tomcatVersion = '7.0.59' tomcat "org.apache.tomcat.embed:tomcat-embed-core:${tomcatVersion}", - "org.apache.tomcat.embed:tomcat-embed-logging-juli:${tomcatVersion}" - tomcat("org.apache.tomcat.embed:tomcat-embed-jasper:${tomcatVersion}") { - exclude group: 'org.eclipse.jdt.core.compiler', module: 'ecj' - } -} \ No newline at end of file + "org.apache.tomcat.embed:tomcat-embed-logging-juli:${tomcatVersion}", + "org.apache.tomcat.embed:tomcat-embed-jasper:${tomcatVersion}" +} diff --git a/samples/custom-cookie/build.gradle b/samples/custom-cookie/build.gradle index 72d63924..b76730d4 100644 --- a/samples/custom-cookie/build.gradle +++ b/samples/custom-cookie/build.gradle @@ -2,10 +2,6 @@ apply from: JAVA_GRADLE apply from: TOMCAT_7_GRADLE apply from: SAMPLE_GRADLE -configurations { - compile.exclude group: 'org.slf4j', module: 'slf4j-api' -} - dependencies { compile project(':spring-session-data-redis'), "org.springframework:spring-web:$springVersion", diff --git a/samples/custom-cookie/src/main/webapp/index.jsp b/samples/custom-cookie/src/main/webapp/index.jsp index 63de3514..8a273e55 100644 --- a/samples/custom-cookie/src/main/webapp/index.jsp +++ b/samples/custom-cookie/src/main/webapp/index.jsp @@ -4,7 +4,8 @@ Session Attributes - "> + + ">