You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by Brian Murray <br...@gmail.com> on 2007/01/05 17:03:21 UTC
Dynamic/Static Behaviors on an Application Server
I'm seeing an inconsistency when testing SDO on an application server (WAS)
versus testing from a command line - described below. Can you please
provide feedback as to why I am seeing the differences and if it is
expected.
I have a Type ('APITest') which has an element of another Type
('Sequenced'). The statically created Factory includes create methods for
both Types. If I use the Static Factory to create APITest, and then try to
use the DataFactory (dynamic) to create Sequenced - there is a difference in
behavior between WAS and command line. From the command line doing so is
okay. On WAS I receive the following error:
Error 500: org.apache.tuscany.sdo.impl.DynamicDataObjectImpl incompatible
with com.ibm.sdo.fvt.staticSdo.Sequenced
The Exception is appended at the end of this message.
If the Exception is expected, why is it not seen when running from the
command line?
If it is not expected, why is it seen on WAS.
When I use the Static Factory to also create Sequenced, it works on both
command line and WAS.
java.lang.ClassCastException:
org.apache.tuscany.sdo.impl.DynamicDataObjectImpl incompatible with
com.ibm.sdo.fvt.staticSdo.Sequenced
at com.ibm.sdo.fvt.staticSdo.impl.APITestImpl.set(APITestImpl.java:1087)
at org.apache.tuscany.sdo.impl.DataObjectBase.eSet(DataObjectBase.java
:272)
at com.ibm.sdo.internal.ecore.impl.BasicEObjectImpl.eSet(
BasicEObjectImpl.java:655)
at org.apache.tuscany.sdo.impl.DataObjectImpl.set(DataObjectImpl.java
:143)
at org.apache.tuscany.sdo.util.DataObjectUtil.set(DataObjectUtil.java
:729)
at org.apache.tuscany.sdo.impl.DataObjectImpl.setDataObject(
DataObjectImpl.java:486)
at org.apache.tuscany.sdo.fvt.lib.FVTUtil.populateFields(FVTUtil.java
:39)
at com.ibm._jsp._StaticTestCase._jspService(_StaticTestCase.java:87)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:85)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(
ServletWrapper.java:989)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(
ServletWrapper.java:501)
at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(
ServletWrapper.java:464)
at
com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(
GenericServletWrapper.java:122)
at
com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest
(AbstractJSPExtensionServletWrapper.java:196)
at
com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionProcessor.handleRequest(
AbstractJSPExtensionProcessor.java:275)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3168)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java
:254)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java
:811)
at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(
WebContainer.java:1433)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(
WCChannelLink.java:96)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
HttpInboundLink.java:465)
at
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
HttpInboundLink.java:394)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(
HttpICLReadCallback.java:102)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted
(AioReadCompletionListener.java:152)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(
AbstractAsyncFuture.java:213)
at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(
AbstractAsyncFuture.java:195)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(
ResultHandler.java:741)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1469)
Re: Dynamic/Static Behaviors on an Application Server
Posted by Frank Budinsky <fr...@ca.ibm.com>.
The exception is not expected. You're probably getting it because the
static type com.ibm.sdo.fvt.staticSdo.Sequenced was not registered in the
WAS environment (usually by a call to SDOUtil.registerStaticTypes), so
DataFactory is creating a DynamicDataObjectImpl as a fallback.
Frank.
"Brian Murray" <br...@gmail.com> wrote on 01/05/2007 11:03:21
AM:
> I'm seeing an inconsistency when testing SDO on an application server
(WAS)
> versus testing from a command line - described below. Can you please
> provide feedback as to why I am seeing the differences and if it is
> expected.
>
> I have a Type ('APITest') which has an element of another Type
> ('Sequenced'). The statically created Factory includes create methods
for
> both Types. If I use the Static Factory to create APITest, and then try
to
> use the DataFactory (dynamic) to create Sequenced - there is a
difference in
> behavior between WAS and command line. From the command line doing so
is
> okay. On WAS I receive the following error:
>
> Error 500: org.apache.tuscany.sdo.impl.DynamicDataObjectImpl
incompatible
> with com.ibm.sdo.fvt.staticSdo.Sequenced
>
> The Exception is appended at the end of this message.
>
> If the Exception is expected, why is it not seen when running from the
> command line?
> If it is not expected, why is it seen on WAS.
>
> When I use the Static Factory to also create Sequenced, it works on both
> command line and WAS.
>
> java.lang.ClassCastException:
> org.apache.tuscany.sdo.impl.DynamicDataObjectImpl incompatible with
> com.ibm.sdo.fvt.staticSdo.Sequenced
> at
com.ibm.sdo.fvt.staticSdo.impl.APITestImpl.set(APITestImpl.java:1087)
> at
org.apache.tuscany.sdo.impl.DataObjectBase.eSet(DataObjectBase.java
> :272)
> at com.ibm.sdo.internal.ecore.impl.BasicEObjectImpl.eSet(
> BasicEObjectImpl.java:655)
> at
org.apache.tuscany.sdo.impl.DataObjectImpl.set(DataObjectImpl.java
> :143)
> at
org.apache.tuscany.sdo.util.DataObjectUtil.set(DataObjectUtil.java
> :729)
> at org.apache.tuscany.sdo.impl.DataObjectImpl.setDataObject(
> DataObjectImpl.java:486)
> at
org.apache.tuscany.sdo.fvt.lib.FVTUtil.populateFields(FVTUtil.java
> :39)
> at com.ibm._jsp._StaticTestCase._jspService(_StaticTestCase.java:87)
> at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:85)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
> at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(
> ServletWrapper.java:989)
> at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(
> ServletWrapper.java:501)
> at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(
> ServletWrapper.java:464)
> at
> com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(
> GenericServletWrapper.java:122)
> at
> com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.
> handleRequest
> (AbstractJSPExtensionServletWrapper.java:196)
> at
>
com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionProcessor.handleRequest(
> AbstractJSPExtensionProcessor.java:275)
> at
com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3168)
> at
com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java
> :254)
> at
com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java
> :811)
> at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(
> WebContainer.java:1433)
> at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(
> WCChannelLink.java:96)
> at
>
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
> HttpInboundLink.java:465)
> at
>
com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
> HttpInboundLink.java:394)
> at
com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(
> HttpICLReadCallback.java:102)
> at
com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted
> (AioReadCompletionListener.java:152)
> at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(
> AbstractAsyncFuture.java:213)
> at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(
> AbstractAsyncFuture.java:195)
> at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
> at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
> at com.ibm.io.async.ResultHandler.runEventProcessingLoop(
> ResultHandler.java:741)
> at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
> at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1469)
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org