osdir.com
mailing list archive

Subject: Complex/nested bean parameter getting errors - msg#00025

List: java.dwr.user

Date: Prev Next Index Thread: Prev Next Index
Hello,
I am successfully receiving a complex bean/POJO at the client but am
getting errors in trying to marshall/pass the JavaScript
representation back to a remoted method on the server. The specific
error is

uk.ltd.getahead.dwr.ConversionException: Error converting parameters for call to
PersonController.updatePerson: com.ihg.peopledb.admin.Person
at uk.ltd.getahead.dwr.impl.ExecuteQuery.execute(ExecuteQuery.java:139)
at uk.ltd.getahead.dwr.impl.DefaultExecProcessor.handle(DefaultExecProce
ssor.java:48)
at uk.ltd.getahead.dwr.impl.DefaultProcessor.handle(DefaultProcessor.jav
a:83)
at uk.ltd.getahead.dwr.AbstractDWRServlet.doPost(AbstractDWRServlet.java
:162)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:252)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:173)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:105)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:107)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.jav
a:148)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:856)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
ssConnection(Http11Protocol.java:744)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpo
int.java:527)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFol
lowerWorkerThread.java:80)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP
ool.java:684)
at java.lang.Thread.run(Unknown Source)
Caused by: uk.ltd.getahead.dwr.ConversionException: com.ihg.peopledb.admin.Perso
n
at uk.ltd.getahead.dwr.convert.BeanConverter.convertInbound(BeanConverte
r.java:262)
at uk.ltd.getahead.dwr.impl.DefaultConverterManager.convertInbound(Defau
ltConverterManager.java:162)
at uk.ltd.getahead.dwr.impl.ExecuteQuery.execute(ExecuteQuery.java:135)
... 19 more
Caused by: java.lang.InstantiationException: com.ihg.peopledb.admin.Person
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at uk.ltd.getahead.dwr.convert.BeanConverter.convertInbound(BeanConverte
r.java:180)
... 21 more
- Erroring: id[7307_1150297539329] message[uk.ltd.getahead.dwr.OutboundVariable@
d93a3f]



Here is the setup:

##### dwr.xml
<dwr>
<allow>
<create creator="new" javascript="SearchController">
<param name="class" value="com.ihg.peopledb.admin.SearchController"/>
</create>
<create creator="new" javascript="PersonController">
<param name="class" value="com.ihg.peopledb.admin.PersonController"/>
</create>
<convert converter="bean" match="com.ihg.peopledb.admin.PersonListItem"/>
<convert converter="bean" match="com.ihg.peopledb.admin.Person"/>
<convert converter="bean" match="com.ihg.peopledb.admin.Location"/>
<convert converter="bean" match="com.ihg.peopledb.admin.Contact"/>
</allow>
</dwr>

####

#### JSP
<%-- DWR scripts --%>
<script type='text/javascript'
src='/peopledb/dwr/interface/SearchController.js'></script>
<script type='text/javascript'
src='/peopledb/dwr/interface/PersonController.js'></script>
<script type='text/javascript' src='/peopledb/dwr/engine.js'></script>
<script type='text/javascript' src='/peopledb/dwr/util.js'></script>
...
var person = { locs:null, contacts:null, personID:-1, salutation:null,
firstName:null, middleName:null,
lastName:null, suffixName:null, localName:null, prefName:null,
picture:null, employeeID:null, userID:null,
email:null, dob:null, lang1:null, lang2:null, gender:null,
ethnicGroup:null,
ethnicOrigin:null, sourceSys:null, sourceSysID:null, userStatus:null,
primaryLoc:-1,
primaryContact:-1, lastUpdate:null, dept:null, userType:null,
workGroup:null };
...

function updatePerson() {
PersonController.updatePerson(setStatusResult, person);
}


#####

#### Person.java
...
import com.ihg.peopledb.admin.Location;
import com.ihg.peopledb.admin.Contact;
public class Person {
private static Context ctx = null;
private static Context envCtx = null;
private static DataSource ds = null;

// maps to store person's location(s) and contact(s)
private Map locs = new TreeMap();
private Map contacts = new TreeMap();

// from PERSON table
private int personID =-1;
private String salutation = null;
private String firstName = null;
private String middleName = null;
private String lastName = null;
private String suffixName = null;
private String localName = null; // unicode value
private String prefName = null;
private String picture = null;
private String employeeID = null;
private String userID = null;
private String email = null;
private Date dob = null;
private String lang1 = null;
private String lang2 = null;
private String gender = null;
private String ethnicGroup = null;
private String ethnicOrigin = null;
private String sourceSys = null;
private String sourceSysID = null;
private String userStatus = null;

// stores IDs of primary location record and contact record respectively
private int primaryLoc= -1;
private int primaryContact = -1;

private Date lastUpdate = null;
//...

// getters working fine!

// setters not working
public void setID(int personID) {
this.personID = personID;
}

public void setSalutation(String salutation) {
this.salutation = salutation;
}
//....

public void setLocs(Map locs) {
this.locs.putAll(locs);
}

public void setContacts(Map contacts) {
this.contacts.putAll(contacts);
}

}
#####



Note that I have different additional attributes in my JavaScript
object than I do in my Java POJO - and vice versa. But, I only have
setters on the POJO for the attributes that match. Does the JavaScript
object need to match exactly to the attributes in the POJO? Do I need
signatures for the "locs" and "contacts" parameters? They themselves
are POJOs which are setup as bean converters per above. I have NOT put
getters/setters on the Location and Contact POJO as I did not need
them for the "retrieval" but I now guess I need them in order to set
it correct? I would appreciate any help as I'm sure it is a
config/signature issue.

Thanks!!
Brian


Was this page helpful?
Yes No
Thread at a glance:

Previous Message by Date: click to view message preview

Re: RE: DWR 2.0.x and WebSphere 6.0

Hi Joe,Just wanted to know if we have the fix for this issue in CVS. I tried getting latest from CVS and building dwr.jar with jdk1.3 and jdk1.5, but its not working on Webshpere 6. and giving same errors as in the first case.Thanks and regards,Sandesh0000002c ServletWrappe E   SRVE0100E: Did not realize  init() exception thrown by servlet dwr-invoker: java.lang.LinkageError: LinkageError while defining class: org.directwebremoting.annotations.AnnotationsConfiguratorCould not be defined due to: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)This is often caused by having a class defined at multiplelocations within the classloader hierarchy.  Other potential causesinclude compiling against an older or newer version of the classthat has an incompatible method signature. Dumping the current context classloader hierarchy:    ==> indicates defining classloader==>[0]com.ibm.ws.classloader.CompoundClassLoader@70882284   Delegation Mode: PARENT_FIRST   [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:  Delegation mode: PARENT_FIRST   [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286   [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287   [4] sun.misc.Launcher$AppClassLoader@63a4a287    [5] sun.misc.Launcher$ExtClassLoader@63a0a287---Original exception---java.lang.UnsupportedClassVersionError: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)     at java.lang.ClassLoader.defineClass0(Native Method)    at java.lang.ClassLoader.defineClass(ClassLoader.java(Compiled Code))    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java(Compiled Code))     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass (CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName(LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init (DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest (WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest (WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:421)     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)--- end Original exception----     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName (LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest (ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest (VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination (HttpInboundLink.java:421)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java :94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)----- Original Message ----From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>To: users-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxSent: Thursday, May 25, 2006 5:01:52 PMSubject: Re: [dwr-user] RE: DWR 2.0.x and WebSphere 6.0Can I just take a moment to say ouch?Websphere is throwing an exception (UnsupportedClassVersionError to beaccurate) that we *can't* catch using:  catch (UnsupportedClassVersionError ex) { ...}Surely this *has* to be a bug in Websphere? Does anyone have any comments - bug?Joe.On 5/25/06, sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx < sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: Hi Joe,Thanks for your efforts on this! I tried the new dwr.jar given by you and its working fine. I am attaching the log for your reference. Please let me know once you commit these changes so that we can get a nightly build or may be a new version you might be planning for.Thanks and regards,Sandesh----- Original Message ---- From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>To: users-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxSent: Wednesday, May 24, 2006 10:54:56 AMSubject: Re: [dwr-user] RE: DWR 2.0.x and WebSphere 6.0So the exception is being throw and not caught for some reason?! Maybe this is a very very very very nasty classpath problem where the UnsupportedClassVersionError being thrown is loaded from a different classloader than the one I'm trying to catch. Yuck. I've created you a special version of dwr that contains some code to trap this, please could you tell me what happens with this one?Joe.On 5/19/06, sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx < sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: Hi Joe,I checked with the latest code and the lines are same.>In DwrServlet line 124 you should have:>>            catch (UnsupportedClassVersionError ex)>            {>                // This will happen in JDK 1.4 and below>>               handleAnnotationFailure(delayedIOException);>            }This issue is  not solved yet.Please see below for the complete stack trace.[5/11/06 10:21:13:138 IST] 0000002c ServletWrappe E   SRVE0100E: Did not realize  init() exception thrown by servlet dwr-invoker: java.lang.LinkageError: LinkageError while defining class: org.directwebremoting.annotations.AnnotationsConfiguratorCould not be defined due to: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)This is often caused by having a class defined at multiplelocations within the classloader hierarchy.  Other potential causesinclude compiling against an older or newer version of the classthat has an incompatible method signature. Dumping the current context classloader hierarchy:    ==> indicates defining classloader==>[0]com.ibm.ws.classloader.CompoundClassLoader@70882284   Delegation Mode: PARENT_FIRST   [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:  Delegation mode: PARENT_FIRST   [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286   [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287   [4] sun.misc.Launcher$AppClassLoader@63a4a287    [5] sun.misc.Launcher$ExtClassLoader@63a0a287---Original exception---java.lang.UnsupportedClassVersionError: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)     at java.lang.ClassLoader.defineClass0(Native Method)    at java.lang.ClassLoader.defineClass(ClassLoader.java(Compiled Code))    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java(Compiled Code))     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass (CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName(LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init (DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest (WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest (WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:421)     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)--- end Original exception----     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName (LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest (ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest (VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination (HttpInboundLink.java:421)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java :94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)   Date: Mon, 15 May 2006 19:03:32 +0100 From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>Content-Type: multipart/alternative;         boundary="----=_Part_15566_7929908.1147716212752"Subject: [dwr-user] Re: DWR 2.0.x and WebSphere 6.0  In DwrServlet line 124 you should have:            catch (UnsupportedClassVersionError ex)            {                // This will happen in JDK 1.4 and below                handleAnnotationFailure(delayedIOException);             }If you don't please sync with CVS again.If you do, please could you post me a stack trace, or even better debug tofind out how this is happening?Thanks.Joe On 5/13/06, Sandesh More < sandeshmore-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote:>> Joe,> I tried to get the latest of the CVS 2 days back to try the solution of > this> DWR2.0 and Websphere 6.0 issue but I am still getting follwoing errors>> [5/11/06 10:21:13:138 IST] 0000002c ServletWrappe E   SRVE0100E: Did not> realize> init() exception thrown by servlet dwr-invoker: java.lang.LinkageError :> LinkageError while defining class:> org.directwebremoting.annotations.AnnotationsConfigurator> Could not be defined due to:> org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported > major.minor version 49.0)> This is often caused by having a class defined at multiple> locations within the classloader hierarchy.  Other potential causes> include compiling against an older or newer version of the class > that has an incompatible method signature.> Dumping the current context classloader hierarchy:>     ==> indicates defining classloader> ==>[0]> com.ibm.ws.classloader.CompoundClassLoader@70882284 >    Delegation Mode: PARENT_FIRST>    [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:> Delegation mode: PARENT_FIRST>    [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286 >    [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287>    [4] sun.misc.Launcher$AppClassLoader@63a4a287>    [5] sun.misc.Launcher$ExtClassLoader@63a0a287> ---Original exception---> java.lang.UnsupportedClassVersionError :> org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported> major.minor version 49.0)>         at java.lang.ClassLoader.defineClass0(Native Method)>         at java.lang.ClassLoader.defineClass (ClassLoader.java(Compiled> Code))>>> ---------------------------------------------------------------------> To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx > For additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx> >--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxFor additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx ---------------------------------------------------------------------To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxFor additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx ---------------------------------------------------------------------To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx

Next Message by Date: click to view message preview

Urgent, please help: "java.lang.SecurityException: No class by name"

Hello, I am not sure what made me get the following errors. It just throws the following exception. In the web.xml (shown in the end of this message), on the "SearchProductHandler" can recognize. Strange! Please help 2006-06-14 23:56:18,390 WARN [org.directwebremoting.servlet.UrlProcessor] Stack Trace: java.lang.SecurityException: No class by name: ProductDetail at org.directwebremoting.impl.DefaultCreatorManager.getCreator(DefaultCreatorManager.java:165) at org.directwebremoting.impl.DefaultRemoter.generateInterfaceScript(DefaultRemoter.java:60) at org.directwebremoting.servlet.UrlProcessor.handle(UrlProcessor.java:118) at org.directwebremoting.servlet.DwrServlet.doPost(DwrServlet.java:188) at org.directwebremoting.servlet.DwrServlet.doGet(DwrServlet.java:175) at javax.servlet.http.HttpServlet.service(HttpServlet.java:697) at javax.servlet.http.HttpServlet.service(HttpServlet.java:810) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) at org.jboss.web.tomcat.security.CustomPrincipalValve.invoke(CustomPrincipalValve.java:54) at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:174) at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112) at java.lang.Thread.run(Thread.java:595) The following is my code: mport org.directwebremoting.annotations.Convert; import org.directwebremoting.annotations.RemoteProperty; @Convert public class ProductDetail { private String description; public ProductDetail() { super(); // TODO Auto-generated constructor stub } @RemoteProperty public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } } web.xml definition. <servlet> <servlet-name>dwr-invoker</servlet-name> <display-name>DWR Servlet</display-name> <description>Direct Web Remoter Servlet</description> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>false</param-value> </init-param> <init-param> <param-name>classes</param-name> <param-value> mo.reales.portlet.product.ProductForm, mo.reales.portlet.product.ProductDetail, mo.reales.portlet.product.SearchResult, mo.reales.portlet.product.SearchProductHandler </param-value> </init-param> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>dwr-invoker</servlet-name> <url-pattern>/dwr/*</url-pattern> </servlet-mapping>

Previous Message by Thread: click to view message preview

Re: RE: DWR 2.0.x and WebSphere 6.0

Hi Joe,Just wanted to know if we have the fix for this issue in CVS. I tried getting latest from CVS and building dwr.jar with jdk1.3 and jdk1.5, but its not working on Webshpere 6. and giving same errors as in the first case.Thanks and regards,Sandesh0000002c ServletWrappe E   SRVE0100E: Did not realize  init() exception thrown by servlet dwr-invoker: java.lang.LinkageError: LinkageError while defining class: org.directwebremoting.annotations.AnnotationsConfiguratorCould not be defined due to: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)This is often caused by having a class defined at multiplelocations within the classloader hierarchy.  Other potential causesinclude compiling against an older or newer version of the classthat has an incompatible method signature. Dumping the current context classloader hierarchy:    ==> indicates defining classloader==>[0]com.ibm.ws.classloader.CompoundClassLoader@70882284   Delegation Mode: PARENT_FIRST   [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:  Delegation mode: PARENT_FIRST   [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286   [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287   [4] sun.misc.Launcher$AppClassLoader@63a4a287    [5] sun.misc.Launcher$ExtClassLoader@63a0a287---Original exception---java.lang.UnsupportedClassVersionError: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)     at java.lang.ClassLoader.defineClass0(Native Method)    at java.lang.ClassLoader.defineClass(ClassLoader.java(Compiled Code))    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java(Compiled Code))     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass (CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName(LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init (DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest (WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest (WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:421)     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)--- end Original exception----     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName (LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest (ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest (VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination (HttpInboundLink.java:421)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java :94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)----- Original Message ----From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>To: users-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxSent: Thursday, May 25, 2006 5:01:52 PMSubject: Re: [dwr-user] RE: DWR 2.0.x and WebSphere 6.0Can I just take a moment to say ouch?Websphere is throwing an exception (UnsupportedClassVersionError to beaccurate) that we *can't* catch using:  catch (UnsupportedClassVersionError ex) { ...}Surely this *has* to be a bug in Websphere? Does anyone have any comments - bug?Joe.On 5/25/06, sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx < sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: Hi Joe,Thanks for your efforts on this! I tried the new dwr.jar given by you and its working fine. I am attaching the log for your reference. Please let me know once you commit these changes so that we can get a nightly build or may be a new version you might be planning for.Thanks and regards,Sandesh----- Original Message ---- From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>To: users-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxSent: Wednesday, May 24, 2006 10:54:56 AMSubject: Re: [dwr-user] RE: DWR 2.0.x and WebSphere 6.0So the exception is being throw and not caught for some reason?! Maybe this is a very very very very nasty classpath problem where the UnsupportedClassVersionError being thrown is loaded from a different classloader than the one I'm trying to catch. Yuck. I've created you a special version of dwr that contains some code to trap this, please could you tell me what happens with this one?Joe.On 5/19/06, sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx < sandesh_more-/E1597aS9LQAvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: Hi Joe,I checked with the latest code and the lines are same.>In DwrServlet line 124 you should have:>>            catch (UnsupportedClassVersionError ex)>            {>                // This will happen in JDK 1.4 and below>>               handleAnnotationFailure(delayedIOException);>            }This issue is  not solved yet.Please see below for the complete stack trace.[5/11/06 10:21:13:138 IST] 0000002c ServletWrappe E   SRVE0100E: Did not realize  init() exception thrown by servlet dwr-invoker: java.lang.LinkageError: LinkageError while defining class: org.directwebremoting.annotations.AnnotationsConfiguratorCould not be defined due to: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)This is often caused by having a class defined at multiplelocations within the classloader hierarchy.  Other potential causesinclude compiling against an older or newer version of the classthat has an incompatible method signature. Dumping the current context classloader hierarchy:    ==> indicates defining classloader==>[0]com.ibm.ws.classloader.CompoundClassLoader@70882284   Delegation Mode: PARENT_FIRST   [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:  Delegation mode: PARENT_FIRST   [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286   [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287   [4] sun.misc.Launcher$AppClassLoader@63a4a287    [5] sun.misc.Launcher$ExtClassLoader@63a0a287---Original exception---java.lang.UnsupportedClassVersionError: org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported major.minor version 49.0)     at java.lang.ClassLoader.defineClass0(Native Method)    at java.lang.ClassLoader.defineClass(ClassLoader.java(Compiled Code))    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java(Compiled Code))     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass (CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName(LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init (DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest (WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest (WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:421)     at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)--- end Original exception----     at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))    at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code))    at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))    at org.directwebremoting.util.LocalUtil.classForName (LocalUtil.java:582)    at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:118)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:262)    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest (ServletWrapper.java:444)    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2841)    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)    at com.ibm.ws.webcontainer.VirtualHost.handleRequest (VirtualHost.java:204)    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination (HttpInboundLink.java:421)    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java :94)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun (WorkQueueManager.java:934)    at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)   Date: Mon, 15 May 2006 19:03:32 +0100 From: Joe Walker <joseph.walker-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx>Content-Type: multipart/alternative;         boundary="----=_Part_15566_7929908.1147716212752"Subject: [dwr-user] Re: DWR 2.0.x and WebSphere 6.0  In DwrServlet line 124 you should have:            catch (UnsupportedClassVersionError ex)            {                // This will happen in JDK 1.4 and below                handleAnnotationFailure(delayedIOException);             }If you don't please sync with CVS again.If you do, please could you post me a stack trace, or even better debug tofind out how this is happening?Thanks.Joe On 5/13/06, Sandesh More < sandeshmore-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote:>> Joe,> I tried to get the latest of the CVS 2 days back to try the solution of > this> DWR2.0 and Websphere 6.0 issue but I am still getting follwoing errors>> [5/11/06 10:21:13:138 IST] 0000002c ServletWrappe E   SRVE0100E: Did not> realize> init() exception thrown by servlet dwr-invoker: java.lang.LinkageError :> LinkageError while defining class:> org.directwebremoting.annotations.AnnotationsConfigurator> Could not be defined due to:> org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported > major.minor version 49.0)> This is often caused by having a class defined at multiple> locations within the classloader hierarchy.  Other potential causes> include compiling against an older or newer version of the class > that has an incompatible method signature.> Dumping the current context classloader hierarchy:>     ==> indicates defining classloader> ==>[0]> com.ibm.ws.classloader.CompoundClassLoader@70882284 >    Delegation Mode: PARENT_FIRST>    [1] com.ibm.ws.classloader.JarClassLoader@1217536644 Local Classpath:> Delegation mode: PARENT_FIRST>    [2] com.ibm.ws.classloader.ProtectionClassLoader@1169a286 >    [3] com.ibm.ws.bootstrap.ExtClassLoader@63aee287>    [4] sun.misc.Launcher$AppClassLoader@63a4a287>    [5] sun.misc.Launcher$ExtClassLoader@63a0a287> ---Original exception---> java.lang.UnsupportedClassVersionError :> org/directwebremoting/annotations/AnnotationsConfigurator (Unsupported> major.minor version 49.0)>         at java.lang.ClassLoader.defineClass0(Native Method)>         at java.lang.ClassLoader.defineClass (ClassLoader.java(Compiled> Code))>>> ---------------------------------------------------------------------> To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx > For additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx> >--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxFor additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx ---------------------------------------------------------------------To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxFor additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx ---------------------------------------------------------------------To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx

Next Message by Thread: click to view message preview

Re: Complex/nested bean parameter getting errors

The trick, I expect is on this line: java.lang.InstantiationException: com.ihg.peopledb.admin.PersonDoes com.ihg.peopledb.admin.Person have a public constructor?Joe On 6/14/06, Brian A Dillon <brianadillon-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: Hello,I am successfully receiving a complex bean/POJO at the client but amgetting errors in trying to marshall/pass the _javascript_representation back to a remoted method on the server. The specificerror is uk.ltd.getahead.dwr.ConversionException: Error converting parameters for call to PersonController.updatePerson: com.ihg.peopledb.admin.Person        at uk.ltd.getahead.dwr.impl.ExecuteQuery.execute(ExecuteQuery.java :139)        at uk.ltd.getahead.dwr.impl.DefaultExecProcessor.handle(DefaultExecProcessor.java:48)        at uk.ltd.getahead.dwr.impl.DefaultProcessor.handle(DefaultProcessor.java:83)        at uk.ltd.getahead.dwr.AbstractDWRServlet.doPost (AbstractDWRServlet.java:162)        at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter (ApplicationFilterChain.java:252)        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV alve.java:213)        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)        at org.apache.catalina.connector.CoyoteAdapter.service (CoyoteAdapter.java:148)        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection( Http11Protocol.java:744)        at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)        at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java :80)        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)        at java.lang.Thread.run(Unknown Source)Caused by: uk.ltd.getahead.dwr.ConversionException: com.ihg.peopledb.admin.Perso n        at uk.ltd.getahead.dwr.convert.BeanConverter.convertInbound(BeanConverter.java:262)        at uk.ltd.getahead.dwr.impl.DefaultConverterManager.convertInbound(DefaultConverterManager.java:162)         at uk.ltd.getahead.dwr.impl.ExecuteQuery.execute(ExecuteQuery.java:135)        ... 19 moreCaused by: java.lang.InstantiationException: com.ihg.peopledb.admin.Person        at java.lang.Class.newInstance0 (Unknown Source)        at java.lang.Class.newInstance(Unknown Source)        at uk.ltd.getahead.dwr.convert.BeanConverter.convertInbound(BeanConverter.java:180)        ... 21 more- Erroring: id[7307_1150297539329] message[ uk.ltd.getahead.dwr.OutboundVariable@d93a3f]Here is the setup:##### dwr.xml<dwr>  <allow>    <create creator="new" _javascript_="SearchController">       <param name="class" value="com.ihg.peopledb.admin.SearchController"/>    </create>    <create creator="new" _javascript_="PersonController">      <param name="class" value=" com.ihg.peopledb.admin.PersonController"/>    </create>    <convert converter="bean" match="com.ihg.peopledb.admin.PersonListItem"/>    <convert converter="bean" match=" com.ihg.peopledb.admin.Person"/>    <convert converter="bean" match="com.ihg.peopledb.admin.Location"/>    <convert converter="bean" match="com.ihg.peopledb.admin.Contact "/>  </allow></dwr>######## JSP<%-- DWR scripts --%><script type='text/_javascript_'src=''></script><script type='text/_javascript_' src=''></script><script type='text/_javascript_' src=''></script><script type='text/_javascript_' src=''></script> ...var person = { locs:null, contacts:null, personID:-1, salutation:null,firstName:null, middleName:null,        lastName:null, suffixName:null, localName:null, prefName:null,picture:null, employeeID:null, userID:null,         email:null, dob:null, lang1:null, lang2:null, gender:null, ethnicGroup:null,        ethnicOrigin:null, sourceSys:null, sourceSysID:null, userStatus:null,primaryLoc:-1,        primaryContact:-1, lastUpdate:null, dept:null, userType:null, workGroup:null }; ...function updatePerson() {  PersonController.updatePerson(setStatusResult, person);}######### Person.java...import com.ihg.peopledb.admin.Location;import com.ihg.peopledb.admin.Contact ;public class Person {        private static Context ctx = null;        private static Context envCtx = null;        private static DataSource ds = null;        // maps to store person's location(s) and contact(s)         private Map locs = new TreeMap();        private Map contacts = new TreeMap();        // from PERSON table        private int personID =-1;        private String salutation = null;        private String firstName = null;         private String middleName = null;        private String lastName = null;        private String suffixName = null;        private String localName = null; // unicode value        private String prefName = null;         private String picture = null;        private String employeeID = null;        private String userID = null;        private String email = null;        private Date dob = null;        private String lang1 = null;         private String lang2 = null;        private String gender = null;        private String ethnicGroup = null;        private String ethnicOrigin = null;        private String sourceSys = null;         private String sourceSysID = null;        private String userStatus = null;        // stores IDs of primary location record and contact record respectively        private int primaryLoc= -1;        private int primaryContact = -1;         private Date lastUpdate = null;        //...        // getters working fine!        // setters not working        public void setID(int personID) {                this.personID = personID;         }        public void setSalutation(String salutation) {                this.salutation = salutation;        }        //....        public void setLocs(Map locs) {                 this.locs.putAll(locs);        }        public void setContacts(Map contacts) {                this.contacts.putAll(contacts);        }}#####Note that I have different additional attributes in my _javascript_ object than I do in my Java POJO - and vice versa. But, I only havesetters on the POJO for the attributes that match. Does the _javascript_object need to match exactly to the attributes in the POJO? Do I need signatures for the "locs" and "contacts" parameters? They themselvesare POJOs which are setup as bean converters per above. I have NOT putgetters/setters on the Location and Contact POJO as I did not need them for the "retrieval" but I now guess I need them in order to setit correct? I would appreciate any help as I'm sure it is aconfig/signature issue.Thanks!!Brian--------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxxFor additional commands, e-mail: users-help-EyPigyGktj4FDOXUYO6UHQ@xxxxxxxxxxxxxxxx
Sign up for updates to this mailing list. email:
Loading Comments...
Home | News | Patents | Sitemap | FAQ | advertise

Advertising by