Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9f7a969a6e | ||
|
|
2ce570cbdc | ||
|
|
840907993b | ||
|
|
4db41c1caf | ||
|
|
f4840e98a2 | ||
|
|
8c99c9f904 | ||
|
|
f70f1f20f9 | ||
|
|
ac1a77e5fe | ||
|
|
214a556dd4 | ||
|
|
cace484fbe | ||
|
|
24c198fe98 | ||
|
|
2c1b79375d | ||
|
|
fba9313c6b | ||
|
|
c2288615bf | ||
|
|
ad52fc0297 |
101
RELEASE.adoc
Normal file
101
RELEASE.adoc
Normal file
@@ -0,0 +1,101 @@
|
||||
== 1. Update Dependencies
|
||||
|
||||
Dependencies are declared in `gradle/dependency-management.gradle`.
|
||||
Update Spring Framework, Spring Security and Spring Data at a minimum.
|
||||
|
||||
Run all the checks:
|
||||
|
||||
[source,bash]
|
||||
----
|
||||
$ ./gradlew check
|
||||
----
|
||||
|
||||
Create separate issues for each dependency update, aside from test dependencies which can be combined into a single commit.
|
||||
|
||||
== 2. Check All Issues are Closed
|
||||
|
||||
You can manually check at https://github.com/spring-projects/spring-session/milestones
|
||||
|
||||
== 3. Update Release Version
|
||||
|
||||
Update the version number in `gradle.properties` for the release, for example `2.6.0-M1`, `2.6.0-RC1`, `2.6.3`
|
||||
|
||||
== 4. Update Antora Version
|
||||
|
||||
You will need to update the antora.yml version.
|
||||
|
||||
== 5. Build Locally
|
||||
|
||||
Run the build using
|
||||
|
||||
[source,bash]
|
||||
----
|
||||
$ ./gradlew check
|
||||
----
|
||||
|
||||
== 6. Push the Release Commit
|
||||
|
||||
Push the commit and GitHub actions will build and deploy the artifacts.
|
||||
Wait for the artifact to appear in https://repo1.maven.org/maven2/org/springframework/session/spring-session-core/
|
||||
|
||||
== 7. Tag the release
|
||||
|
||||
Tag the release and then push the tag
|
||||
|
||||
....
|
||||
git tag 2.6.3
|
||||
git push origin 2.6.3
|
||||
....
|
||||
|
||||
== 8. Update to Next Development Version
|
||||
|
||||
Update `gradle.properties` version to next `+SNAPSHOT+` version, update antora.yml and then push
|
||||
|
||||
== 9. Update version on project pages
|
||||
|
||||
Update the versions on https://spring.io/projects for Spring Session Core, Spring Session Data Redis, Spring Session JDBC, Spring Session Hazelcast, and Spring Session MongoDB.
|
||||
|
||||
== 10. Update Release Notes on GitHub
|
||||
|
||||
Download
|
||||
https://github.com/spring-io/github-changelog-generator/releases/latest[the
|
||||
GitHub release notes generator]
|
||||
|
||||
* Generate the release notes
|
||||
|
||||
....
|
||||
java -jar github-changelog-generator.jar \
|
||||
--changelog.repository=spring-projects/spring-session \
|
||||
$MILESTONE release-notes
|
||||
....
|
||||
|
||||
Note 1: `+$MILESTONE+` is something like `+2.6.1+` or `+2.6.0-M1+`. +
|
||||
Note 2: This will create a file on your filesystem
|
||||
called `+release-notes+`.
|
||||
|
||||
* Copy the release notes to your clipboard (your mileage may vary with
|
||||
the following command)
|
||||
|
||||
....
|
||||
cat release-notes | xclip -selection clipboard
|
||||
....
|
||||
|
||||
* Create the
|
||||
https://github.com/spring-projects/spring-session/releases[release on
|
||||
GitHub], associate it with the tag, and paste the generated notes.
|
||||
|
||||
== 11. Close / Create Milestone
|
||||
|
||||
* In
|
||||
https://github.com/spring-projects/spring-session/milestones[GitHub
|
||||
Milestones], create a new milestone for the next release version
|
||||
* Move any open issues from the existing milestone you just released to
|
||||
the new milestone.
|
||||
* Close the milestone for the release.
|
||||
|
||||
== 12. Announce the release
|
||||
|
||||
* Announce via Slack on https://pivotal.slack.com/messages/spring-session[#spring-session], and tag any downstream Spring Session projects (e.g Spring Session for Apache Geode).
|
||||
|
||||
Note: Do not post on #spring-release or create a blog post. Those steps happen after the Spring Session BOM is released.
|
||||
|
||||
@@ -4,7 +4,7 @@ buildscript {
|
||||
snapshotBuild = version.endsWith('SNAPSHOT')
|
||||
milestoneBuild = !(releaseBuild || snapshotBuild)
|
||||
|
||||
springBootVersion = '2.5.6'
|
||||
springBootVersion = '2.6.6'
|
||||
}
|
||||
|
||||
repositories {
|
||||
|
||||
@@ -66,7 +66,7 @@ dependencies {
|
||||
implementation 'io.spring.nohttp:nohttp-gradle:0.0.9'
|
||||
implementation 'net.sourceforge.htmlunit:htmlunit:2.55.0'
|
||||
implementation 'org.hidetake:gradle-ssh-plugin:2.10.1'
|
||||
implementation 'org.jfrog.buildinfo:build-info-extractor-gradle:4.24.20'
|
||||
implementation 'org.jfrog.buildinfo:build-info-extractor-gradle:4.29.0'
|
||||
implementation 'org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.7.1'
|
||||
|
||||
testImplementation platform('org.junit:junit-bom:5.8.1')
|
||||
|
||||
@@ -18,6 +18,7 @@ package io.spring.gradle.convention
|
||||
|
||||
import org.gradle.api.Plugin
|
||||
import org.gradle.api.Project
|
||||
import org.gradle.api.publish.maven.plugins.MavenPublishPlugin
|
||||
|
||||
class ArtifactoryPlugin implements Plugin<Project> {
|
||||
|
||||
@@ -37,8 +38,14 @@ class ArtifactoryPlugin implements Plugin<Project> {
|
||||
password = artifactoryPassword
|
||||
}
|
||||
}
|
||||
defaults {
|
||||
publications('mavenJava')
|
||||
}
|
||||
}
|
||||
project.plugins.withType(MavenPublishPlugin) {
|
||||
project.artifactory {
|
||||
publish {
|
||||
defaults {
|
||||
publications('mavenJava')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -32,6 +32,7 @@ class RootProjectPlugin implements Plugin<Project> {
|
||||
pluginManager.apply(SchemaPlugin)
|
||||
pluginManager.apply(NoHttpPlugin)
|
||||
pluginManager.apply(SpringNexusPublishPlugin)
|
||||
pluginManager.apply(ArtifactoryPlugin)
|
||||
pluginManager.apply("org.sonarqube")
|
||||
|
||||
project.repositories.mavenCentral()
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
org.gradle.jvmargs=-Xmx2g -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
|
||||
org.gradle.parallel=true
|
||||
version=2.6.2
|
||||
version=2.6.4-SNAPSHOT
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
dependencyManagement {
|
||||
imports {
|
||||
mavenBom 'io.projectreactor:reactor-bom:2020.0.16'
|
||||
mavenBom 'com.fasterxml.jackson:jackson-bom:2.13.1'
|
||||
mavenBom 'io.projectreactor:reactor-bom:2020.0.18'
|
||||
mavenBom 'com.fasterxml.jackson:jackson-bom:2.13.2.20220328'
|
||||
mavenBom 'org.junit:junit-bom:5.8.2'
|
||||
mavenBom 'org.springframework:spring-framework-bom:5.3.16'
|
||||
mavenBom 'org.springframework.data:spring-data-bom:2021.1.2'
|
||||
mavenBom 'org.springframework.security:spring-security-bom:5.6.2'
|
||||
mavenBom 'org.testcontainers:testcontainers-bom:1.16.2'
|
||||
mavenBom 'org.springframework:spring-framework-bom:5.3.19'
|
||||
mavenBom 'org.springframework.data:spring-data-bom:2021.1.4'
|
||||
mavenBom 'org.springframework.security:spring-security-bom:5.6.3'
|
||||
mavenBom 'org.testcontainers:testcontainers-bom:1.16.3'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@@ -15,8 +15,8 @@ dependencyManagement {
|
||||
entry 'hazelcast-client'
|
||||
}
|
||||
|
||||
dependency 'org.aspectj:aspectjweaver:1.9.8'
|
||||
dependency 'ch.qos.logback:logback-core:1.2.10'
|
||||
dependency 'org.aspectj:aspectjweaver:1.9.9.1'
|
||||
dependency 'ch.qos.logback:logback-core:1.2.11'
|
||||
dependency 'com.google.code.findbugs:jsr305:3.0.2'
|
||||
dependency 'com.h2database:h2:1.4.200'
|
||||
dependency 'com.ibm.db2:jcc:11.5.7.0'
|
||||
@@ -24,7 +24,7 @@ dependencyManagement {
|
||||
dependency 'com.oracle.database.jdbc:ojdbc8:21.3.0.0'
|
||||
dependency 'com.zaxxer:HikariCP:3.4.5'
|
||||
dependency 'edu.umd.cs.mtc:multithreadedtc:1.01'
|
||||
dependency 'io.lettuce:lettuce-core:6.1.6.RELEASE'
|
||||
dependency 'io.lettuce:lettuce-core:6.1.8.RELEASE'
|
||||
dependency 'jakarta.annotation:jakarta.annotation-api:1.3.5'
|
||||
dependency 'jakarta.servlet:jakarta.servlet-api:4.0.4'
|
||||
dependency 'mysql:mysql-connector-java:8.0.28'
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
name: ROOT
|
||||
version: '2.6.2'
|
||||
version: '2.6.4'
|
||||
prerelease: '-SNAPSHOT'
|
||||
|
||||
@@ -46,7 +46,7 @@ final class DatabaseContainers {
|
||||
}
|
||||
|
||||
static MySQLContainer<?> mySql() {
|
||||
return new MySQLContainer<>("mysql:8.0.27");
|
||||
return new MySQLContainer<>("mysql:8.0.28");
|
||||
}
|
||||
|
||||
static OracleContainer oracle() {
|
||||
|
||||
@@ -728,7 +728,8 @@ public class JdbcIndexedSessionRepository
|
||||
T attributeValue = supplier.get();
|
||||
if (attributeValue != null
|
||||
&& JdbcIndexedSessionRepository.this.saveMode.equals(SaveMode.ON_GET_ATTRIBUTE)) {
|
||||
this.delta.put(attributeName, DeltaValue.UPDATED);
|
||||
this.delta.merge(attributeName, DeltaValue.UPDATED, (oldDeltaValue,
|
||||
deltaValue) -> (oldDeltaValue == DeltaValue.ADDED) ? oldDeltaValue : deltaValue);
|
||||
}
|
||||
return attributeValue;
|
||||
}
|
||||
|
||||
@@ -655,6 +655,20 @@ class JdbcIndexedSessionRepositoryTests {
|
||||
verifyNoMoreInteractions(this.jdbcOperations);
|
||||
}
|
||||
|
||||
@Test
|
||||
void saveWithSaveModeOnGetAttributeAndNewAttributeSetAndGet() {
|
||||
this.repository.setSaveMode(SaveMode.ON_GET_ATTRIBUTE);
|
||||
MapSession delegate = new MapSession();
|
||||
delegate.setAttribute("attribute1", (Supplier<String>) () -> "value1");
|
||||
JdbcSession session = this.repository.new JdbcSession(delegate, UUID.randomUUID().toString(), false);
|
||||
session.setAttribute("attribute2", "value2");
|
||||
session.getAttribute("attribute2");
|
||||
this.repository.save(session);
|
||||
verify(this.jdbcOperations, times(1)).update(startsWith("INSERT INTO SPRING_SESSION_ATTRIBUTES ("),
|
||||
isA(PreparedStatementSetter.class));
|
||||
verifyNoMoreInteractions(this.jdbcOperations);
|
||||
}
|
||||
|
||||
@Test
|
||||
void saveWithSaveModeAlways() {
|
||||
this.repository.setSaveMode(SaveMode.ALWAYS);
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
dependencyManagement {
|
||||
imports {
|
||||
mavenBom 'com.fasterxml.jackson:jackson-bom:2.13.1'
|
||||
mavenBom 'com.fasterxml.jackson:jackson-bom:2.13.2.20220328'
|
||||
}
|
||||
|
||||
dependencies {
|
||||
dependency 'ch.qos.logback:logback-classic:1.2.10'
|
||||
dependency 'ch.qos.logback:logback-classic:1.2.11'
|
||||
dependency 'com.maxmind.geoip2:geoip2:2.15.0'
|
||||
dependency 'javax.servlet.jsp.jstl:javax.servlet.jsp.jstl-api:1.2.2'
|
||||
dependency 'javax.servlet.jsp:javax.servlet.jsp-api:2.3.3'
|
||||
|
||||
@@ -2,3 +2,7 @@ logging:
|
||||
level:
|
||||
org.springframework.data.mongodb: DEBUG
|
||||
org.springframework.session: DEBUG
|
||||
spring:
|
||||
mongodb:
|
||||
embedded:
|
||||
version: 3.0.0
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
spring.thymeleaf.cache=false
|
||||
spring.template.cache=false
|
||||
spring.data.mongodb.port=0
|
||||
spring.mongodb.embedded.version=3.0.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<html xmlns:layout="https://github.com/ultraq/thymeleaf-layout-dialect" layout:decorator="layout">
|
||||
<html xmlns:layout="https://github.com/ultraq/thymeleaf-layout-dialect" layout:decorate="layout">
|
||||
<head>
|
||||
<title>Secured Content</title>
|
||||
</head>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
xmlns:th="https://www.thymeleaf.org"
|
||||
xmlns:layout="https://github.com/ultraq/thymeleaf-layout-dialect">
|
||||
<head>
|
||||
<title layout:title-pattern="$DECORATOR_TITLE - $CONTENT_TITLE">Spring Session Sample</title>
|
||||
<title layout:title-pattern="$LAYOUT_TITLE - $CONTENT_TITLE">Spring Session Sample</title>
|
||||
<link rel="icon" type="image/x-icon" th:href="@{/resources/img/favicon.ico}" href="../static/img/favicon.ico"/>
|
||||
<link th:href="@{/webjars/bootstrap/css/bootstrap.min.css}" href="/webjars/bootstrap/css/bootstrap.min.css" rel="stylesheet"></link>
|
||||
<style type="text/css">
|
||||
|
||||
Reference in New Issue
Block a user