Skip to content

Commit c0c8220

Browse files
committed
Remove unused findManaged
1 parent 15ea235 commit c0c8220

1 file changed

Lines changed: 0 additions & 14 deletions

File tree

  • frameworks/Java/quarkus/resteasy-reactive-hibernate-reactive/src/main/java/io/quarkus/benchmark/repository

frameworks/Java/quarkus/resteasy-reactive-hibernate-reactive/src/main/java/io/quarkus/benchmark/repository/WorldRepository.java

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,6 @@ public Uni<List<World>> findStateless(Mutiny.StatelessSession s, int count) {
5656
return loopRoot.replaceWith(worlds);
5757
}
5858

59-
public Uni<List<World>> findManaged(Mutiny.Session s, int count) {
60-
final List<World> worlds = new ArrayList<>(count);
61-
//The rules require individual load: we can't use the Hibernate feature which allows load by multiple IDs
62-
// as one single operation as Hibernate is too smart and will switch to use batched loads.
63-
// But also, we can't use "Uni#join" as we did in the above method as managed entities shouldn't use pipelining -
64-
// so we also have to avoid Mutiny optimising things by establishing an explicit chain:
65-
final LocalRandom localRandom = Randomizer.current();
66-
Uni<Void> loopRoot = Uni.createFrom().voidItem();
67-
for (int i = 0; i < count; i++) {
68-
loopRoot = loopRoot.call(() -> s.find(World.class, localRandom.getNextRandom()).invoke(worlds::add));
69-
}
70-
return loopRoot.replaceWith(worlds);
71-
}
72-
7359
public Uni<World> findStateless() {
7460
return inStatelessSession(session -> session.get(World.class, Randomizer.current().getNextRandom()));
7561
}

0 commit comments

Comments
 (0)