John, Thanks for the reply. As I mentioned, there seems to be multiple issues - what do I make an issue on?
Also, will appreciate if you can share some thoughts on going about fixing it. Johan Compagner wrote: > > Make a jira issue with a sample quickstart > > On 4/29/08, Ritz123 <[EMAIL PROTECTED]> wrote: >> >> Hi, >> >> After spending quiet a few hours on PageParameter mystery I think its >> time >> to get experts help. >> >> I have a few Bookmarkable pages with MixedParamStrategy set - this means >> I >> have few fixed parameters and few optional params. What is happening is, >> somewhere in my code (digging as we speak) one of the optional parameters >> is >> getting a default value of "false" in the URL. Here is the discrete URL >> thats failing >> http://localhost:8080/mfg/Polycom/POLYCOM/133/?isAnd=false where mfg is >> the >> mount path, Polycom is mfg name, POLYCOM is mfg id and 133 is category id >> - >> all of these are obviously Fixed parameters for MixedParamStrategy and >> isAnd >> which is an optional param getting set to default false and is part of >> the >> URL. >> >> What seems to be happening is, somehow the parametermap is storing >> "isAnd" >> is an array of strings instead of just string and hence >> MixedParameterUrlCodingStrategy.appendParameter (line 153of wicket 1.3.X) >> fails with the ClassCastException and yet the length of the array is only >> 1 >> so there is no reason to convert an existing String param to String array >> - >> but somehow that is what is happening. >> >> I put some debugging statements in the ValueMap.java to see who is >> setting >> it as String array - and here is the stack trace I get (see below) >> >> This actually brings up multiple questions why cant >> mixedparamurlcodingstragy handle multiple values etc. but that is not >> important in my case - since I will always have 1 value for now. But just >> wondering what if I had multi select boxes etc. >> >> Will appreciate any pointers. >> >> >> java.lang.RuntimeException: =============> ValueMap.putall....... putting >> isand with array >> at org.apache.wicket.util.value.ValueMap.putAll(ValueMap.java:494) >> at >> org.apache.wicket.request.target.coding.MixedParamUrlCodingStrategy.decodeParameters(MixedParamUrlCodingStrategy.java:189) >> at >> org.apache.wicket.request.target.coding.BookmarkablePageRequestTargetUrlCodingStrategy.decode(BookmarkablePageRequestTargetUrlCodingStrategy.java:76) >> at >> org.apache.wicket.protocol.http.request.WebRequestCodingStrategy.targetForRequest(WebRequestCodingStrategy.java:475) >> at >> org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:175) >> at org.apache.wicket.RequestCycle.step(RequestCycle.java:1227) >> at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1347) >> at org.apache.wicket.RequestCycle.request(RequestCycle.java:496) >> at >> org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:375) >> at >> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:199) >> at >> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215) >> at >> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188) >> at >> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210) >> at >> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174) >> at >> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) >> at >> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117) >> at >> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108) >> at >> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:542) >> at >> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151) >> at >> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870) >> at >> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665) >> at >> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528) >> at >> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81) >> at >> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685) >> at java.lang.Thread.run(Thread.java:595) >> >> >> -- >> View this message in context: >> http://www.nabble.com/PageParameter-mysetry---need-help-tp16966154p16966154.html >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > -- View this message in context: http://www.nabble.com/PageParameter-mystery---need-help-tp16966154p16969397.html Sent from the Wicket - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
