5 Replies Latest reply on Jan 12, 2007 8:50 AM by adrian.brock

    What does this mean?

    bill.burke

      WARN 11-01 18:03:08,890 (AbstractTypeMetaData.java:preinstantiatedLookup:152) -Exception in preinstantiated lookup: java.lang.NullPointerException


        • 1. Re: What does this mean?
          starksm64

          Some property get is throwing an NPE. I aded the full trace to show what the cause is.

          • 2. Re: What does this mean?
            bill.burke

            do you have to have a corresponding get() method? That could be the problem.

            • 3. Re: What does this mean?
              starksm64

              Its the SecurityDeployer having a write-only ignoreSuffixes property:

              AbstractBeanMetaData@7ba65cf7{name=SecurityDeployer bean=org.jboss.deployment.security.SecurityDeployer properties=[ignoreSuffixes] constructor=null installs=[MainDeployer.addDeployer] uninstalls=[MainDeployer.removeDeployer]}
              ...
              AbstractPropertyInfo@1943b93b{name=ignoreSuffixes getter=null setter=ReflectMethodInfoImpl@2b5d7e8e{name=setIgnoreSuffixes[ParameterizedClassInfo@71fb2e0{java.util.HashSet<java.lang.String>}] return=void}}

              The problem occurs at the Configurator.getPropertyGetterJoinPoint

              18:49:29,115 WARN [AbstractSetMetaData] Exception in preinstantiated lookup:
              java.lang.NullPointerException
               at org.jboss.kernel.plugins.config.Configurator.getPropertyGetterJoinPoint(Configurator.java:381)
               at org.jboss.kernel.plugins.config.Configurator.getPropertyGetterJoinPoint(Configurator.java:360)
               at org.jboss.kernel.plugins.config.AbstractKernelConfigurator.getPropertyGetterJoinPoint(AbstractKernelConfigurator.java:115)
               at org.jboss.beans.metadata.plugins.AbstractTypeMetaData.preinstantiatedLookup(AbstractTypeMetaData.java:150)
               at org.jboss.beans.metadata.plugins.AbstractCollectionMetaData.getCollectionInstance(AbstractCollectionMetaData.java:208)
               at org.jboss.beans.metadata.plugins.AbstractCollectionMetaData.getValue(AbstractCollectionMetaData.java:85)
               at org.jboss.kernel.plugins.config.Configurator.getPropertySetterJoinPoint(Configurator.java:502)
               at org.jboss.kernel.plugins.config.Configurator.getPropertySetterJoinPoint(Configurator.java:446)
               at org.jboss.kernel.plugins.config.Configurator.getPropertySetterJoinPoints(Configurator.java:410)
               at org.jboss.kernel.plugins.config.AbstractKernelConfigurator.getPropertySetterJoinPoints(AbstractKernelConfigurator.java:120)
               at org.jboss.kernel.plugins.dependency.ConfigureAction.installActionInternal(ConfigureAction.java:54)
              


              Either this code or the caller needs to validate that a getter exists.


              • 4. Re: What does this mean?

                 

                "scott.stark@jboss.org" wrote:

                Either this code or the caller needs to validate that a getter exists.


                The code should be:
                 JoinpointFactory jpf = info.getBeanInfo().getJoinpointFactory();
                 MethodInfo minfo = info.getGetter();
                + if (minfo == null)
                + throw new IllegalArgumentException("Property is write only");
                 return getMethodJoinpoint(null, jpf, minfo.getName(), null, null);
                


                The preinstantiated lookup should be using a different mechanism
                that first checks whether the property is readable
                rather than logging a warning when it is not.

                • 5. Re: What does this mean?