Announcement

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

    Issue with 'JSExpression cannot be cast to Long'

    I've been building a project on SmartGWT for a while now, but for various reasons I want to see if DataSources are going to make life easier. As such I'm running this on a very recent version of SmartGWT EE, currently 3.0d

    This appears to occur regardless of browser, and completely seems to be a server-side problem.

    In this simple example, I'm trying to bind against an "athlete" object, which for the moment is pretty simple:
    Code:
    <DataSource ID="athlete">
    <fields>
        <field primaryKey="true"
              name="riderId"          hidden="true"      type="sequence" />
        <field name="firstname"  title="First Name" type="text" />
        <field name="lastname"   title="Last Name"  type="text" />
        <field name="email"   title="email"  type="text" />
        <field name="dob"   title="DOB"   type="date" />
    </fields>
    </DataSource>
    It's being retrieved as follows:
    Code:
    		DataSource athleteDataSource = DataSource.get("athlete");
    Unfortunately the errors I'm seeing don't seem to be relevant to anything I've defined. I'm reasonably confident it's my simple DataSource file causing the issue(s), but I can't see how or why. Ultimately this is completely blocking me from making any further progress or evaluating whether or not EE is going to be worth pursuing further. An extensive Google and Forum search only gives a few similar threads, but nothing obviously that's helped me solve the problem.


    After hitting the application and causing that DataSource.get to be executed, the server logs look as follows:

    ISC: Configuring log4j from: file:/D:/dev/workspaces/elemental/timing-web/src/main/resources/log4j.isc.config.xml
    === 2012-07-26 21:09:49,828 [main] INFO ISCInit - Isomorphic SmartClient Framework - Initializing
    === 2012-07-26 21:09:49,832 [main] INFO ConfigLoader - Attempting to load framework.properties from CLASSPATH
    === 2012-07-26 21:09:49,920 [main] INFO ConfigLoader - Successfully loaded framework.properties from CLASSPATH at location: jar:file:/D:/dev/workspaces/elemental/timing-web/war/WEB-INF/lib/isomorphic_core_rpc.jar!/framework.properties
    === 2012-07-26 21:09:49,920 [main] INFO ConfigLoader - Attempting to load project.properties from CLASSPATH
    === 2012-07-26 21:09:49,921 [main] INFO ConfigLoader - Unable to locate project.properties in CLASSPATH
    === 2012-07-26 21:09:49,925 [main] INFO ConfigLoader - Successfully loaded isc_interfaces.properties from CLASSPATH at location: jar:file:/D:/dev/workspaces/elemental/timing-web/war/WEB-INF/lib/isomorphic_core_rpc.jar!/isc_interfaces.properties
    === 2012-07-26 21:09:49,925 [main] INFO ConfigLoader - Attempting to load server.properties from CLASSPATH
    === 2012-07-26 21:09:49,927 [main] INFO ConfigLoader - Successfully loaded server.properties from CLASSPATH at location: file:/D:/dev/workspaces/elemental/timing-web/src/main/resources/server.properties
    === 2012-07-26 21:09:49,931 [main] INFO Logger - Logging system started.
    === 2012-07-26 21:09:49,931 [main] INFO ISCInit - Isomorphic SmartClient Framework (v8.2p_2012-07-10/EVAL Deployment 2012-07-10) - Initialization Complete
    === 2012-07-26 21:09:49,932 [main] INFO ISCInit - No ServletContext available yet - using container IO for now
    Problem loading builtinTypes.xml
    Exception when loading from __USE_CONTAINER__/com.elemental.timing.web.gwt.TimingModule/sc/system/schema/builtinTypes.xml:
    java.io.IOException: Configured for containerIO, but servletContext not available! You need to install the Init servlet
    at com.isomorphic.io.ISCFile.<init>(ISCFile.java:139)
    at com.isomorphic.store.ProcessedFileCache.getObjectFromFile(ProcessedFileCache.java:138)
    at com.isomorphic.xml.XML.getXMLDocument(XML.java:255)
    at com.isomorphic.xml.XML.toDSRecords(XML.java:263)
    at com.isomorphic.xml.XML.toDSRecords(XML.java:266)
    at com.isomorphic.datasource.DataSource.<clinit>(DataSource.java:555)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    at java.lang.reflect.Constructor.newInstance(Unknown Source)
    at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
    at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:76)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:990)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:943)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:485)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
    at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:384)
    at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:283)
    at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
    at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
    at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
    at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
    at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
    at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
    at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
    at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
    at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    at org.mortbay.jetty.Server.doStart(Server.java:222)
    at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
    at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
    at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
    at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
    at com.google.gwt.dev.DevMode.main(DevMode.java:311)

    === 2012-07-26 21:09:50,012 [main] INFO ISCInit - Auto-detected webRoot - using: D:\dev\workspaces\elemental\timing-web\war
    Jul 26, 2012 9:09:50 PM com.sun.jersey.api.core.PackagesResourceConfig init
    INFO: Scanning for root resource and provider classes in the packages:
    com.elemental.timing.ws
    Jul 26, 2012 9:09:50 PM com.sun.jersey.api.core.ScanningResourceConfig logClasses
    INFO: Root resource classes found:
    class com.elemental.timing.ws.AthleteListService
    class com.elemental.timing.ws.AthleteService
    Jul 26, 2012 9:09:50 PM com.sun.jersey.api.core.ScanningResourceConfig init
    INFO: No provider classes found.
    Jul 26, 2012 9:09:50 PM com.sun.jersey.spi.spring.container.servlet.SpringServlet getContext
    INFO: Using default applicationContext
    Jul 26, 2012 9:09:50 PM com.sun.jersey.spi.spring.container.SpringComponentProviderFactory registerSpringBeans
    INFO: Registering Spring bean, athleteListService, of type com.elemental.timing.ws.AthleteListService as a root resource class
    Jul 26, 2012 9:09:50 PM com.sun.jersey.spi.spring.container.SpringComponentProviderFactory registerSpringBeans
    INFO: Registering Spring bean, athleteListRest, of type com.elemental.timing.ws.AthleteListService as a root resource class
    Jul 26, 2012 9:09:50 PM com.sun.jersey.spi.spring.container.SpringComponentProviderFactory registerSpringBeans
    INFO: Registering Spring bean, athleteRest, of type com.elemental.timing.ws.AthleteService as a root resource class
    Jul 26, 2012 9:09:50 PM com.sun.jersey.server.impl.application.WebApplicationImpl _initiate
    INFO: Initiating Jersey application, version 'Jersey: 1.11 12/09/2011 11:05 AM'
    Jul 26, 2012 9:09:50 PM com.sun.jersey.spi.inject.Errors processErrorMessages
    WARNING: The following warnings have been detected with resource and/or provider classes:
    WARNING: A sub-resource method, public javax.ws.rs.core.Response com.elemental.timing.ws.AthleteService.listAll() throws java.rmi.RemoteException, with URI template, "/", is treated as a resource method
    [WARN] Server class 'org.apache.xalan.processor.TransformerFactoryImpl' could not be found in the web app, but was found on the system classpath
    [WARN] Adding classpath entry 'file:/C:/Users/trowe/.eclipse/org.eclipse.platform_3.6.1_1709980481/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r36/gwt-2.4.0/gwt-dev.jar' to the web app classpath for this session
    For additional info see: file:/C:/Users/trowe/.eclipse/org.eclipse.platform_3.6.1_1709980481/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r36/gwt-2.4.0/doc/helpInfo/webAppClassPath.html
    === 2012-07-26 21:11:18,938 [l0-0] INFO RequestContext - URL: '/TimingModule.html', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:18,946 [l0-0] INFO Compression - /TimingModule.html: 1682 -> 622 bytes
    === 2012-07-26 21:11:18,962 [l0-3] INFO RequestContext - URL: '/com.elemental.timing.web.gwt.TimingModule/sc/DataSourceLoader', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:18,996 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\load_skin.js
    === 2012-07-26 21:11:19,001 [l0-3] INFO PoolManager - SmartClient pooling disabled for 'athlete' objects
    === 2012-07-26 21:11:19,008 [l0-2] INFO Compression - /com.elemental.timing.web.gwt.TimingModule/sc/modules/ISC_Core.js: 715895 -> 185702 bytes
    === 2012-07-26 21:11:19,011 [l0-3] DEBUG XML - Parsed XML from D:\dev\workspaces\elemental\timing-web\war\ds\athlete.ds.xml: 3ms
    === 2012-07-26 21:11:19,015 [l0-3] DEBUG XML - Parsed XML from D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\system\schema\DataSource.ds.xml: 4ms
    === 2012-07-26 21:11:19,035 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/ID
    === 2012-07-26 21:11:19,039 [l0-3] DEBUG XML - Parsed XML from D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\system\schema\DataSourceField.ds.xml: 3ms
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'boolean', not processing field value at /DataSource[@ID=athlete]/fields/0/field[@name=riderId]/hidden
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/0/field[@name=riderId]/name
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'boolean', not processing field value at /DataSource[@ID=athlete]/fields/0/field[@name=riderId]/primaryKey
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/0/field[@name=riderId]/type
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/1/field[@name=firstname]/name
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/1/field[@name=firstname]/title
    === 2012-07-26 21:11:19,050 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/1/field[@name=firstname]/type
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/2/field[@name=lastname]/name
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/2/field[@name=lastname]/title
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/2/field[@name=lastname]/type
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/3/field[@name=email]/name
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/3/field[@name=email]/title
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/3/field[@name=email]/type
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/4/field[@name=dob]/name
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/4/field[@name=dob]/title
    === 2012-07-26 21:11:19,051 [l0-3] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=athlete]/fields/4/field[@name=dob]/type
    === 2012-07-26 21:11:19,057 [l0-3] INFO Compression - /com.elemental.timing.web.gwt.TimingModule/sc/DataSourceLoader: 602 -> 206 bytes
    === 2012-07-26 21:11:19,446 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\skin_styles.css
    === 2012-07-26 21:11:24,861 [l0-3] INFO RequestContext - URL: '/timing/event', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    [WARN] Server class 'org.apache.ddlutils.model.ModelException' could not be found in the web app, but was found on the system classpath
    [WARN] Adding classpath entry 'file:/D:/dev/workspaces/elemental/timing/lib/DdlUtils-1.0.jar' to the web app classpath for this session
    For additional info see: file:/C:/Users/trowe/.eclipse/org.eclipse.platform_3.6.1_1709980481/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r36/gwt-2.4.0/doc/helpInfo/webAppClassPath.html
    [WARN] Server class 'org.apache.derby.jdbc.EmbeddedDriver' could not be found in the web app, but was found on the system classpath
    [WARN] Adding classpath entry 'file:/D:/dev/workspaces/elemental/timing-derby/lib/derby.jar' to the web app classpath for this session
    For additional info see: file:/C:/Users/trowe/.eclipse/org.eclipse.platform_3.6.1_1709980481/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r36/gwt-2.4.0/doc/helpInfo/webAppClassPath.html
    === 2012-07-26 21:11:25,136 [l0-2] INFO RequestContext - URL: '/timing/venue', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:25,364 [l0-6] INFO RequestContext - URL: '/timing/series', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:26,449 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_stretch.png
    === 2012-07-26 21:11:26,449 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_start.png
    === 2012-07-26 21:11:26,454 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_end.png
    === 2012-07-26 21:11:26,456 [l0-4] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_Over_stretch.png
    === 2012-07-26 21:11:26,459 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_stretch.png
    === 2012-07-26 21:11:26,459 [l0-6] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_start.png
    === 2012-07-26 21:11:26,460 [l0-3] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_Over_end.png
    === 2012-07-26 21:11:26,460 [l0-2] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_end.png
    === 2012-07-26 21:11:26,461 [l0-0] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\Tab\top\tab_Selected_Over_start.png
    === 2012-07-26 21:11:27,119 [l0-0] INFO Download - Returning 304: Not modified on conditional get of: D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\skins\Enterprise\images\pickers\comboBoxPicker.png
    === 2012-07-26 21:11:27,159 [l0-0] INFO RequestContext - URL: '/com.elemental.timing.web.gwt.TimingModule/sc/IDACall', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:27,175 [l0-2] INFO RequestContext - URL: '/favicon.ico', User-Agent: 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.57 Safari/536.11': Safari with Accept-Encoding header
    === 2012-07-26 21:11:27,177 [l0-0] DEBUG XML - Parsed XML from (in memory stream): 3ms
    === 2012-07-26 21:11:27,181 [l0-0] DEBUG XML - Parsed XML from D:\dev\workspaces\elemental\timing-web\war\com.elemental.timing.web.gwt.TimingModule\sc\system\schema\List.ds.xml: 2ms
    === 2012-07-26 21:11:27,182 [l0-0] WARN Validation - No such type 'string', not processing field value at /DataSource[@ID=List]/ID
    === 2012-07-26 21:11:27,184 [l0-0] ERROR IDACall - Top-level servlet error:
    java.lang.ClassCastException: com.isomorphic.js.JSExpression cannot be cast to java.lang.Long
    at com.isomorphic.rpc.RPCManager.parseRequest(RPCManager.java:1866)
    at com.isomorphic.rpc.RPCManager.<init>(RPCManager.java:296)
    at com.isomorphic.rpc.RPCManager.<init>(RPCManager.java:281)
    at com.isomorphic.servlet.IDACall.processRequest(IDACall.java:116)
    at com.isomorphic.servlet.IDACall.doPost(IDACall.java:73)
    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 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)
    === 2012-07-26 21:11:27,187 [l0-0] INFO Compression - /com.elemental.timing.web.gwt.TimingModule/sc/IDACall: 2258 -> 619 bytes
    Two thigns stand out to me:
    1. The Jersey log entries from the services I previously had, but these are bound to different classes, different URLs... Removing/disabling it hasn't helped (for now, it would break other areas of the app to chop all that out... I'm not convinced it's related).
    2. All the fields being specified with 'No such type...'
    I expect this is the crux of the problem. I have no idea how to resolve it.

    Can anyone make any suggestions?

    #2
    Didn't you see the huge warning and stack trace about the lack of init Servlet / bad webroot setting? That's the issue.

    Comment


      #3
      I have certainly tried to ensure things are followed as per http://forums.smartclient.com/showthread.php?t=19754, but other threads have indicated this is to be expected in some circumstances. As it is the exception messages given by this are pretty unhelpful.

      Attached is my complete web.xml file, in which I've attempted everything I can find to rectify this problem.

      Setting webRoot to / in server.properties results in the following error instead:
      === 2012-07-27 21:48:09,124 [main] ERROR ISCInit - Can't find marker file for webRoot: /com.elemental.timing.web.gwt.TimingModule/sc for configured/autodetected webRoot - if you moved the 'isomorphic' directory, please set isomorphicPathRootRelative in server.properties to the new location and restart the servlet engine.
      Isomorphic Init: Exception in Init.go()
      java.lang.Exception: Configured webRoot path is invalid please check your server.properties setting. Current value is: /
      at com.isomorphic.base.ISCInit.go(ISCInit.java:76)
      at com.isomorphic.base.Init.go(Init.java:87)
      at com.isomorphic.servlet.BaseFilter.init(BaseFilter.java:56)
      at com.isomorphic.servlet.CompressionFilter.init(CompressionFilter.java:148)
      at org.mortbay.jetty.servlet.FilterHolder.doStart(FilterHolder.java:97)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:593)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:140)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
      at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
      at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
      at org.mortbay.jetty.Server.doStart(Server.java:222)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
      at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
      at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
      at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
      at com.google.gwt.dev.DevMode.main(DevMode.java:311)
      Interestingly with a path of '/', it also gives this, which would seem to say it's looking int he completely wrong location for builtinTypes.xml. At least this exception is a slight step in the right direction as it actually tells you it can't find the file:
      Problem loading builtinTypes.xml
      Exception when loading from /com.elemental.timing.web.gwt.TimingModule/sc/system/schema/builtinTypes.xml:
      java.io.FileNotFoundException: \com.elemental.timing.web.gwt.TimingModule\sc\system\schema\builtinTypes.xml (The system cannot find the path specified)
      at java.io.FileInputStream.open(Native Method)
      at java.io.FileInputStream.<init>(Unknown Source)
      at com.isomorphic.io.ISCFile.getInputStream(ISCFile.java:349)
      at com.isomorphic.xml.XML$DocumentCache.loadObjectFromFile(XML.java:240)
      at com.isomorphic.store.ProcessedFileCache.getObjectFromFile(ProcessedFileCache.java:132)
      at com.isomorphic.store.ProcessedFileCache.getObjectFromFile(ProcessedFileCache.java:74)
      at com.isomorphic.store.ProcessedFileCache.getObjectFromFile(ProcessedFileCache.java:138)
      at com.isomorphic.xml.XML.getXMLDocument(XML.java:255)
      at com.isomorphic.xml.XML.toDSRecords(XML.java:263)
      at com.isomorphic.xml.XML.toDSRecords(XML.java:266)
      at com.isomorphic.datasource.DataSource.<clinit>(DataSource.java:555)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
      at java.lang.reflect.Constructor.newInstance(Unknown Source)
      at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:147)
      at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:76)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:990)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:943)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:485)
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
      at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
      at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
      at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
      at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
      at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
      at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)
      at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
      at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:384)
      at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:283)
      at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
      at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
      at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
      at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
      at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
      at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
      at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
      at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
      at org.mortbay.jetty.Server.doStart(Server.java:222)
      at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
      at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
      at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
      at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
      at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
      at com.google.gwt.dev.DevMode.main(DevMode.java:311)
      Another thread briefly mentions this 'marker file', but doesn't specify what it is, or what the full set of files it's looking for is - nor can I see an 'isomorphic' dir in any of the samples.

      Nothing in these exceptions, the documentation, or anywhere on the forums seems to be remotely helpful in solving these exceptions.


      Now it would seem taht setting webRoot as:
      webRoot: D:\dev\workspaces\elemental\timing-web\war
      seems to work. However this seems odd for two reasons:
      1. This path is what I cut and pasted from what autodetect found. Why would autodetect not work when it's found the same path as what I'm now manually specifying
      2. Obviously I can't hardcode a location on my local system. That's simply not portable.

      Note that this does seem to solve the problem and I'm now trying to resolve exceptions dealing with a missing fetch method - but I believe that to be another issue.
      The documentation and descriptions in the above errors though leave a lot to be desired. A more realistic solution to this webRoot would be a requirement in production.
      Attached Files
      Last edited by akashra; 27 Jul 2012, 04:28.

      Comment


        #4
        Oh, it looks like you've hit a bug in Spring - see this thread (among others) that explains how to delay Spring so that it does not take action before the init servlet.

        This is no longer needed in 3.1d since we worked around the Spring issue.

        Comment

        Working...
        X