2 Replies Latest reply on Jul 12, 2007 9:39 AM by Norman Richards

    Configuring POJOs as Seam Components in components.xml

    youngm Novice

      I'm using 1.2.0.nightly

      Is it legal to configure POJOs as Seam components in components.xml?

      For example:

      <component name="expanderState" class="java.util.HashMap" auto-create="true" scope="conversation"/>


      I get:

      java.lang.RuntimeException: Could not create Component: expanderState
       at org.jboss.seam.init.Initialization.addComponent(Initialization.java:910)
       at org.jboss.seam.init.Initialization.installComponents(Initialization.java:841)
       at org.jboss.seam.init.Initialization.init(Initialization.java:508)
       at org.jboss.seam.servlet.SeamListener.contextInitialized(SeamListener.java:34)
       at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3764)
       at org.apache.catalina.core.StandardContext.start(StandardContext.java:4216)
       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
       at org.apache.catalina.core.StandardHost.start(StandardHost.java:736)
       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
       at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
       at org.apache.catalina.core.StandardService.start(StandardService.java:448)
       at org.apache.catalina.core.StandardServer.start(StandardServer.java:700)
       at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
       at java.lang.reflect.Method.invoke(Method.java:615)
       at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)
       at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:433)
      Caused by:
      java.lang.NullPointerException
       at org.jboss.seam.init.DeploymentDescriptor.<init>(DeploymentDescriptor.java:33)
       at org.jboss.seam.Seam.getEjbDescriptor(Seam.java:51)
       at org.jboss.seam.Seam.getComponentType(Seam.java:102)
       at org.jboss.seam.Component.<init>(Component.java:216)
       at org.jboss.seam.Component.<init>(Component.java:207)
       at org.jboss.seam.init.Initialization.addComponent(Initialization.java:896)