Skip to content

Commit

Permalink
feature: run the Kessel migration in a virtual thread (#3194)
Browse files Browse the repository at this point in the history
We want to avoid blocking Quarkus' event thread, and since the migration
uses blocking calls, we want to make sure it does not get killed by
Vert.x.

RHCLOUD-35454
  • Loading branch information
MikelAlejoBR authored Dec 11, 2024
1 parent 1b73cd5 commit 45cc692
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import com.redhat.cloud.notifications.models.Endpoint;
import io.grpc.stub.StreamObserver;
import io.quarkus.logging.Log;
import io.smallrye.common.annotation.RunOnVirtualThread;
import io.smallrye.mutiny.Multi;
import io.smallrye.mutiny.Uni;
import jakarta.annotation.security.RolesAllowed;
Expand Down Expand Up @@ -57,6 +58,7 @@ public class KesselAssetsMigrationService {

@Path("/kessel/migrate-assets")
@POST
@RunOnVirtualThread
public void migrateAssets() {
Log.info("Kessel assets' migration begins");

Expand Down

0 comments on commit 45cc692

Please sign in to comment.