Interesting, I'm also migrating to Wicket 1.5 with GAE

First a comment: In addition to what you mention I had to change the default
HeaderRenderStrategy to
org.apache.wicket.markup.renderStrategy.ParentFirstHeaderRenderStrategy
 since it's rendering the child headers before parents and that doesn't work
for me. I tried reverting the call order in renderHead() but didn't work.

Now a question:
Did you use Ajax? .

I'm getting the following error and I don't know what could be the problem
(I'm a wicket newbie :S )

Last cause: STREAMED
WicketMessage: Method onRequest of interface
org.apache.wicket.behavior.IBehaviorListener targeted at
org.apache.wicket.ajax.markup.html.form.AjaxButton$1@161b0bc on
component [ [Component id = postCommentButton]] threw an exception

Root cause:

java.lang.IllegalStateException: STREAMED
     at org.mortbay.jetty.Request.getReader(Request.java:935)
     at 
org.apache.wicket.protocol.http.servlet.ServletWebRequest.generatePostParameters(ServletWebRequest.java:250)
     at 
org.apache.wicket.protocol.http.servlet.ServletWebRequest.getPostRequestParameters(ServletWebRequest.java:294)
     at 
org.apache.wicket.protocol.http.servlet.ServletWebRequest.access$000(ServletWebRequest.java:60)
     at 
org.apache.wicket.protocol.http.servlet.ServletWebRequest$1.getParameterValues(ServletWebRequest.java:331)
     at 
org.apache.wicket.request.parameter.CombinedRequestParametersAdapter.getParameterValues(CombinedRequestParametersAdapter.java:88)
     at 
org.apache.wicket.markup.html.form.FormComponent.getInputAsArray(FormComponent.java:702)
     at 
org.apache.wicket.markup.html.form.FormComponent.inputChanged(FormComponent.java:871)
     at org.apache.wicket.markup.html.form.Form$9.component(Form.java:1045)
     at org.apache.wicket.markup.html.form.Form$9.component(Form.java:1041)
     at 
org.apache.wicket.util.visit.Visits.visitPostOrderHelper(Visits.java:274)
     at 
org.apache.wicket.util.visit.Visits.visitPostOrderHelper(Visits.java:263)
     at 
org.apache.wicket.util.visit.Visits.visitPostOrderHelper(Visits.java:263)
     at org.apache.wicket.util.visit.Visits.visitPostOrder(Visits.java:246)
     at 
org.apache.wicket.markup.html.form.FormComponent.visitFormComponentsPostOrder(FormComponent.java:344)
     at 
org.apache.wicket.markup.html.form.Form.visitFormComponentsPostOrder(Form.java:980)
     at org.apache.wicket.markup.html.form.Form.inputChanged(Form.java:1039)
     at org.apache.wicket.markup.html.form.Form.onFormSubmitted(Form.java:706)
     at 
org.apache.wicket.ajax.form.AjaxFormSubmitBehavior.onEvent(AjaxFormSubmitBehavior.java:148)
     at 
org.apache.wicket.ajax.AjaxEventBehavior.respond(AjaxEventBehavior.java:166)
     at 
org.apache.wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:300)
     at java.lang.reflect.Method.invoke(Method.java:616)
     at 
com.google.appengine.tools.development.agent.runtime.Runtime.invoke(Runtime.java:100)
     at 
org.apache.wicket.RequestListenerInterface.internalInvoke(RequestListenerInterface.java:259)
     at 
org.apache.wicket.RequestListenerInterface.invoke(RequestListenerInterface.java:240)
     at 
org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.invokeListener(ListenerInterfaceRequestHandler.java:178)
     at 
org.apache.wicket.request.handler.ListenerInterfaceRequestHandler.respond(ListenerInterfaceRequestHandler.java:157)
     at 
org.apache.wicket.request.RequestHandlerStack.executeRequestHandler(RequestHandlerStack.java:84)
     at 
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:205)
     at 
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:247)
     at 
org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:138)


Thanks!


On Sun, Feb 13, 2011 at 4:25 PM, Per <p...@hamburg.de> wrote:

>
> Hi Martin,
>
> yes, I used your utility, it was great to get me started!  Funny enough,
> I had prepared several questions (which I then ended up answering by
> myself and never posted), and in each of them I was referring to your
> utility. Almost asked you directly, but figured it out before I did.
> I'll make sure it's mentioned in the overall summary once I am through
> with this.
>
>
> Two items maybe worth mentioning already, since you asked: If you use
> the always-on feature in GAE, there's a much higher chance that your
> session gets deserialised on a node that was not in use yet. You get an
> exception like this:
>
>
> Caused by: java.lang.IllegalStateException: PageManager for application
> quickstart not registered.
>     at
>
> org.apache.wicket.page.MyPersistentPageManager$SessionEntry.getPageStore(MyPersistentPageManager.java:117)
>     at
>
> org.apache.wicket.page.MyPersistentPageManager$SessionEntry.readObject(MyPersistentPageManager.java:292)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>     at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>     at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>     at java.lang.reflect.Method.invoke(Method.java:616)
>     at
> java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:991)
>     at
> java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1865)
>     at
> java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1770)
>
> (Ignore the row numbers, that's just my version of the PPM)
>
> It can also happen with a single node of course, but it really hit me
> often when run with always-on enabled. I added a simple
> "getPageManager();" call right into the init() of the application, and
> that seems to do the trick for me.
>
> Also, since the PersistentPageManager's isReplicated() returns "true",
> the DefaultPageStore's prepareForSerialization() always keeps putting
> null page objects into the session. This results in a NPE in the
> PersistentPageManager's SessionEntry's findPage(), so I added a
> null-check there:
>
>     private IManageablePage findPage(int id)
>         {
>             for (IManageablePage p : pages)
>             {
>                 if (p==null) {
>                     log.info("sigh, a null page");
>                 }
>                 else if (p.getPageId() == id)
>                 {
>                     return p;
>                 }
>             }
>             return null;
>         }
>
>
> To be honest, I have no idea why this works at all, given that every
> page put into the session is null. But when I tried returning "false" in
> isReplicated() in order to make it actually serialise things, it became
> a HUGE mess. But then again that might also be related to that I was at
> that time trying to use the default page render strategy. It seems that
> 1.5 on App Engine doesn't work at all with the default, so I used
>
>
>
> getRequestCycleSettings().setRenderStrategy(IRequestCycleSettings.RenderStrategy.REDIRECT_TO_RENDER);
>
> I had been using that render-strategy in 1.4 as well. Since it still
> works (and the other doesn't) I guess that's the one for me.
>
>
> Cheers,
> Per
>
>
>
>
> > Hi,
> >
> > On Sun, Feb 13, 2011 at 6:39 PM, Per <[hidden email]
> > </user/SendEmail.jtp?type=node&node=3303934&i=0>> wrote:
> >
> > >
> > > Hello fellow Wicketeers,
> > >
> > > I have pretty much completed upgrading my application to Wicket 1.5
> > RC1. I
> > > have rolled it out onto my QA system on Google App Engine, and
> > except for
> > > some minor glitches in PersistentPageManager and PageManager (which
> > I'll
> > > document later on) it was a rather uncomplicated upgrade. Not that
> > the API
> > > changes were fun to work through, but I've seen much much worse
> > upgrades in
> > > my life, so thanks for another awesome Wicket release guys!!
> > >
> >
> > Did you use
> >
> https://github.com/wicketstuff/core/tree/master/jdk-1.5-parent/gae-initializer-parentby
> > chance ?
> > If not, then please take a look at GaeInitializer.java and tell us
> > what else
> > did you need to tweak.
> >
> > >
> > > Wicket 1.5 solves some issues 1.4 had on App Engine (multi tab support,
> > > back
> > > button, lack of control of the session size), so I feel even a mere
> > Release
> > > Candidate is better than the stable 1.4.x releases. I am busy
> > testing the
> > > app now, and I would really like to roll it out soon.
> > >
> > > Unless!! I do wonder if there are maybe any showstoppers I didn't learn
> > > about yet. I checked JIRA of course, and nothing in RC2 seems to
> > blocking
> > > me. I couldn't find RC3 nor any issues in 1.5.0.
> > >
> >
> > I also don't know of any stoppers.
> >
> > >
> > > So what do you think, yay or nay for putting RC1 into production
> > this week?
> > >
> > If you don't find any issues in your testing then I'm 'yay'.
> >
> > Please report if you find something and we will try to fix it as soon as
> > possible!
> >
> > >
> > > Cheers,
> > > Per
> > >
> > > --
> > > View this message in context:
> > >
> >
> http://apache-wicket.1842946.n4.nabble.com/Vote-Veto-Should-I-put-1-5-RC1-on-App-Engine-into-production-this-week-tp3303781p3303781.html
> > <
> http://apache-wicket.1842946.n4.nabble.com/Vote-Veto-Should-I-put-1-5-RC1-on-App-Engine-into-production-this-week-tp3303781p3303781.html?by-user=t
> >
> > > Sent from the Users forum mailing list archive at Nabble.com.
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [hidden email]
> > </user/SendEmail.jtp?type=node&node=3303934&i=1>
> > > For additional commands, e-mail: [hidden email]
> > </user/SendEmail.jtp?type=node&node=3303934&i=2>
> > >
> > >
> >
> >
> > ------------------------------------------------------------------------
> > If you reply to this email, your message will be added to the
> > discussion below:
> >
> http://apache-wicket.1842946.n4.nabble.com/Vote-Veto-Should-I-put-1-5-RC1-on-App-Engine-into-production-this-week-tp3303781p3303934.html
> >
> > To unsubscribe from Vote/Veto: Should I put 1.5 RC1 on App Engine into
> > production this week?, click here
> > <
> http://apache-wicket.1842946.n4.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=3303781&code=cGVyQGhhbWJ1cmcuZGV8MzMwMzc4MXwtMjI2MTAwMzE0
> >.
> >
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Vote-Veto-Should-I-put-1-5-RC1-on-App-Engine-into-production-this-week-tp3303781p3303969.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>

Reply via email to