2 Replies Latest reply on Feb 18, 2014 11:58 AM by luksa

    NPE on production

    nikolay.mitev

      Hello,

       

      I have a development environment and a production environment based on Ubuntu and OpenStack. I'm testing CD with the todolist. It works fine on development env, (if deployed as ROOT.war), but on production I get Internal Server Error. This is the stack trace:

       

      2014-02-18 15:38:30,561 ERROR [io.undertow.request] (default task-14) UT005023: Exception handling request to /index: java.lang.NullPointerException

      at com.google.appengine.api.NamespaceManager.get(NamespaceManager.java:101) [appengine-api-1.0-sdk-1.8.8.jar:1384479771]

      at com.google.appengine.api.search.SearchServiceImpl.getAppNamespace(SearchServiceImpl.java:121) [appengine-api-1.0-sdk-1.8.8.jar:]

      at com.google.appengine.api.search.SearchServiceImpl.<init>(SearchServiceImpl.java:26) [appengine-api-1.0-sdk-1.8.8.jar:]

      at com.google.appengine.api.search.SearchServiceFactoryImpl.getSearchService(SearchServiceFactoryImpl.java:36) [appengine-api-1.0-sdk-1.8.8.jar:]

      at com.google.appengine.api.search.SearchServiceFactory.getSearchService(SearchServiceFactory.java:52) [appengine-api-1.0-sdk-1.8.8.jar:]

      at com.google.appengine.api.search.SearchServiceFactory.getSearchService(SearchServiceFactory.java:61) [appengine-api-1.0-sdk-1.8.8.jar:]

      at org.jboss.capedwarf.todolist.dao.AbstractDAO.<init>(AbstractDAO.java:41) [classes:]

      at org.jboss.capedwarf.todolist.dao.TasksDAO.<init>(TasksDAO.java:44) [classes:]

       

      Can you help, please?

        • 1. Re: NPE on production
          luksa

          What do you mean by "Production"?

           

          I see you are running this on Undertow, so I assume you're running on CapeDwarf, but from the stack trace it looks like the original (Google's) SearchServiceImpl is being used and not CapeDwarf's (which is called CapedwarfSearchService)

          • 2. Re: NPE on production
            luksa

            Are you bundling appengine-sdk.jar in your war or not? If not, CapeDwarf will use the jar in %CD_HOME%/modules/com/google/appengine/main. Did you run %CD_HOME%/bin/capedwarf-bytecode.sh after installation (or run capedwarf.sh, which automatically also runs capedwarf-bytecode.sh on the first run)?