deltaspike-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deven Phillips <>
Subject Observer in DeltaSpike 1.2.0/Weld 1.1.19.Final Not Working
Date Sun, 11 Jan 2015 05:21:36 GMT
I'm trying to implement a suggestion from John Ament based this gist:

My code looks something like:

            // Initialize DeltaSpike Dependency Injection of JavaSE
            // This will also cause some back-end setup to begin
            LOG.debug("Starting CDI Container and Contexts");
            CdiContainer cdiContainer =
            ContextControl ctxControl = cdiContainer.getContextControl();

            // Create an ObjectFactory for the JaxRsApplication to be able
            // to inject dependencies
            CdiObjectFactory objFactory = new CdiObjectFactory();

            // Send an event to DeltaSpike to load the config into
            // the application scope
            LOG.debug("Firing event to load configuration into Application
            try {
                BeanManager bm = objFactory.getInstance(BeanManager.class);
            } catch (InstantiateException ex) {
                LOG.error("Error getting BeanManager from objFactory", ex);
                throw new RuntimeException(ex);

The problem is, the observer bean never sees the event. I can trace and
step through and it never receives the event... Any thoughts on what I may
be doing wrong?

Thanks in advance!!


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message