Skip to content

Commit 03c017d

Browse files
authored
Merge pull request #223 from derjust/Issue_218
Issue #218 - Update to Spring-Data 2.1.2.RELEASE and Spring Framework 5.1.2.RELEAS
2 parents 9356e42 + 82285cf commit 03c017d

File tree

8 files changed

+41
-28
lines changed

8 files changed

+41
-28
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Download the JAR though [Maven Central](http://mvnrepository.com/artifact/com.gi
3737
<dependency>
3838
<groupId>com.github.derjust</groupId>
3939
<artifactId>spring-data-dynamodb</artifactId>
40-
<version>5.0.3</version>
40+
<version>5.0.4</version>
4141
</dependency>
4242
```
4343

@@ -165,11 +165,11 @@ API changes will follow SEMVER and loosly the Spring Framework releases.
165165
| ------------------------------- | ------------------------------ | ------------------------------ | ------------------------- |
166166
| 1.0.x | | >= 3.1 && < 4.2 | |
167167
| 4.2.x | >= 1.3.0 && < 1.4.0 | >= 4.2 && < 4.3 | Gosling-SR1 |
168-
| 4.3.x | >= 1.4.0 < 2.0 | >= 4.3 && < 5.0 | Gosling-SR1 |
169-
| 4.4.x | >= 1.4.0 < 2.0 | >= 4.3 && < 5.0 | Hopper-SR2 |
170-
| 4.5.x | >= 1.4.0 < 2.0 | >= 4.3 && < 5.0 | Ingalls |
171-
| 5.0.x | >= 2.0 | >= 5.0 | Kay-SR1 |
172-
168+
| 4.3.x | >= 1.4.0 && < 2.0 | >= 4.3 && < 5.0 | Gosling-SR1 |
169+
| 4.4.x | >= 1.4.0 && < 2.0 | >= 4.3 && < 5.0 | Hopper-SR2 |
170+
| 4.5.x | >= 1.4.0 && < 2.0 | >= 4.3 && < 5.0 | Ingalls |
171+
| 5.0.x | >= 2.0 && < 2.1 | >= 5.0 && < 5.1 | Kay-SR1 |
172+
| 5.1.x | >= 2.1 | >= 5.1 | Lovelace-SR1 |
173173
`spring-data-dynamodb` depends directly on `spring-data` as also `spring-context`, `spring-data` and `spring-tx`.
174174

175175
`compile` and `runtime` dependencies are kept to a minimum to allow easy integartion, for example into

pom.xml

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<modelVersion>4.0.0</modelVersion>
2121
<groupId>com.github.derjust</groupId>
2222
<artifactId>spring-data-dynamodb</artifactId>
23-
<version>5.0.5-SNAPSHOT</version>
23+
<version>5.1.0-SNAPSHOT</version>
2424
<name>Spring Data DynamoDB</name>
2525
<inceptionYear>2018</inceptionYear>
2626

@@ -37,14 +37,13 @@
3737
</licenses>
3838

3939
<properties>
40-
<spring.version>5.0.4.RELEASE</spring.version>
41-
<spring-data.version>2.0.9.RELEASE</spring-data.version>
40+
<spring.version>5.1.2.RELEASE</spring.version>
41+
<spring-data.version>2.1.2.RELEASE</spring-data.version>
4242

4343
<hibernate-validator.version>6.0.9.Final</hibernate-validator.version>
44-
<aws-java-sdk.version>1.11.301</aws-java-sdk.version>
44+
<aws-java-sdk.version>1.11.443</aws-java-sdk.version>
4545
<junit.version>4.12</junit.version>
46-
<mockito.version>2.13.0</mockito.version>
47-
46+
<mockito.version>2.23.0</mockito.version>
4847
<cdi.version>1.2</cdi.version>
4948
<slf4j-test.version>1.2.0</slf4j-test.version>
5049
<sqlite4java.version>1.0.392</sqlite4java.version>
@@ -89,7 +88,6 @@
8988
<artifactId>mockito-core</artifactId>
9089
<version>${mockito.version}</version>
9190
</dependency>
92-
9391
<dependency>
9492
<groupId>com.amazonaws</groupId>
9593
<artifactId>aws-java-sdk-bom</artifactId>
@@ -202,6 +200,9 @@
202200
<groupId>net.revelc.code.formatter</groupId>
203201
<artifactId>formatter-maven-plugin</artifactId>
204202
<version>2.7.2</version>
203+
<configuration>
204+
<lineEnding>LF</lineEnding>
205+
</configuration>
205206
</plugin>
206207
<plugin>
207208
<groupId>org.apache.maven.plugins</groupId>
@@ -260,7 +261,7 @@
260261
</manifest>
261262
<manifestEntries>
262263
<Specification-Title>Spring Data</Specification-Title>
263-
<Specification-Version>2.0</Specification-Version>
264+
<Specification-Version>2.1</Specification-Version>
264265
</manifestEntries>
265266
</archive>
266267
</configuration>
@@ -653,7 +654,7 @@
653654
</os>
654655
</activation>
655656
<properties>
656-
<sqlite4java.artifactId>libsqlite4java-win32-x64</sqlite4java.artifactId>
657+
<sqlite4java.artifactId>sqlite4java-win32-x64</sqlite4java.artifactId>
657658
<sqlite4java.type>dll</sqlite4java.type>
658659
</properties>
659660
</profile>
@@ -794,6 +795,14 @@
794795
<name>Rene Enriquez</name>
795796
<url>enriquezrene</url>
796797
</contributor>
798+
<contributor>
799+
<name>John Dorman</name>
800+
<url>https://github.com/boostchicken</url>
801+
</contributor>
802+
<contributor>
803+
<name>Ryon Day</name>
804+
<url>https://github.com/ryonday</url>
805+
</contributor>
797806
</contributors>
798807

799808

src/changes/changes.xml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,17 @@
2323
<author email="[email protected]">derjust</author>
2424
</properties>
2525
<body>
26-
<release version="5.0.4" date="2018-11-27" description="Maintenance &amp; security release">
26+
<release version="5.1.0" date="" description="Spring Boot 2.1 and Spring Data Lovelace-SR1 support">
27+
<action dev="boostschicken" type="add" date="2018-10-28">
28+
Updated all code to work with Spring Boot 2.1 and Lovelace-SR1
29+
</action>
30+
<action dev="boostschicken" type="add" date="2018-10-28">
31+
Updated Mockito to improve test coverage
32+
<action dev="ryonday" issue="218" type="fix" date="2018-11-09">
33+
Update to Spring-Data 2.1.2.RELEASE and Spring Framework 5.1.2.RELEASE
34+
</action>
35+
</release>
36+
<release version="5.0.4" date="2018-11-27" description="Maintenance &amp; security release">
2737
<action dev="enriquezrene" issue="199" type="fix" date="2018-10-11">
2838
Fix README.md examples
2939
</action>

src/main/java/org/socialsignin/spring/data/dynamodb/repository/support/DynamoDBRepositoryFactory.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@
2525
import org.springframework.data.repository.core.RepositoryInformation;
2626
import org.springframework.data.repository.core.RepositoryMetadata;
2727
import org.springframework.data.repository.core.support.RepositoryFactorySupport;
28-
import org.springframework.data.repository.query.EvaluationContextProvider;
2928
import org.springframework.data.repository.query.QueryLookupStrategy;
3029
import org.springframework.data.repository.query.QueryLookupStrategy.Key;
30+
import org.springframework.data.repository.query.QueryMethodEvaluationContextProvider;
3131
import org.springframework.data.util.Version;
3232

3333
import java.io.Serializable;
@@ -108,7 +108,7 @@ public <T, ID> DynamoDBEntityInformation<T, ID> getEntityInformation(final Class
108108

109109
@Override
110110
protected Optional<QueryLookupStrategy> getQueryLookupStrategy(Key key,
111-
EvaluationContextProvider evaluationContextProvider) {
111+
QueryMethodEvaluationContextProvider evaluationContextProvider) {
112112
return Optional.of(DynamoDBQueryLookupStrategy.create(dynamoDBOperations, key));
113113
}
114114

src/test/java/org/socialsignin/spring/data/dynamodb/config/DynamoDBAuditingBeanDefinitionParserTest.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ public class DynamoDBAuditingBeanDefinitionParserTest {
6464
private ParserContext parserContext;
6565
@Mock
6666
private BeanDefinitionRegistry registry;
67+
6768
@Mock
6869
private BeanDefinitionBuilder builder;
6970

src/test/java/org/socialsignin/spring/data/dynamodb/domain/UnpagedPageImplTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public void testHashCode() {
9494
public void testToString() {
9595
String actual = underTest.toString();
9696

97-
assertTrue(actual, actual.startsWith("Page 1 of 1 containing codegen.java.util.Iterator$MockitoMock"));
97+
assertTrue(actual, actual.startsWith("Page 1 of 1 containing org.mockito.codegen.Iterator$MockitoMock"));
9898
}
9999

100100
@Test

src/test/java/org/socialsignin/spring/data/dynamodb/repository/query/PartTreeDynamoDBQueryUnitTest.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -139,16 +139,8 @@ private <T, ID extends Serializable> void setupCommonMocksForThisRepositoryMetho
139139
Mockito.when(mockEntityMetadata.isRangeKeyAware()).thenReturn(true);
140140
}
141141

142-
// Dirty Harry 9 3/4: In recent versions of spring-data-commons, a lot of
143-
// methods within
144-
// org.springframework.data.repository.query.QueryMethod have become final. Thus
145-
// they can't
146-
// be mocked by Mockito anymore
147-
// https://github.com/mockito/mockito/wiki/FAQ#what-are-the-limitations-of-mockito
148-
// Therefore setting the field explicitly that is used by all the isXXX methods
149142
try {
150-
Field unwrappedReturnTypeField = mockDynamoDBQueryMethod.getClass() // Mockito-generated class
151-
.getSuperclass() // org.socialsignin.spring.data.dynamodb.repository.query.DynamoDBQueryMethod
143+
Field unwrappedReturnTypeField = mockDynamoDBQueryMethod.getClass() // org.socialsignin.spring.data.dynamodb.repository.query.DynamoDBQueryMethod
152144
.getSuperclass() // org.springframework.data.repository.query.QueryMethod
153145
.getDeclaredField("unwrappedReturnType");
154146
unwrappedReturnTypeField.setAccessible(true); // It's final therefore unlocking the field
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
mock-maker-inline

0 commit comments

Comments
 (0)