Skip to content

Commit 741226e

Browse files
author
Mariusz Kopylec
committed
Dependencies update
1 parent 72a3782 commit 741226e

File tree

9 files changed

+64
-71
lines changed

9 files changed

+64
-71
lines changed

build.gradle

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,21 @@ buildscript {
33
mavenCentral()
44
}
55
dependencies {
6-
classpath group: 'io.codearte.gradle.nexus', name: 'gradle-nexus-staging-plugin', version: '0.5.3'
6+
classpath group: 'io.codearte.gradle.nexus', name: 'gradle-nexus-staging-plugin', version: '0.11.0'
77
}
88
}
99

1010
plugins {
1111
id 'groovy'
1212
id 'maven-publish'
1313
id 'jacoco'
14-
id 'nebula.optional-base' version '3.1.0'
15-
id 'com.github.kt3k.coveralls' version '2.6.3'
14+
id 'nebula.optional-base' version '3.2.0'
15+
id 'com.github.kt3k.coveralls' version '2.8.1'
1616
id 'maven'
1717
id 'signing'
18-
id 'pl.allegro.tech.build.axion-release' version '1.5.0'
18+
id 'pl.allegro.tech.build.axion-release' version '1.7.2'
19+
id 'io.codearte.nexus-staging' version '0.11.0'
1920
}
20-
apply plugin: 'io.codearte.nexus-staging'
2121

2222
scmVersion {
2323
tag {
@@ -36,18 +36,18 @@ repositories {
3636
mavenCentral()
3737
}
3838

39-
ext.springBootVersion = '1.5.1.RELEASE'
39+
ext.springBootVersion = '1.5.6.RELEASE'
4040

4141
dependencies {
4242

4343
compile group: 'org.springframework.boot', name: 'spring-boot-starter', version: springBootVersion
4444
compile("org.springframework.boot:spring-boot-starter-data-couchbase:$springBootVersion") {
4545
exclude group: 'org.springframework', module: 'spring-web'
4646
}
47-
compile group: 'org.springframework.session', name: 'spring-session', version: '1.3.0.RELEASE'
48-
compile group: 'org.springframework.retry', name: 'spring-retry', version: '1.1.5.RELEASE'
47+
compile group: 'org.springframework.session', name: 'spring-session', version: '1.3.1.RELEASE'
48+
compile group: 'org.springframework.retry', name: 'spring-retry', version: '1.2.1.RELEASE'
4949
compile group: 'javax.servlet', name: 'javax.servlet-api', version: '3.1.0'
50-
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.8.6'
50+
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.8.9'
5151
compile group: 'org.apache.commons', name: 'commons-lang3', version: '3.5'
5252
compile group: 'org.apache.commons', name: 'commons-collections4', version: '4.1'
5353

@@ -56,7 +56,7 @@ dependencies {
5656
testCompile group: 'org.springframework.boot', name: 'spring-boot-starter-test', version: springBootVersion
5757
testCompile group: 'org.springframework.boot', name: 'spring-boot-starter-web', version: springBootVersion
5858
testCompile group: 'org.springframework.boot', name: 'spring-boot-starter-undertow', version: springBootVersion
59-
testCompile group: 'org.spockframework', name: 'spock-spring', version: '1.1-groovy-2.4-rc-3'
59+
testCompile group: 'org.spockframework', name: 'spock-spring', version: '1.1-groovy-2.4'
6060
}
6161

6262
configurations {
@@ -141,7 +141,3 @@ jacocoTestReport {
141141
html.enabled = true
142142
}
143143
}
144-
145-
nexusStaging {
146-
numberOfRetries = 20
147-
}

gradle/wrapper/gradle-wrapper.jar

1.89 KB
Binary file not shown.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
#Fri Sep 09 10:34:20 CEST 2016
1+
#Mon Sep 04 14:49:51 CEST 2017
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-3.4-bin.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-bin.zip

gradlew

Lines changed: 41 additions & 33 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

gradlew.bat

Lines changed: 4 additions & 10 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

release

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ if [ -z "$VERSION" ]; then
88
echo "Set release version using -v option"
99
exit 1
1010
else
11-
./gradlew clean test release -Prelease.forceVersion=$VERSION && ./gradlew uploadArchives -PsignArtifacts && ./gradlew closeAndPromoteRepository
11+
./gradlew clean test release -Prelease.forceVersion=$VERSION && ./gradlew uploadArchives -PsignArtifacts && ./gradlew closeAndReleaseRepository
1212
fi

src/main/java/com/github/mkopylec/sessioncouchbase/configuration/InMemoryConfiguration.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,15 @@
22

33
import com.github.mkopylec.sessioncouchbase.data.InMemoryDao;
44
import com.github.mkopylec.sessioncouchbase.data.SessionDao;
5-
import org.springframework.beans.factory.annotation.Autowired;
65
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
76
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
8-
import org.springframework.boot.context.properties.EnableConfigurationProperties;
97
import org.springframework.context.annotation.Bean;
108
import org.springframework.context.annotation.Configuration;
119

1210
@Configuration
13-
@EnableConfigurationProperties(SessionCouchbaseProperties.class)
1411
@ConditionalOnProperty(name = "session-couchbase.in-memory.enabled")
1512
public class InMemoryConfiguration {
1613

17-
@Autowired
18-
protected SessionCouchbaseProperties sessionCouchbase;
19-
2014
@Bean
2115
@ConditionalOnMissingBean
2216
public SessionDao sessionDao() {

src/main/java/com/github/mkopylec/sessioncouchbase/configuration/SessionCouchbaseAutoConfiguration.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
import com.github.mkopylec.sessioncouchbase.data.SessionDao;
88
import org.springframework.beans.factory.annotation.Autowired;
99
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
10-
import org.springframework.boot.autoconfigure.couchbase.CouchbaseProperties;
1110
import org.springframework.boot.context.properties.EnableConfigurationProperties;
1211
import org.springframework.context.ApplicationEventPublisher;
1312
import org.springframework.context.annotation.Bean;
@@ -19,7 +18,7 @@
1918

2019
@Configuration
2120
@EnableSpringHttpSession
22-
@EnableConfigurationProperties(CouchbaseProperties.class)
21+
@EnableConfigurationProperties(SessionCouchbaseProperties.class)
2322
public class SessionCouchbaseAutoConfiguration {
2423

2524
@Autowired

src/main/java/com/github/mkopylec/sessioncouchbase/data/InMemoryDao.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ public boolean exists(String documentId) {
9898

9999
@Override
100100
public void delete(String id) {
101+
expirationTimes.remove(id);
101102
sessions.remove(id);
102103
principalSessions.remove(id);
103104
}
@@ -113,12 +114,13 @@ public void deleteAll() {
113114
public void afterPropertiesSet() throws Exception {
114115
expirationScheduler.initialize();
115116
expirationScheduler.scheduleAtFixedRate(() -> {
116-
for(Iterator<Entry<String, Long>> iter = expirationTimes.entrySet().iterator(); iter.hasNext(); ) {
117-
Entry<String, Long> entry = iter.next();
117+
Iterator<Entry<String, Long>> iterator = expirationTimes.entrySet().iterator();
118+
while (iterator.hasNext()) {
119+
Entry<String, Long> entry = iterator.next();
118120
if (entry.getValue() < currentTimeMillis()) {
119121
sessions.remove(entry.getKey());
120122
principalSessions.remove(entry.getKey());
121-
iter.remove();
123+
iterator.remove();
122124
}
123125
}
124126
}, 1000);

0 commit comments

Comments
 (0)