2 Commits

Author SHA1 Message Date
1965d93f25 Dhfs-app: handle empty op push correctly 2025-04-24 22:38:01 +02:00
f6685f45f9 Dhfs-app: increase sync timeout 2025-04-24 22:34:04 +02:00
2 changed files with 7 additions and 3 deletions

View File

@@ -66,7 +66,7 @@ public class DhfsImage implements Future<String> {
.run("apt update && apt install -y libfuse2 curl gcc")
.copy("/app", "/app")
.copy("/libs", "/libs")
.cmd("java", "-ea", "-Xmx256M", "-XX:TieredStopAtLevel=1","-XX:+UseParallelGC",
.cmd("java", "-ea", "-Xmx256M", "-XX:TieredStopAtLevel=1", "-XX:+UseParallelGC",
"--add-exports", "java.base/sun.nio.ch=ALL-UNNAMED",
"--add-exports", "java.base/jdk.internal.access=ALL-UNNAMED",
"--add-opens=java.base/java.nio=ALL-UNNAMED",
@@ -75,7 +75,7 @@ public class DhfsImage implements Future<String> {
"-Ddhfs.objects.deletion.delay=0",
"-Ddhfs.objects.deletion.can-delete-retry-delay=1000",
"-Ddhfs.objects.ref_verification=true",
"-Ddhfs.objects.sync.timeout=10",
"-Ddhfs.objects.sync.timeout=30",
"-Ddhfs.objects.sync.ping.timeout=5",
"-Ddhfs.objects.reconnect_interval=1s",
"-Dquarkus.log.category.\"com.usatiuk\".level=TRACE",

View File

@@ -1,6 +1,5 @@
package com.usatiuk.dhfs.repository;
import com.usatiuk.dhfs.ProtoSerializer;
import com.usatiuk.dhfs.*;
import com.usatiuk.dhfs.persistence.JObjectKeyP;
import com.usatiuk.dhfs.repository.invalidation.Op;
@@ -105,6 +104,11 @@ public class RemoteObjectServiceServerImpl {
}
public Uni<OpPushReply> opPush(PeerId from, OpPushRequest request) {
if (request.getMsgCount() == 0) {
Log.infov("<-- opPush: empty from {0}", from);
return Uni.createFrom().item(OpPushReply.getDefaultInstance());
}
var handles = new ArrayList<TransactionHandle>();
try {
var ops = request.getMsgList().stream().map(opProtoSerializer::deserialize).toList();