Avoid call to loader.loadBlocking(<empty list>) when there are no entities to load

Description

Some entity loaders (e.g. Infinispan) incur significant cost even when we ask to load 0 entity. Let's work around the problem and avoid calls to the entity loader when there are no entities to load.

Ideal place to do this: org.hibernate.search.engine.search.loading.spi.DefaultProjectionHitMapper#loadBlocking.

Environment

None

Assignee

Yoann Rodière

Reporter

Yoann Rodière

Labels

None

Suitable for new contributors

None

Feedback Requested

None

Components

Fix versions

Priority

Major
Configure