Closed Postremus closed 1 month ago
/cc @gsmet (hibernate-orm), @yrodiere (hibernate-orm)
Agreed, at the very least the method should mention which instances are "competing".
Also from what I can tell, the error could be thrown at build time instead of runtime as the presence of multiple beans is known at build time.
Agreed, at the very least the method should mention which instances are "competing".
True. The method to improve is PersistenceUnitUtil.singleExtensionInstanceForPersistenceUnit
, you can list beans using instance.handles()
and InstanceHandle#getBean()
.
Similar problems exist in io.quarkus.hibernate.search.orm.elasticsearch.runtime.bean.HibernateSearchBeanUtil#singleExtensionBeanReferenceFor(java.lang.Class<T>, java.lang.String, java.lang.String, java.lang.String)
and io.quarkus.hibernate.search.standalone.elasticsearch.runtime.bean.HibernateSearchBeanUtil#singleExtensionBeanReferenceFor(java.lang.Class<T>, java.lang.String, java.lang.String)
.
PRs welcome!
Also from what I can tell, the error could be thrown at build time instead of runtime as the presence of multiple beans is known at build time.
Also true, but would require more work, and would possibly be much more clunky due to the nice CDI APIs not being available. Wouldn't recommend this change to whoever will fix this, unless they're very familiar with Quarkus internals (Arc in particular).
Wouldn't recommend this change to whoever will fix this
Agreed, just something to keep in mind for the future
I am interested to work in this issue as long as would some guidance Thanks in advance
All the guidance you should need is in the messages above; if that's not enough, ask away, but I won't be providing a step-by-step guide as it would take me as much time as doing it myself.
Description
Can this message please be expanded to include the fqdn of the interceptors
Implementation ideas
No response