Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New quickstart #214

Merged
merged 23 commits into from
Nov 22, 2024
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix Java templates issues
gvdongen committed Nov 21, 2024

Verified

This commit was signed with the committer’s verified signature.
freya022 freya02
commit 283ec6f5a6136f5c09418cfc71dd0bf9e95f7385
6 changes: 6 additions & 0 deletions templates/java-gradle/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -35,4 +35,10 @@ application {

tasks.named<Test>("test") {
useJUnitPlatform()
}

java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
}
Original file line number Diff line number Diff line change
@@ -29,6 +29,6 @@ void testGreet(@RestateClient Client ingressClient) {
var client = GreeterClient.fromClient(ingressClient);

String response = client.greet("Francesco");
assertEquals(response, "Hello Francesco");
assertEquals(response, "You said hi to Francesco!");
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package my.example;
package com.example.restatestarter;

// You can remove this file.
// It's only purpose is providing stubs for the template.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
spring.application.name=restate-starter
greetingPrefix=Hello Mr.
greetingPrefix=hi

# Restate SDK port (to expose Greeter)
restate.sdk.http.port=9080
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@

@SpringBootTest(
classes = Greeter.class,
properties = {"greetingPrefix=Ciao "})
properties = {"greetingPrefix=ciao"})
@RestateTest
public class GreeterTest {

@@ -30,6 +30,6 @@ public class GreeterTest {
void greet(@RestateClient Client ingressClient) {
var client = GreeterClient.fromClient(ingressClient);

assertThat(client.greet("Francesco")).isEqualTo("Ciao Francesco");
assertThat(client.greet("Francesco")).isEqualTo("You said ciao to Francesco!");
}
}
Original file line number Diff line number Diff line change
@@ -29,6 +29,6 @@ void testGreet(@RestateClient Client ingressClient) {
var client = GreeterClient.fromClient(ingressClient);

String response = client.greet("Francesco");
assertEquals(response, "Hello Francesco");
assertEquals(response, "You said hi to Francesco!");
}
}