Hi Alex,
could you share your code?
Or, ideally, a reproducer?
Your scenario sounds valid to me and so does your deployment.
But I suppose there is a catch somewhere which I cannot glance from just the description.
Regards,
Matej
----- Original Message -----
From: "Alex Sviridov" <ooo_saturn7(a)mail.ru>
To: "weld-dev" <weld-dev(a)lists.jboss.org>
Sent: Tuesday, March 6, 2018 12:10:51 PM
Subject: [weld-dev] How to inject in servlet CDI beans from war/lib?
Hi all.
Could anyone help me with the following problem. I have a war that contains
one servlet.
In WEB-INF of the war I have beans.xml. Besides, inside this war, in lib
folder I have
a jar archive. Jar archive has beans.xml in META-INF.
I use GlassFish 5 that uses Weld. When I want to inject in servlet CDI bean
from jar,
container doesn't inject anything - field is null, and no errors I get.
However, when
I inject in servlet EJB bean everything works fine.
How to fix it?
--
Best regards, Alex Sviridov
_______________________________________________
weld-dev mailing list
weld-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/weld-dev