Skip to content

Commit

Permalink
Formatting TS code and cleanup (#425)
Browse files Browse the repository at this point in the history
  • Loading branch information
gvdongen authored Jun 21, 2024
1 parent d84e0d4 commit 63a3dc0
Show file tree
Hide file tree
Showing 56 changed files with 2,891 additions and 1,648 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import dev.restate.sdk.annotation.Handler;
import dev.restate.sdk.annotation.Service;
import dev.restate.sdk.client.Client;
import develop.MyWorkflowClient;
import java.time.Duration;

@Service
Expand All @@ -19,20 +18,6 @@ public void myRestateHandler(Context ctx) {
.send(Duration.ofMillis(1000))
// focus
.greet("Hi");

// focus
GreetCounterObjectClient.fromContext(ctx, "Mary")
// focus
.send(Duration.ofMillis(1000))
// focus
.greet("Hi");

// focus
MyWorkflowClient.fromContext(ctx, "wf-id-1")
// focus
.send(Duration.ofMillis(1000))
// focus
.run("input");
}

// <end_delayed_call>
Expand All @@ -47,13 +32,6 @@ public void myJavaHandler(Context ctx) {
.send(Duration.ofMillis(1000))
// focus
.greet("Hi");

// focus
GreetCounterObjectClient.fromClient(restate, "Mary")
// focus
.send(Duration.ofMillis(1000))
// focus
.greet("Hi");
}
// <end_delayed_call_java>
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import dev.restate.sdk.annotation.Handler;
import dev.restate.sdk.annotation.Service;
import dev.restate.sdk.client.Client;
import develop.MyWorkflowClient;

@Service
public class OneWayCalls {
Expand All @@ -18,20 +17,6 @@ public void myRestateHandler(Context ctx) {
.send()
// focus
.greet("Hi");

// focus
GreetCounterObjectClient.fromContext(ctx, "Mary")
// focus
.send()
// focus
.greet("Hi");

// focus
MyWorkflowClient.fromContext(ctx, "wf-id-1")
// focus
.send()
// focus
.run("input");
}

// <end_one_way_call>
Expand All @@ -46,18 +31,6 @@ public void myJavaHandler(Context ctx) {
.send()
// focus
.greet("Hi");

// focus
GreetCounterObjectClient.fromClient(restate, "Mary")
// focus
.send()
// focus
.greet("Hi");

// focus
MyWorkflowClient.fromClient(restate, "wf-id-1")
// focus
.submit("input");
}
// <end_one_way_call_java>
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import dev.restate.sdk.annotation.Handler;
import dev.restate.sdk.annotation.Service;
import dev.restate.sdk.client.Client;
import develop.MyWorkflowClient;

@Service
public class RpcCalls {
Expand All @@ -20,24 +19,6 @@ public void myRestateHandler(Context ctx) {
.greet("Hi")
// focus
.await();

// focus
int count =
// focus
GreetCounterObjectClient.fromContext(ctx, "Mary")
// focus
.greet("Hi")
// focus
.await();

// focus
String result =
// focus
MyWorkflowClient.fromContext(ctx, "wf-id-1")
// focus
.run("input")
// focus
.await();
}

// <end_rpc>
Expand All @@ -52,13 +33,6 @@ public void myJavaHandler(Context ctx) {
GreeterServiceClient.fromClient(restate)
// focus
.greet("Hi");

// focus
int count =
// focus
GreetCounterObjectClient.fromClient(restate, "Mary")
// focus
.greet("Hi");
}
// <end_rpc_java>

Expand Down
Loading

0 comments on commit 63a3dc0

Please sign in to comment.