Remove unnecessary code from samples

Remove code that is not necessary to demonstrate Spring Session functionality and is not compatible with the Java 17 / Jakarta EE 9 upgrades.

Issue gh-1949
This commit is contained in:
Eleftheria Stein
2021-11-12 10:35:35 +01:00
parent fc5f875036
commit cc1fd826ac
18 changed files with 1 additions and 75 deletions

View File

@@ -18,6 +18,5 @@ dependencyManagement {
dependency 'org.webjars:knockout:3.5.1'
dependency 'org.webjars:sockjs-client:1.5.1'
dependency 'org.webjars:stomp-websocket:2.3.4'
dependency 'org.webjars:webjars-taglib:0.3'
}
}

View File

@@ -7,8 +7,6 @@ dependencies {
implementation project(':spring-session-data-redis')
implementation "org.springframework:spring-web"
implementation "io.lettuce:lettuce-core"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"
implementation "org.slf4j:log4j-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -9,8 +9,6 @@ dependencies {
implementation "org.springframework:spring-web"
implementation "org.springframework.security:spring-security-config"
implementation "org.springframework.security:spring-security-web"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "com.hazelcast:hazelcast"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Secured Content</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -6,8 +6,6 @@ plugins {
dependencies {
implementation project(':spring-session-jdbc')
implementation "org.springframework:spring-web"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "com.h2database:h2"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"

View File

@@ -1,32 +0,0 @@
/*
* Copyright 2014-2019 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package sample;
import javax.servlet.ServletContext;
import org.h2.server.web.WebServlet;
import org.springframework.web.WebApplicationInitializer;
public class H2ConsoleInitializer implements WebApplicationInitializer {
@Override
public void onStartup(ServletContext servletContext) {
servletContext.addServlet("h2Console", new WebServlet()).addMapping("/h2-console/*");
}
}

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -7,8 +7,6 @@ dependencies {
implementation project(':spring-session-data-redis')
implementation "org.springframework:spring-web"
implementation "io.lettuce:lettuce-core"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"
implementation "org.slf4j:log4j-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -9,8 +9,6 @@ dependencies {
implementation "org.springframework.security:spring-security-config"
implementation "org.springframework.security:spring-security-web"
implementation "io.lettuce:lettuce-core"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"
implementation "org.slf4j:log4j-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Secured Content</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -5,17 +5,14 @@ plugins {
dependencies {
implementation project(':spring-session-core')
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "com.hazelcast:hazelcast"
implementation "jakarta.servlet.jsp.jstl:jakarta.servlet.jsp.jstl-api"
implementation "org.apache.taglibs:taglibs-standard-jstlel"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"
implementation "org.slf4j:log4j-over-slf4j"
implementation "ch.qos.logback:logback-classic"
providedCompile "jakarta.servlet:jakarta.servlet-api"
providedCompile "org.glassfish.web:jakarta.servlet.jsp.jstl"
testImplementation "org.assertj:assertj-core"
testImplementation "org.junit.jupiter:junit-jupiter-api"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -6,8 +6,6 @@ plugins {
dependencies {
implementation project(':spring-session-jdbc')
implementation "org.springframework:spring-web"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "com.h2database:h2"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;

View File

@@ -7,8 +7,6 @@ dependencies {
implementation project(':spring-session-data-redis')
implementation "org.springframework:spring-web"
implementation "io.lettuce:lettuce-core"
implementation "org.webjars:bootstrap"
implementation "org.webjars:webjars-taglib"
implementation "org.slf4j:slf4j-api"
implementation "org.slf4j:jcl-over-slf4j"
implementation "org.slf4j:log4j-over-slf4j"

View File

@@ -1,11 +1,8 @@
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="wj" uri="http://www.webjars.org/tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Session Attributes</title>
<wj:locate path="bootstrap.min.css" relativeTo="META-INF/resources" var="bootstrapCssLocation"/>
<link rel="stylesheet" href="<c:url value="${bootstrapCssLocation}"/>">
<style type="text/css">
body {
padding: 1em;