0 Replies Latest reply on Apr 5, 2012 4:03 AM by William Sanjaya

    CDI in Lift packages

    William Sanjaya Newbie

      Hi everyone,


      Has anyone investigated a way to do injection using CDI in a Lift web app? I did a little test using the numberguess example and tried injecting it normally into several Lift snippets (reflection-based and DispatchSnippet subclass) like so:

      @Inject @Random var randomNumber: Instance[Integer] = _


      When I (deliberately) tried injecting it into a final variable (val) it would spew an error message over which I assume that Weld indeed recognizes the injection point.  But in the end it doesn't work, the injected random integer instance is null.


      Any help or hints would be appreciated!


      Lift 2.4, JBoss AS 7.1.1