Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    SQLDriver getting null pointer error in latest nightly

    I'm testing the 2010-11-20 build and am getting an error that was not happening with the prior build (2010-11-11). It is the SQLDriver getting a NullPointerException, it looks like a problem with the Velocity substitutions. Here is the DSRequest from the log about to be processed and the unsubstituted SQL also from the log.
    Code:
    === 2010-11-20 13:43:36,337 [l0-4] DEBUG RPCManager - Request #1 (DSRequest) payload: {
        criteria:{
            IONO:"LKJDSLKJDS"
        },
        operationConfig:{
            dataSource:"PoItem",
            operationType:"fetch",
            textMatchStyle:"exact"
        },
        sortBy:[
            "IPPK",
            "ItemNumber"
        ],
        componentId:"isc_PoItemCanvas$12_1",
        appID:"builtinApplication",
        operation:"fetch2_PoItem_member(F909)",
        oldValues:{
            IONO:"LKJDSLKJDS"
        }
    }
    === 2010-11-20 13:43:36,383 [l0-4] INFO  SQLDataSource - [builtinApplication.fetch2_PoItem_member(F909)] derived query: SELECT 
    				$defaultSelectClause,
    				CASE WHEN IPPOITM.IPPK='Y' 
    					 THEN DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)||'-'||DIGITS(IPPOITM.ISIZ)
    					 ELSE
    				#if ($requestAttributes.GroupLevel == "style")
    				DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)
    				#elseif ($requestAttributes.GroupLevel == "color")
    				DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)
    				#else
    				DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)||'-'||DIGITS(IPPOITM.ISIZ)
    				#end 
    				END AS ItemNumber,
    				sum(CASE WHEN (IERR='C' OR ITQR>IQTY) THEN 0 ELSE IQTY-ITQR END) AS QtyOpen,
    				sum(CASE WHEN IPPOITM.IPPK!='Y' 
    					THEN IQTY
    					ELSE IQTY * IPITHDR.IPKQTY
    					END) 
    					AS UnitsOrdered,
    				sum(CASE WHEN IPPOITM.IPPK!='Y' 
    					THEN ITQR
    					ELSE ITQR * IPITHDR.IPKQTY
    					END) 
    					AS UnitsReceived,
    				sum(CASE WHEN IPPOITM.IPPK!='Y'
    					THEN CASE WHEN (IERR='C' OR ITQR>IQTY) THEN 0 ELSE IQTY-ITQR END 
    					ELSE CASE WHEN (IERR='C' OR ITQR>IQTY) THEN 0 ELSE (IQTY-ITQR) * IPITHDR.IPKQTY END
    					END)
    					AS UnitsOpen,				
    				min(IPPOITN.POITMNT) as POITMNT	
    			 FROM 
    				IPPOITM#if($requestAttributes.fileMemberName)_$rawValue.requestAttributes.fileMemberName#end IPPOITM
    				LEFT JOIN IPSIZES on IPPOITM.ISIZ=SSIZ
    				LEFT JOIN IPPOCOM ON IPPOITM.IONO=IPPOCOM.CONO AND IPPOITM.ISEQ=IPPOCOM.CSEQ
    				LEFT JOIN IPPOITN#if($requestAttributes.fileMemberName)_$rawValue.requestAttributes.fileMemberName#end IPPOITN 
                       	on IPPOITM.ICLS=IPPOITN.PONCLS and IPPOITM.IVEN=IPPOITN.PONVEN and IPPOITM.ISTY=IPPOITN.PONSTY and IPPOITM.ICLR=IPPOITN.PONCLR and IPPOITM.ISIZ=IPPOITN.PONSIZ
                    LEFT JOIN IPITHDR 
                    	on IPPOITM.ICLS=IPITHDR.ICLS and IPPOITM.IVEN=IPITHDR.IVEN and IPPOITM.ISTY=IPITHDR.ISTY and IPPOITM.ICLR=IPITHDR.ICLR and IPPOITM.ISIZ=IPITHDR.ISIZ												
    	  		 WHERE 
    				IPPOITM.IONO = $criteria.IONO
    				#if($criteria.ICLS) AND IPPOITM.ICLS=$criteria.ICLS #end
    				#if($criteria.IVEN) AND IPPOITM.IVEN=$criteria.IVEN #end
    				#if($criteria.ISTY) AND IPPOITM.ISTY=$criteria.ISTY #end
    				#if($criteria.ICLR) AND IPPOITM.ICLR=$criteria.ICLR #end
    				#if($criteria.ISIZ) AND IPPOITM.ISIZ=$criteria.ISIZ #end
    			 GROUP BY 
    					IPPOITM.IONO, IPPOITM.IASQ, 
    					CASE WHEN IPPOITM.IPPK='Y' 
    				 	THEN DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)||'-'||DIGITS(IPPOITM.ISIZ)
    				 	ELSE
    					#if ($requestAttributes.GroupLevel == "style")
    					DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)
    					#elseif ($requestAttributes.GroupLevel == "color")
    					DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)
    					#else
    					DIGITS(IPPOITM.ICLS)||'-'||DIGITS(IPPOITM.IVEN)||'-'||DIGITS(IPPOITM.ISTY)||'-'||DIGITS(IPPOITM.ICLR)||'-'||DIGITS(IPPOITM.ISIZ)
    					#end 
    					END 
    				HAVING $defaultWhereClause
    			 ORDER BY $defaultOrderClause
    And here is the error.
    Code:
    === 2010-11-20 13:43:36,433 [l0-4] WARN  RequestContext - dsRequest.execute() failed: 
    java.lang.NullPointerException
    	at com.isomorphic.sql.SQLDriver.sqlInTransform(SQLDriver.java:795)
    	at com.isomorphic.sql.DB2iSeriesDriver.sqlInTransform(DB2iSeriesDriver.java:112)
    	at com.isomorphic.sql.SQLDataSource.valueForWhereClause(SQLDataSource.java:600)
    	at com.isomorphic.sql.SQLDataSource.escapeValueForWhereClause(SQLDataSource.java:559)
    	at com.isomorphic.velocity.ISCReferenceInsertionEventHandler.referenceInsert(ISCReferenceInsertionEventHandler.java:105)
    	at org.apache.velocity.app.event.ReferenceInsertionEventHandler$referenceInsertExecutor.execute(ReferenceInsertionEventHandler.java:87)
    	at org.apache.velocity.app.event.EventHandlerUtil.iterateOverEventHandlers(EventHandlerUtil.java:444)
    	at org.apache.velocity.app.event.EventHandlerUtil.referenceInsert(EventHandlerUtil.java:97)
    	at org.apache.velocity.runtime.parser.node.ASTReference.render(ASTReference.java:372)
    	at org.apache.velocity.runtime.parser.node.SimpleNode.render(SimpleNode.java:336)
    	at org.apache.velocity.runtime.RuntimeInstance.render(RuntimeInstance.java:1277)
    	at org.apache.velocity.runtime.RuntimeInstance.evaluate(RuntimeInstance.java:1216)
    	at org.apache.velocity.runtime.RuntimeInstance.evaluate(RuntimeInstance.java:1165)
    	at org.apache.velocity.app.VelocityEngine.evaluate(VelocityEngine.java:219)
    	at com.isomorphic.velocity.Velocity.evaluate(Velocity.java:211)
    	at com.isomorphic.velocity.Velocity.evaluateAsString(Velocity.java:182)
    	at com.isomorphic.sql.SQLDataSource.generateSQLStatement(SQLDataSource.java:788)
    	at com.isomorphic.sql.SQLDataSource.SQLExecute(SQLDataSource.java:1182)
    	at com.isomorphic.sql.SQLDataSource.execute(SQLDataSource.java:257)
    	at com.islandpacific.gui.server.customDataSource.IpDataSource.execute(IpDataSource.java:60)
    	at com.islandpacific.gui.server.customDataSource.PoItemDS.execute(PoItemDS.java:289)
    	at com.isomorphic.application.AppBase.executeDefaultDSOperation(AppBase.java:721)
    	at com.isomorphic.application.AppBase.executeAppOperation(AppBase.java:658)
    	at com.isomorphic.application.AppBase.execute(AppBase.java:491)
    	at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:1418)
    	at com.isomorphic.servlet.IDACall.handleDSRequest(IDACall.java:173)
    	at com.islandpacific.gui.server.customDataSource.IpIDACall.handleDSRequest(IpIDACall.java:40)
    	at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:130)
    	at com.isomorphic.servlet.IDACall.processRequest(IDACall.java:95)
    	at com.isomorphic.servlet.IDACall.doPost(IDACall.java:54)
    	at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
    	at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:152)
    	at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)
    	at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1097)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:343)
    	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109)
    	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:97)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:100)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:54)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:35)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:188)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:105)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:79)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at com.islandpacific.gui.security.IpConcurrentSessionFilter.doFilter(IpConcurrentSessionFilter.java:55)
    	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:355)
    	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:149)
    	at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:237)
    	at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)
    	at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1088)
    	at com.isomorphic.servlet.CompressionFilter.doFilter(CompressionFilter.java:259)
    	at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1088)
    	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:360)
    	at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
    	at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
    	at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:729)
    	at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
    	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    	at org.mortbay.jetty.handler.RequestLogHandler.handle(RequestLogHandler.java:49)
    	at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    	at org.mortbay.jetty.Server.handle(Server.java:324)
    	at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505)
    	at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:843)
    	at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:647)
    	at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
    	at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380)
    	at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:395)
    	at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:488)

    #2
    Hello Isomorphic - Have you been able to reproduce this?
    Is it possible that the fix for this issue is the same fix?

    Comment


      #3
      We haven't reproduced this one yet, but several fixes have gone in recently that might have resolved this issue.

      Comment


        #4
        Actually on a second look we're fairly sure that this one is fixed as of 2 nights ago.

        Comment

        Working...
        X