Skip to content

Commit 67e8859

Browse files
committed
Fix. invoke async with register refs
1 parent ede71b8 commit 67e8859

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ The second thing we have to do is add the spawn dependency to the project.
9494
<dependency>
9595
<groupId>com.github.eigr</groupId>
9696
<artifactId>spawn-java-std-sdk</artifactId>
97-
<version>v1.2.0</version>
97+
<version>v1.2.1</version>
9898
</dependency>
9999
```
100100
We're also going to configure a few things for our application build to work, including compiling the protobuf files.
@@ -128,7 +128,7 @@ See below a full example of the pom.xml file:
128128
<dependency>
129129
<groupId>com.github.eigr</groupId>
130130
<artifactId>spawn-java-std-sdk</artifactId>
131-
<version>v1.2.0</version>
131+
<version>v1.2.1</version>
132132
</dependency>
133133
<dependency>
134134
<groupId>ch.qos.logback</groupId>

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<groupId>io.eigr.spawn</groupId>
55
<artifactId>spawn-java-std-sdk</artifactId>
66
<packaging>jar</packaging>
7-
<version>1.2.0</version>
7+
<version>1.2.1</version>
88
<name>spawn-java-std-sdk</name>
99
<url>http://maven.apache.org</url>
1010

src/main/java/io/eigr/spawn/api/ActorRef.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,10 @@ private <T extends GeneratedMessageV3, S extends GeneratedMessageV3> void invoke
324324

325325
Protocol.InvocationRequest.Builder invocationRequestBuilder = Protocol.InvocationRequest.newBuilder();
326326

327+
if (Objects.nonNull(this.actorId.getParent()) && !this.actorId.getParent().isEmpty()) {
328+
invocationRequestBuilder.setRegisterRef(this.actorId.getParent());
329+
}
330+
327331
Map<String, String> metadata = new HashMap<>();
328332
options.ifPresent(opts -> {
329333
invocationRequestBuilder.setAsync(true);

src/test/java/io/eigr/spawn/test/actors/JoeActor.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
import io.eigr.spawn.api.actors.ActorContext;
55
import io.eigr.spawn.api.actors.annotations.Action;
66
import io.eigr.spawn.api.actors.annotations.stateful.StatefulNamedActor;
7+
import io.eigr.spawn.api.actors.workflows.SideEffect;
78
import io.eigr.spawn.java.test.domain.Actor;
89

910
@StatefulNamedActor(name = "test_joe", stateType = Actor.State.class, channel = "test.channel")

0 commit comments

Comments
 (0)