Thanks, Kabir.

I figure this is a reason for using source transformation for artifacts, instead of binary transformation, since presumably the source transformation approach would result in a consistent-with-the-class-files jandex.idx being built.

I don't know how feasible it would be to get Eclipse Transformer / Jandex to transform jandex.idx files but I doubt it's worth the effort.

The deployment transformation thing WildFly Preview does would presumably have problems as well if deployments package a jandex index. I'm not sure if that 'feature' would survive std WildFly's move to EE 10 though. If it did I'm pretty sure it would become something we'd only apply if the user opted into it for a deployment (e.g. with a new attribute on the deployment resource.)

On Thu, Dec 2, 2021 at 6:57 AM Kabir Khan <kkhan@redhat.com> wrote:
My latest attempt to upgrade SmallRye Reactive Messaging failed in the WildFly Preview testsuite.

After some investigation, I found the cause to be that they now include the jandex index in their jars. This index contains javax annotations to define the CDI beans. If Weld finds a jandex index, it will use that. However, in EE9 preview mode, it searches for jakarta annotations in that index.The end result was that no CDI beans were found in the Reactive Messaging provider jar.

I've worked around this in my https://github.com/wildfly/wildfly/pull/14953, by adding a method to WeldCapability to ignore the precalculated jandex index for modules containing jars with a jandex index. 

I am mentioning this because the jandex index was added to help with some build time config checking for Quarkus. So it would not surprise me if other SmallRye projects, and maybe other projects consumed by Quarkus follow suit.

My changes have not been reviewed yet, so there might be some small changes but the overall concept will most likely be kept.

Thanks,

Kabir
_______________________________________________
wildfly-dev mailing list -- wildfly-dev@lists.jboss.org
To unsubscribe send an email to wildfly-dev-leave@lists.jboss.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s


--
Brian Stansberry
Principal Architect, Red Hat JBoss EAP
He/Him/His