Skip to content

Commit 3d3d8af

Browse files
committed
Upgrade to Spring Boot 2.7 M3.
Switch from UUID to String as identifier type in LineItems as Hibernate doesn't like that on recent H2 versions.
1 parent 466aa5d commit 3d3d8af

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

server/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/ma
1212
<parent>
1313
<groupId>org.springframework.boot</groupId>
1414
<artifactId>spring-boot-starter-parent</artifactId>
15-
<version>2.7.0-M1</version>
15+
<version>2.7.0-M3</version>
1616
</parent>
1717

1818
<properties>

server/src/main/java/org/springsource/restbucks/order/LineItem.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public class LineItem implements Entity<Order, LineItemIdentifier> {
4949

5050
public LineItem(Drink drink) {
5151

52-
this.id = LineItemIdentifier.of(UUID.randomUUID());
52+
this.id = LineItemIdentifier.of(UUID.randomUUID().toString());
5353
this.name = drink.getName();
5454
this.quantity = 1;
5555
this.milk = drink.getMilk();
@@ -69,6 +69,6 @@ LineItem increaseAmount() {
6969

7070
@Value(staticConstructor = "of")
7171
public static class LineItemIdentifier implements Identifier {
72-
UUID id;
72+
String id;
7373
}
7474
}

0 commit comments

Comments
 (0)