Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-13 Thread nino martinez wael
Sure, I was not so much thinking of me but other wicket users.. I've asked
around and at least here its not a "normal" wicket behavior that you could
break something by calling target.add(component).. And its not that I do
not want the error message, just to make it a little more clear to the
developer on whats wrong.. Not many would know that by calling target.add
you are breaking art because of internals of the tree..

A more pragmatic solution could also just to write in the java doc that
calling target.add + having expand in the  newContentComponent method are a
no go and will break runtime.

right now expand java doc are just "Expand the given node, tries to update
the affected branch if the change happens on an AjaxRequestTarget
<https://ci.apache.org/projects/wicket/apidocs/6.x/org/apache/wicket/ajax/AjaxRequestTarget.html>
."


regards Nino

On Tue, Dec 11, 2018 at 10:02 PM Sven Meier  wrote:

> Hi Nino,
>
> I've expanded the error message for now.
>
> We could make that method on NestedTree lenient, i.e. catch the
> exception and log the message instead.
> But you could do that for yourself in your code too.
>
> Have fun
> Sven
>
> Am 10.12.18 um 11:16 schrieb nino martinez wael:
> > I agree, i just find the error message strange.. Normally if i add an
> > component with target.add it does not break.. If it breaks and we know it
> > breaks maybe an warning or error message should come from the tree that
> it
> > cannot have expand in new component on ajax requests..
> >
> >
> >
> > Ps typing iæon phone
> >
> > On Mon, 10 Dec 2018, 11:04 Sven Meier,  wrote:
> >
> >> Hi,
> >>
> >> found it:
> >>
> >> - since WICKET-6335 the node content is created in #onInitialize() only
> >> - at this moment the node is already inside the component hierarchy
> >> - #updateBranch() finds the branch of the currently rendered node and
> >> tries to add it to the ART
> >> -> "Components can no  longer be added"
> >>
> >> Compare this with 7.x:
> >>
> >> - the node content is created directly from the constructor
> >> - at this moment the node (and its parental branch) is not in the
> >> component hierarchy yet
> >> - #updateBranch() does not find any branch for the node's model and
> >> doesn't add anything to the ART
> >>
> >> So yes, we have a change, but no bug. In 7.x adding of the branch to the
> >> ART was just ignored.
> >>
> >> You can achieve the same in Wicket 8.x with the following:
> >>
> >>   protected Component newContentComponent(String id,
> >> IModel node) {
> >>   if(haveClicked){
> >>   // #expand() can not be used, since it tries to
> add
> >> the branch
> >>   // to the ART, which is not allowed during
> rendering
> >>   getModelObject().add(node.getObject());
> >>   }
> >>   return super.newContentComponent(id, node);
> >>   }
> >>
> >> Have fun
> >> Sven
> >>
> >> Am 10.12.18 um 08:41 schrieb nino martinez wael:
> >>> I have replicated it here, I found the error a little counter
> intuitive:
> >>>
> >>>
> >>
> https://github.com/nmwael/wicket/blob/master/wicket-examples/src/main/java/org/apache/wicket/examples/tree/BeginnersTreePage.java
> >>> On Fri, Dec 7, 2018 at 5:48 PM Sven Meier  wrote:
> >>>
> >>>> Hi,
> >>>>
> >>>> the stacktrace shows clearly that you add a component to the ART while
> >>>> it is already rendering the response.
> >>>> This is not allowed, and this wasn't allowed in previous version.
> >>>>
> >>>> You'll have to provide a quickstart to prove that it worked
> previously.
> >>>>
> >>>> Regards
> >>>> Sven
> >>>>
> >>>> Am 06.12.18 um 13:50 schrieb nino martinez wael:
> >>>>> @svenme...@apache.com  what/how do I need to
> >> check
> >>>>> during the call? For now I have a breakpoint the place in the code
> >> where
> >>>> it
> >>>>> fails, but I need to figure out what closes the request target..
> >>>>>
> >>>>> On Mon, Dec 3, 2018 at 10:55 AM nino martinez wael <
> >>>>> nino.martinez.w...@gmail.com> wrote:
> >>>>>
> >>

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-11 Thread Sven Meier

Hi Nino,

I've expanded the error message for now.

We could make that method on NestedTree lenient, i.e. catch the 
exception and log the message instead.

But you could do that for yourself in your code too.

Have fun
Sven

Am 10.12.18 um 11:16 schrieb nino martinez wael:

I agree, i just find the error message strange.. Normally if i add an
component with target.add it does not break.. If it breaks and we know it
breaks maybe an warning or error message should come from the tree that it
cannot have expand in new component on ajax requests..



Ps typing iæon phone

On Mon, 10 Dec 2018, 11:04 Sven Meier,  wrote:


Hi,

found it:

- since WICKET-6335 the node content is created in #onInitialize() only
- at this moment the node is already inside the component hierarchy
- #updateBranch() finds the branch of the currently rendered node and
tries to add it to the ART
-> "Components can no  longer be added"

Compare this with 7.x:

- the node content is created directly from the constructor
- at this moment the node (and its parental branch) is not in the
component hierarchy yet
- #updateBranch() does not find any branch for the node's model and
doesn't add anything to the ART

So yes, we have a change, but no bug. In 7.x adding of the branch to the
ART was just ignored.

You can achieve the same in Wicket 8.x with the following:

  protected Component newContentComponent(String id,
IModel node) {
  if(haveClicked){
  // #expand() can not be used, since it tries to add
the branch
  // to the ART, which is not allowed during rendering
  getModelObject().add(node.getObject());
  }
  return super.newContentComponent(id, node);
  }

Have fun
Sven

Am 10.12.18 um 08:41 schrieb nino martinez wael:

I have replicated it here, I found the error a little counter intuitive:



https://github.com/nmwael/wicket/blob/master/wicket-examples/src/main/java/org/apache/wicket/examples/tree/BeginnersTreePage.java

On Fri, Dec 7, 2018 at 5:48 PM Sven Meier  wrote:


Hi,

the stacktrace shows clearly that you add a component to the ART while
it is already rendering the response.
This is not allowed, and this wasn't allowed in previous version.

You'll have to provide a quickstart to prove that it worked previously.

Regards
Sven

Am 06.12.18 um 13:50 schrieb nino martinez wael:

@svenme...@apache.com  what/how do I need to

check

during the call? For now I have a breakpoint the place in the code

where

it

fails, but I need to figure out what closes the request target..

On Mon, Dec 3, 2018 at 10:55 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


I've debugged a lot further. But still unable to pinpoint it.. For now
I've switched to rendering the full page instead, which of course

works.

We are a couple of things in conjunction with TREE, like wicket jquery

ui

draggable and droppable.. We also have a custom loading mechanism that

pops

a veil if the request are too long to load.. And some custom form

handling

aswell (auto show an marker for error'd form fields)..

PS writing this for other to see, if they hit  this challenge..

-Regards Nino


On Thu, Nov 29, 2018 at 8:50 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


currently unable to reproduce in examples, something must be wrong in

my

code..

I'll comeback if it turns out otherwise..

Thanks for helping :)

On Thu, Nov 29, 2018 at 6:54 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


Yes I understand.. Let me see if it breaks in wicket examples, or I

can

make it so.. Do you know another way to make a node/folder expand

during

construction time? Feels like the expand method are meant for ajax

calls

only.

-regards Nino

On Wed, Nov 28, 2018 at 4:16 PM sven  wrote:


Hi Nino,



during rendering of components no additional components can be

added

to

the ART any more.

I surprised that your code worked in 6.x, can you build a

quickstart

demonstrating the problem?



Have fun

Sven










On 28.11.2018 at 14:38,wrote:


Hi In wicket 6 this worked, there are another input field (ajax

activated) that triggers the update : ChildAwareNestedTree
profilePartitionTree = new ChildAwareNestedTree("skillsetSelect",

provider,

sharedExpansionState) { @Override protected Component
newContentComponent(String id, IModel model) { TreeNode node =
model.getObject(); if (node instanceof

TreeNodeProvider.PartitionNode) {

Partition partition = ((TreeNodeProvider.PartitionNode)
node).getPartition(); if
(getPartitionsWithProfiles().containsKey(partition.getId())) {*
expand(node);* } } else if (node instanceof
TreeNodeProvider.NoPartitionNode  &&

isNoPartitionProfilesPresent()) {*

expand(node);* } } The triggering field: searchTerm.add(new
AjaxFormComponentUpdatingBehavior("keydown") { @Override protected

void

onUpdate

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-10 Thread nino martinez wael
I agree, i just find the error message strange.. Normally if i add an
component with target.add it does not break.. If it breaks and we know it
breaks maybe an warning or error message should come from the tree that it
cannot have expand in new component on ajax requests..



Ps typing iæon phone

On Mon, 10 Dec 2018, 11:04 Sven Meier,  wrote:

> Hi,
>
> found it:
>
> - since WICKET-6335 the node content is created in #onInitialize() only
> - at this moment the node is already inside the component hierarchy
> - #updateBranch() finds the branch of the currently rendered node and
> tries to add it to the ART
> -> "Components can no  longer be added"
>
> Compare this with 7.x:
>
> - the node content is created directly from the constructor
> - at this moment the node (and its parental branch) is not in the
> component hierarchy yet
> - #updateBranch() does not find any branch for the node's model and
> doesn't add anything to the ART
>
> So yes, we have a change, but no bug. In 7.x adding of the branch to the
> ART was just ignored.
>
> You can achieve the same in Wicket 8.x with the following:
>
>  protected Component newContentComponent(String id,
> IModel node) {
>  if(haveClicked){
>  // #expand() can not be used, since it tries to add
> the branch
>  // to the ART, which is not allowed during rendering
>  getModelObject().add(node.getObject());
>  }
>  return super.newContentComponent(id, node);
>  }
>
> Have fun
> Sven
>
> Am 10.12.18 um 08:41 schrieb nino martinez wael:
> > I have replicated it here, I found the error a little counter intuitive:
> >
> >
> https://github.com/nmwael/wicket/blob/master/wicket-examples/src/main/java/org/apache/wicket/examples/tree/BeginnersTreePage.java
> >
> > On Fri, Dec 7, 2018 at 5:48 PM Sven Meier  wrote:
> >
> >> Hi,
> >>
> >> the stacktrace shows clearly that you add a component to the ART while
> >> it is already rendering the response.
> >> This is not allowed, and this wasn't allowed in previous version.
> >>
> >> You'll have to provide a quickstart to prove that it worked previously.
> >>
> >> Regards
> >> Sven
> >>
> >> Am 06.12.18 um 13:50 schrieb nino martinez wael:
> >>> @svenme...@apache.com  what/how do I need to
> check
> >>> during the call? For now I have a breakpoint the place in the code
> where
> >> it
> >>> fails, but I need to figure out what closes the request target..
> >>>
> >>> On Mon, Dec 3, 2018 at 10:55 AM nino martinez wael <
> >>> nino.martinez.w...@gmail.com> wrote:
> >>>
> >>>> I've debugged a lot further. But still unable to pinpoint it.. For now
> >>>> I've switched to rendering the full page instead, which of course
> works.
> >>>>
> >>>> We are a couple of things in conjunction with TREE, like wicket jquery
> >> ui
> >>>> draggable and droppable.. We also have a custom loading mechanism that
> >> pops
> >>>> a veil if the request are too long to load.. And some custom form
> >> handling
> >>>> aswell (auto show an marker for error'd form fields)..
> >>>>
> >>>> PS writing this for other to see, if they hit  this challenge..
> >>>>
> >>>> -Regards Nino
> >>>>
> >>>>
> >>>> On Thu, Nov 29, 2018 at 8:50 AM nino martinez wael <
> >>>> nino.martinez.w...@gmail.com> wrote:
> >>>>
> >>>>> currently unable to reproduce in examples, something must be wrong in
> >> my
> >>>>> code..
> >>>>>
> >>>>> I'll comeback if it turns out otherwise..
> >>>>>
> >>>>> Thanks for helping :)
> >>>>>
> >>>>> On Thu, Nov 29, 2018 at 6:54 AM nino martinez wael <
> >>>>> nino.martinez.w...@gmail.com> wrote:
> >>>>>
> >>>>>> Yes I understand.. Let me see if it breaks in wicket examples, or I
> >> can
> >>>>>> make it so.. Do you know another way to make a node/folder expand
> >> during
> >>>>>> construction time? Feels like the expand method are meant for ajax
> >> calls
> >>>>>> only.
> >>>>>>
> >>>>>> -regards Nino
> >>>

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-10 Thread Sven Meier

Hi,

found it:

- since WICKET-6335 the node content is created in #onInitialize() only
- at this moment the node is already inside the component hierarchy
- #updateBranch() finds the branch of the currently rendered node and 
tries to add it to the ART

-> "Components can no  longer be added"

Compare this with 7.x:

- the node content is created directly from the constructor
- at this moment the node (and its parental branch) is not in the 
component hierarchy yet
- #updateBranch() does not find any branch for the node's model and 
doesn't add anything to the ART


So yes, we have a change, but no bug. In 7.x adding of the branch to the 
ART was just ignored.


You can achieve the same in Wicket 8.x with the following:

    protected Component newContentComponent(String id, 
IModel node) {

    if(haveClicked){
                    // #expand() can not be used, since it tries to add 
the branch

                    // to the ART, which is not allowed during rendering
        getModelObject().add(node.getObject());
    }
    return super.newContentComponent(id, node);
    }

Have fun
Sven

Am 10.12.18 um 08:41 schrieb nino martinez wael:

I have replicated it here, I found the error a little counter intuitive:

https://github.com/nmwael/wicket/blob/master/wicket-examples/src/main/java/org/apache/wicket/examples/tree/BeginnersTreePage.java

On Fri, Dec 7, 2018 at 5:48 PM Sven Meier  wrote:


Hi,

the stacktrace shows clearly that you add a component to the ART while
it is already rendering the response.
This is not allowed, and this wasn't allowed in previous version.

You'll have to provide a quickstart to prove that it worked previously.

Regards
Sven

Am 06.12.18 um 13:50 schrieb nino martinez wael:

@svenme...@apache.com  what/how do I need to check
during the call? For now I have a breakpoint the place in the code where

it

fails, but I need to figure out what closes the request target..

On Mon, Dec 3, 2018 at 10:55 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


I've debugged a lot further. But still unable to pinpoint it.. For now
I've switched to rendering the full page instead, which of course works.

We are a couple of things in conjunction with TREE, like wicket jquery

ui

draggable and droppable.. We also have a custom loading mechanism that

pops

a veil if the request are too long to load.. And some custom form

handling

aswell (auto show an marker for error'd form fields)..

PS writing this for other to see, if they hit  this challenge..

-Regards Nino


On Thu, Nov 29, 2018 at 8:50 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


currently unable to reproduce in examples, something must be wrong in

my

code..

I'll comeback if it turns out otherwise..

Thanks for helping :)

On Thu, Nov 29, 2018 at 6:54 AM nino martinez wael <
nino.martinez.w...@gmail.com> wrote:


Yes I understand.. Let me see if it breaks in wicket examples, or I

can

make it so.. Do you know another way to make a node/folder expand

during

construction time? Feels like the expand method are meant for ajax

calls

only.

-regards Nino

On Wed, Nov 28, 2018 at 4:16 PM sven  wrote:


Hi Nino,



during rendering of components no additional components can be added

to

the ART any more.

I surprised that your code worked in 6.x, can you build a quickstart
demonstrating the problem?



Have fun

Sven










On 28.11.2018 at 14:38,wrote:


   Hi In wicket 6 this worked, there are another input field (ajax

activated) that triggers the update : ChildAwareNestedTree
profilePartitionTree = new ChildAwareNestedTree("skillsetSelect",

provider,

sharedExpansionState) { @Override protected Component
newContentComponent(String id, IModel model) { TreeNode node =
model.getObject(); if (node instanceof

TreeNodeProvider.PartitionNode) {

Partition partition = ((TreeNodeProvider.PartitionNode)
node).getPartition(); if
(getPartitionsWithProfiles().containsKey(partition.getId())) {*
expand(node);* } } else if (node instanceof
TreeNodeProvider.NoPartitionNode  &&

isNoPartitionProfilesPresent()) {*

expand(node);* } } The triggering field: searchTerm.add(new
AjaxFormComponentUpdatingBehavior("keydown") { @Override protected

void

onUpdate(AjaxRequestTarget target) { if (searchTermModel.getObject()

!=

null  &&  !searchTermModel.getObject().isEmpty()) {
profilePartitionTree.rebuildExpandedPartitions(); } else {
profilePartitionTree.getP
artitionsWithProfiles().clear(); }*

target.add(profilePartitionTree);*

} @Override protected void updateAjaxAttributes(AjaxRequestAttributes
attributes) { super.updateAjaxAttributes(attributes);
attributes.setThrottlingSettings(new
ThrottlingSettings(searchTerm.getMarkupId(),

Duration.milliseconds(400),

true)); } }); But I get an this error message in wicket 8, my line

below:

2018-11-28 14:26:44,127 | ERROR | qtp938432184-65

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-09 Thread nino martinez wael
erByCGLIB$$a4862322.processRequestCycle()[jar:bundle://128.0:0/!/:]
> >>>>> at
> >>>>>
> org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:204)[136:org.apache.wicket.core:8.1.0]
> >>>>> at
> >>>>>
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:286)[136:org.apache.wicket.core:8.1.0]
> >>>>> at
> >>>>>
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.CGLIB$doFilter$3()[jar:bundle://128.0:0/!/:]
> >>>>> at
> >>>>>
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322$$FastClassByCGLIB$$c4e730b8.invoke()[jar:bundle://128.0:0/!/:]
> >>>>> at
> >>>>>
> net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)[128:org.apache.servicemix.bundles.cglib:2.2.2.1]
> >>>>> at
> >>>>>
> org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet$WicketFilterCallback.int
> >>>>>
> ercept(PAXWicketServlet.java:236)[147:org.ops4j.pax.wicket.service:5.0.0]
> >>>>> at
> >>>>>
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.doFilter()[jar:bundle://128.0:0/!/:]
> >>>>> at
> >>>>>
> org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet.service(PAXWicketServlet.java:140)[147:org.ops4j.pax.wicket.service:5.0.0]
> >>>>> at
> >>>>>
> org.ops4j.pax.wicket.internal.filter.PAXWicketFilterChain.doFilter(PAXWicketFilterChain.java:71)[147:org.ops4j.pax.wicket.service:5.0.0]
> >>>>> at
> >>>>>
> org.ops4j.pax.wicket.internal.filter.FilterDelegator.doFilter(FilterDelegator.java:105)[147:org.ops4j.pax.wicket.service:5.0.0]
> >>>>> at
> >>>>>
> org.ops4j.pax.wicket.internal.servlet.ServletCallInterceptor.service(ServletCallInterceptor.java:179)[147:org.ops4j.pax.wicket.service:5.0.0]
> >>>>> at
> >>>>>
> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1669)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> >>>>> at o
> >>>>>
> rg.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:201)[92:org.eclipse.jetty.websocket.server:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:72)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
> >>>>> at
> >>>>>
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)[80:org.eclipse.jetty.security:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> >>>>> at org.eclipse.jetty.server.handler.Con
> >>>>>
> textHandler.doHandle(ContextHandler.java:1127)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:287)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
> >>>>> at
> >>>>>
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> >>>>> at
> >>>>>
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)[81:org.eclipse.jetty.

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-07 Thread Sven Meier
HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
clipse.jetty.server:9.2.21.v20170120] at
org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
  at
org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
at
org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
at org.eclipse.jetty.io
.AbstractConnection$2.run(AbstractConnection.java:544)[73:
org.eclipse.jetty.io:9 .2.21.v20170120] at
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]
at
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]
at java.lang.Thread.run(Unknown Source)[:1.8.0_111] Caused by:
java.lang.IllegalStateException: Components can no longer be added at
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wick
et.core:8.1.0] at
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:240)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:122)
at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:115)
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
a
t
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:960)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree.updateBranch(NestedTree.java:114)
at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.lambda$expand$0(AbstractTree.java:159)[137:org.apache.wicket.extensions:8.1.0]
at java.util.Optional.ifPresent(Unknown Source)[:1.8.0_111]   at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:158)[137:org.apache.wicket.extensions:8.1.0]
* at
dk.netdesign.XXX.frontend.page.SupervisorPage$14.newContentComponent(SupervisorPage.java:443)[106:XXX-frontend:1.0.4.RC_01]*
at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree$1.createContent(AbstractTree.java:236)[137:org.apache.wicket.extensions:8.1.0]
at org.apache.wicket.extensions.markup.html.repe
ater.tree.Node.onInitialize(Node.java:86)[137:org.apache.wicket.extensions:8.1.0]
at
org.apache.wicket.Component.fireInitialize(Component.java:871)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1043)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1039)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:192)[140:org.apache.wicket.util:8.1.0]
at
org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:975)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.MarkupContainer.internalInitialize(MarkupContainer.java:1038)[136:org.apache.wicket.core:8.1.0]
at org.apache.wicket.MarkupContainer.addedComponent(Mark
upContainer.java:1014)[136:org.apache.wicket.core:8.1.0] at
org.apache.wicket.MarkupContainer.add(MarkupContainer.java:239)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.markup.repeater.RefreshingView.addItems(RefreshingView.java:191)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.markup.repeater.RefreshingView.onPopulate(RefreshingView.java:97)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:124)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.Component.beforeRender(Component.java:937)[136:org.apache.wicket.core:8.1.0]
at
org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1753)[136:org.apache.wicket.core:8.1.0]
... 56 more -- Best regards / Med venlig hilsen Nino Martinez



--
Best regards / Med venlig hilsen
Nino Martinez



--
Best regards / Med venlig hilsen
Nino Martine

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-06 Thread nino martinez wael
170120]
>>>> at
>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1669)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
>>>> at o
>>>> rg.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:201)[92:org.eclipse.jetty.websocket.server:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
>>>> at
>>>> org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:72)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>>>> at
>>>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)[80:org.eclipse.jetty.security:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at org.eclipse.jetty.server.handler.Con
>>>> textHandler.doHandle(ContextHandler.java:1127)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:287)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>>>> at
>>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>>>> at
>>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
>>>> clipse.jetty.server:9.2.21.v20170120] at
>>>> org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>>  at
>>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>> at org.eclipse.jetty.io
>>>> .AbstractConnection$2.run(AbstractConnection.java:544)[73:
>>>> org.eclipse.jetty.io:9 .2.21.v20170120] at
>>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>>>> at
>>>> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>>>> at java.lang.Thread.run(Unknown Source)[:1.8.0_111] Caused by:
>>>> java.lang.IllegalStateException: Components can no longer be added at
>>>> org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wick
>>>> et.core:8.1.0] at
>>>> org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]
>>>> at
>>>> org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]
>>>> at
>>>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]
>>>> at
>>>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:240)[136:org.apache.wicket.core:8.1.0]
>>>> at
>>>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:122)
>>>> at
>>>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:115)
>>>> at
>>>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
>>>> at
>>>> org.apac

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-12-03 Thread nino martinez wael
lipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)[80:org.eclipse.jetty.security:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at org.eclipse.jetty.server.handler.Con
>>> textHandler.doHandle(ContextHandler.java:1127)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:287)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>>> at
>>> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>>> at
>>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
>>> clipse.jetty.server:9.2.21.v20170120] at
>>> org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>>  at
>>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>> at org.eclipse.jetty.io
>>> .AbstractConnection$2.run(AbstractConnection.java:544)[73:
>>> org.eclipse.jetty.io:9 .2.21.v20170120] at
>>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>>> at
>>> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>>> at java.lang.Thread.run(Unknown Source)[:1.8.0_111] Caused by:
>>> java.lang.IllegalStateException: Components can no longer be added at
>>> org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wick
>>> et.core:8.1.0] at
>>> org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]
>>> at
>>> org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]
>>> at
>>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]
>>> at
>>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:240)[136:org.apache.wicket.core:8.1.0]
>>> at
>>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:122)
>>> at
>>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:115)
>>> at
>>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
>>> at
>>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
>>> at
>>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
>>> a
>>> t
>>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]
>>> at
>>> org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:960)[136:org.apache.wicket.core:8.1.0]
>>> at
>>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree.updateBranch(NestedTree.java:114)
>>> at
>>> org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.lambda$expand$0(AbstractTree.java:159)[137:org.apache.wicket.extensions:8.1.0]
>>> at java.util.Optional.ifPresent(Unknown Source)[:1.8.0_111]   at
>>> org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:158)[137:org.apache.wicket.extensions:8.1.0]
>>> * at
>>> dk.netdesign.XXX.frontend.page.SupervisorPage$14.newContentComponent(SupervisorPage.java:443)[106:

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-11-28 Thread nino martinez wael
1.v20170120]
>> at
>> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
>> at
>> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
>> clipse.jetty.server:9.2.21.v20170120] at
>> org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>>  at
>> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>> at
>> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>> at org.eclipse.jetty.io
>> .AbstractConnection$2.run(AbstractConnection.java:544)[73:
>> org.eclipse.jetty.io:9 .2.21.v20170120] at
>> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>> at
>> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]
>> at java.lang.Thread.run(Unknown Source)[:1.8.0_111] Caused by:
>> java.lang.IllegalStateException: Components can no longer be added at
>> org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wick
>> et.core:8.1.0] at
>> org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:240)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:122)
>> at
>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:115)
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]
>> a
>> t
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:960)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree.updateBranch(NestedTree.java:114)
>> at
>> org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.lambda$expand$0(AbstractTree.java:159)[137:org.apache.wicket.extensions:8.1.0]
>> at java.util.Optional.ifPresent(Unknown Source)[:1.8.0_111]   at
>> org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:158)[137:org.apache.wicket.extensions:8.1.0]
>> * at
>> dk.netdesign.XXX.frontend.page.SupervisorPage$14.newContentComponent(SupervisorPage.java:443)[106:XXX-frontend:1.0.4.RC_01]*
>> at
>> org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree$1.createContent(AbstractTree.java:236)[137:org.apache.wicket.extensions:8.1.0]
>> at org.apache.wicket.extensions.markup.html.repe
>> ater.tree.Node.onInitialize(Node.java:86)[137:org.apache.wicket.extensions:8.1.0]
>> at
>> org.apache.wicket.Component.fireInitialize(Component.java:871)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1043)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1039)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:192)[140:org.apache.wicket.util:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:975)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer.internalInitialize(MarkupContainer.java:1038)[136:org.apache.wicket.core:8.1.0]
>> at org.apache.wicket.MarkupContainer.addedComponent(Mark
>> upContainer.java:1014)[136:org.apache.wicket.core:8.1.0] at
>> org.apache.wicket.MarkupContainer.add(MarkupContainer.java:239)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.markup.repeater.RefreshingView.addItems(RefreshingView.java:191)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.markup.repeater.RefreshingView.onPopulate(RefreshingView.java:97)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.markup.repeater.AbstractRepeater.onBeforeRender(AbstractRepeater.java:124)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.Component.beforeRender(Component.java:937)[136:org.apache.wicket.core:8.1.0]
>> at
>> org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1753)[136:org.apache.wicket.core:8.1.0]
>> ... 56 more -- Best regards / Med venlig hilsen Nino Martinez
>> >
>>
>
>
>
> --
> Best regards / Med venlig hilsen
> Nino Martinez
>


-- 
Best regards / Med venlig hilsen
Nino Martinez


Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-11-28 Thread nino martinez wael
roxy.MethodProxy.invokeSuper(MethodProxy.java:228)[128:org.apache.servic
> emix.bundles.cglib:2.2.2.1] at
> org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet$WicketFilterCallback.intercept(PAXWicketServlet.java:236)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.processRequestCycle()[jar:bundle://128.0:0/!/:]
> at
> org.apache.wicket.protocol.http.WicketFilter.processRequest(WicketFilter.java:204)[136:org.apache.wicket.core:8.1.0]
> at
> org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:286)[136:org.apache.wicket.core:8.1.0]
> at
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.CGLIB$doFilter$3()[jar:bundle://128.0:0/!/:]
> at
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322$$FastClassByCGLIB$$c4e730b8.invoke()[jar:bundle://128.0:0/!/:]
> at
> net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)[128:org.apache.servicemix.bundles.cglib:2.2.2.1]
> at
> org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet$WicketFilterCallback.int
> ercept(PAXWicketServlet.java:236)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.doFilter()[jar:bundle://128.0:0/!/:]
> at
> org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet.service(PAXWicketServlet.java:140)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.ops4j.pax.wicket.internal.filter.PAXWicketFilterChain.doFilter(PAXWicketFilterChain.java:71)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.ops4j.pax.wicket.internal.filter.FilterDelegator.doFilter(FilterDelegator.java:105)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.ops4j.pax.wicket.internal.servlet.ServletCallInterceptor.service(ServletCallInterceptor.java:179)[147:org.ops4j.pax.wicket.service:5.0.0]
> at
> org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> at
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1669)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> at o
> rg.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:201)[92:org.eclipse.jetty.websocket.server:9.2.21.v20170120]
> at
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> at
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> at
> org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:72)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
> at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)[80:org.eclipse.jetty.security:9.2.21.v20170120]
> at
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at org.eclipse.jetty.server.handler.Con
> textHandler.doHandle(ContextHandler.java:1127)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:287)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
> at
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
> at
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
> at
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
> clipse.jetty.server:9.2.21.v20170120] at
> org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
>  at
> org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at
> org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
> at org.eclipse.jetty.io
> .AbstractConnection$2.run(AbstractConnection.java:544)[73:
> org.eclipse.jetty.io:9 .2.21.v20170120] at
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPo

Re: Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-11-28 Thread sven
org.apache.wicket.core:8.1.0]
 at 
org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.CGLIB$doFilter$3()[jar:bundle://128.0:0/!/:]
 at 
org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322$$FastClassByCGLIB$$c4e730b8.invoke()[jar:bundle://128.0:0/!/:]
 at 
net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)[128:org.apache.servicemix.bundles.cglib:2.2.2.1]
 at 
org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet$WicketFilterCallback.int
ercept(PAXWicketServlet.java:236)[147:org.ops4j.pax.wicket.service:5.0.0] at 
org.apache.wicket.protocol.http.WicketFilter$$EnhancerByCGLIB$$a4862322.doFilter()[jar:bundle://128.0:0/!/:]
 at 
org.ops4j.pax.wicket.internal.servlet.PAXWicketServlet.service(PAXWicketServlet.java:140)[147:org.ops4j.pax.wicket.service:5.0.0]
 at 
org.ops4j.pax.wicket.internal.filter.PAXWicketFilterChain.doFilter(PAXWicketFilterChain.java:71)[147:org.ops4j.pax.wicket.service:5.0.0]
 at 
org.ops4j.pax.wicket.internal.filter.FilterDelegator.doFilter(FilterDelegator.java:105)[147:org.ops4j.pax.wicket.service:5.0.0]
 at 
org.ops4j.pax.wicket.internal.servlet.ServletCallInterceptor.service(ServletCallInterceptor.java:179)[147:org.ops4j.pax.wicket.service:5.0.0]
 at 
org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:812)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
 at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1669)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
 at o
rg.eclipse.jetty.websocket.server.WebSocketUpgradeFilter.doFilter(WebSocketUpgradeFilter.java:201)[92:org.eclipse.jetty.websocket.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1652)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
 at 
org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:585)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
 at 
org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:72)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
 at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:577)[80:org.eclipse.jetty.security:9.2.21.v20170120]
 at 
org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at org.eclipse.jetty.server.handler.Con
textHandler.doHandle(ContextHandler.java:1127)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:287)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
 at 
org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:515)[82:org.eclipse.jetty.servlet:9.2.21.v20170120]
 at 
org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1061)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80)[99:org.ops4j.pax.web.pax-web-jetty:4.3.4]
 at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)[81:org.e
clipse.jetty.server:9.2.21.v20170120] at 
org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]
   at 
org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]
 at 
org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:544)[73:org.eclipse.jetty.io:9
 .2.21.v20170120] at 
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]
 at 
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]
 at java.lang.Thread.run(Unknown Source)[:1.8.0_111] Caused by: 
java.lang.IllegalStateException: Components can no longer be added at 
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wick
et.core:8.1.0] at 
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]
 at 
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]
 at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]
 at 
org.apache.

Wicket 6.x -> Wicket 8.x extensions NestedTree expand fails ( Components can no longer be added)

2018-11-28 Thread nino martinez wael
clipse.jetty.server:9.2.21.v20170120]

 at
org.eclipse.jetty.server.Server.handle(Server.java:499)[81:org.eclipse.jetty.server:9.2.21.v20170120]

 at
org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:311)[81:org.eclipse.jetty.server:9.2.21.v20170120]

 at
org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:258)[81:org.eclipse.jetty.server:9.2.21.v20170120]

 at
org.eclipse.jetty.io.AbstractConnection$2.run(AbstractConnection.java:544)[73:org.eclipse.jetty.io:9
.2.21.v20170120]

 at
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:635)[84:org.eclipse.jetty.util:9.2.21.v20170120]

 at
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:555)[84:org.eclipse.jetty.util:9.2.21.v20170120]

 at java.lang.Thread.run(Unknown
Source)[:1.8.0_111]

Caused by: java.lang.IllegalStateException: Components can no  longer be
added

 at
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:264)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:240)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:122)

 at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree$1.component(NestedTree.java:115)

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:162)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:960)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree.updateBranch(NestedTree.java:114)

 at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.lambda$expand$0(AbstractTree.java:159)[137:org.apache.wicket.extensions:8.1.0]

 at java.util.Optional.ifPresent(Unknown
Source)[:1.8.0_111]

 at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:158)[137:org.apache.wicket.extensions:8.1.0]

* at
dk.netdesign.XXX.frontend.page.SupervisorPage$14.newContentComponent(SupervisorPage.java:443)[106:XXX-frontend:1.0.4.RC_01]*

 at
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree$1.createContent(AbstractTree.java:236)[137:org.apache.wicket.extensions:8.1.0]

 at
org.apache.wicket.extensions.markup.html.repeater.tree.Node.onInitialize(Node.java:86)[137:org.apache.wicket.extensions:8.1.0]

 at
org.apache.wicket.Component.fireInitialize(Component.java:871)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1043)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.MarkupContainer$3.component(MarkupContainer.java:1039)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:144)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:123)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.util.visit.Visits.visitChildren(Visits.java:192)[140:org.apache.wicket.util:8.1.0]

 at
org.apache.wicket.MarkupContainer.visitChildren(MarkupContainer.java:975)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.MarkupContainer.internalInitialize(MarkupContainer.java:1038)[136:org.apache.wicket.core:8.1.0]

 at
org.apache.wicket.MarkupContainer.addedComp

Re: AJAX & IllegalStateException: Components can no longer be added

2018-05-25 Thread Tobias Gierke

Hi Sven,

Hi,

actually it is even more strict:

Once the ART has started generating the response - including 
preparation of components - you can now longer add other components.


This hasn't changed from 7.x to 8.x

We were discussing on lifting this restriction, but this would come 
with some difficulties: what if a component in beforeRender() adds one 
of its ancestors to be updated?

Thanks for the clarification!

Cheers,
Tobias


Have fun
Sven


Am 25.05.2018 um 10:44 schrieb Tobias Gierke:

Hi,

Can someone please explain to me what's causing this exception (see 
end of this mail) when trying to add a component to an ART ?


In 
http://apache-wicket.1842946.n4.nabble.com/Components-can-no-longer-be-added-td4662838.html 
Sven Meier said



once rendering of components via Ajax has started, you cannot update
components. 
but as can be seen from the stacktrace I'm still in the 
beforeRender() phase ... or is anything inside the beforeRender() 
code path already considered to be part of the rendering phase ?


Thanks,
Tobias



 java.lang.IllegalStateException: Components can no  longer be added
    at 
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:263) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.lambda$0(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.behaviors.AjaxTooltipManager.doOnAjaxRequest(AjaxTooltipManager.java:411) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.queryFinished(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.invokeCallbacks(AbstractSearchResultsDataProvider.java:241) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:230) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:252) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRDataTable.onConfigure(XDRDataTable.java:436) 
[classes/:?]
    at org.apache.wicket.Component.configure(Component.java:984) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:926) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1753) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.Component.onBeforeRender(Component.java:3796) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:937) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.prepareComponent(PartialPageUpdate.java:322) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeComponents(PartialPageUpdate.java:250) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeTo(PartialPageUpdate.java:162) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.respond(AjaxRequestHandler.java:383) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:912) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.RequestHandlerExecutor.execute(RequestHandlerExecutor.java:65) 
[wicket-request-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:283) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:253) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:221) 
[wicket-core-8.0.0.jar:8.0.0]



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: AJAX & IllegalStateException: Components can no longer be added

2018-05-25 Thread Sven Meier

Hi,

actually it is even more strict:

Once the ART has started generating the response - including preparation 
of components - you can now longer add other components.


This hasn't changed from 7.x to 8.x

We were discussing on lifting this restriction, but this would come with 
some difficulties: what if a component in beforeRender() adds one of its 
ancestors to be updated?


Have fun
Sven


Am 25.05.2018 um 10:44 schrieb Tobias Gierke:

Hi,

Can someone please explain to me what's causing this exception (see 
end of this mail) when trying to add a component to an ART ?


In 
http://apache-wicket.1842946.n4.nabble.com/Components-can-no-longer-be-added-td4662838.html 
Sven Meier said



once rendering of components via Ajax has started, you cannot update
components. 
but as can be seen from the stacktrace I'm still in the beforeRender() 
phase ... or is anything inside the beforeRender() code path already 
considered to be part of the rendering phase ?


Thanks,
Tobias



 java.lang.IllegalStateException: Components can no  longer be added
    at 
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:263) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.lambda$0(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.behaviors.AjaxTooltipManager.doOnAjaxRequest(AjaxTooltipManager.java:411) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.queryFinished(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.invokeCallbacks(AbstractSearchResultsDataProvider.java:241) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:230) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:252) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRDataTable.onConfigure(XDRDataTable.java:436) 
[classes/:?]
    at org.apache.wicket.Component.configure(Component.java:984) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:926) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1753) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.onBeforeRender(Component.java:3796) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:937) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.prepareComponent(PartialPageUpdate.java:322) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeComponents(PartialPageUpdate.java:250) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeTo(PartialPageUpdate.java:162) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.respond(AjaxRequestHandler.java:383) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:912) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.RequestHandlerExecutor.execute(RequestHandlerExecutor.java:65) 
[wicket-request-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:283) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:253) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:221) 
[wicket-core-8.0.0.jar:8.0.0]



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



AJAX & IllegalStateException: Components can no longer be added

2018-05-25 Thread Tobias Gierke

Hi,

Can someone please explain to me what's causing this exception (see end 
of this mail) when trying to add a component to an ART ?


In 
http://apache-wicket.1842946.n4.nabble.com/Components-can-no-longer-be-added-td4662838.html 
Sven Meier said



once rendering of components via Ajax has started, you cannot update
components. 
but as can be seen from the stacktrace I'm still in the beforeRender() 
phase ... or is anything inside the beforeRender() code path already 
considered to be part of the rendering phase ?


Thanks,
Tobias



 java.lang.IllegalStateException: Components can no  longer be added
    at 
org.apache.wicket.page.PartialPageUpdate.assertNotFrozen(PartialPageUpdate.java:858) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.assertComponentsNotFrozen(PartialPageUpdate.java:851) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.add(PartialPageUpdate.java:448) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:263) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239) 
~[wicket-core-8.0.0.jar:8.0.0]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.lambda$0(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.behaviors.AjaxTooltipManager.doOnAjaxRequest(AjaxTooltipManager.java:411) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRListPanel$1.queryFinished(XDRListPanel.java:73) 
~[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.invokeCallbacks(AbstractSearchResultsDataProvider.java:241) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:230) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.streamsearch.AbstractSearchResultsDataProvider.getSearchResults(AbstractSearchResultsDataProvider.java:252) 
[classes/:?]
    at 
com.vodecc.voipmng.boundary.wicket.xdrsearch.XDRDataTable.onConfigure(XDRDataTable.java:436) 
[classes/:?]
    at org.apache.wicket.Component.configure(Component.java:984) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:926) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.MarkupContainer.onBeforeRenderChildren(MarkupContainer.java:1753) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.onBeforeRender(Component.java:3796) 
[wicket-core-8.0.0.jar:8.0.0]
    at org.apache.wicket.Component.beforeRender(Component.java:937) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.prepareComponent(PartialPageUpdate.java:322) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeComponents(PartialPageUpdate.java:250) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.page.PartialPageUpdate.writeTo(PartialPageUpdate.java:162) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.ajax.AjaxRequestHandler.respond(AjaxRequestHandler.java:383) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle$HandlerExecutor.respond(RequestCycle.java:912) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.RequestHandlerExecutor.execute(RequestHandlerExecutor.java:65) 
[wicket-request-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.execute(RequestCycle.java:283) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequest(RequestCycle.java:253) 
[wicket-core-8.0.0.jar:8.0.0]
    at 
org.apache.wicket.request.cycle.RequestCycle.processRequestAndDetach(RequestCycle.java:221) 
[wicket-core-8.0.0.jar:8.0.0]



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



RE: Components can no longer be added

2013-12-10 Thread Colin Rogers
Sven,

 once rendering of components via Ajax has started, you cannot update 
components.

But at the moment when this happens, we are in the onConfigure() part of the 
lifecycle. Which is before onBeforeRender(), and hence components should've 
have started rendering... but that is minor as...

You should just add all expanded nodes to your tree's model. That's faster and 
won't trigger any updates:

Brilliant! I didn't realize that tree model was the *expanded* nodes, but it 
makes sense since you now say it...

Thanks! This works great and gets round any other issues. :)

Cheers,
Col.

-Original Message-
From: Sven Meier [mailto:s...@meiers.net]
Sent: Monday, December 9, 2013 8:01 PM
To: users@wicket.apache.org
Subject: Re: Components can no longer be added

Hi,

once rendering of components via Ajax has started, you cannot update components.

AbstractTree#expand() is a convenience method that updates the expanded branch 
automatically, hence you get the IllegalStateException.

You should just add all expanded nodes to your tree's model. That's faster and 
won't trigger any updates:

   tree.getModel().addAll(addNodes);

If you always start with all nodes expanded, you might want to use a custom 
set, which inverses its contents. See 
org.apache.wicket.examples.tree.FooExpansion for inspiration.

Regards
Sven


On 12/09/2013 06:28 AM, Colin Rogers wrote:
 Wicketeers,

 I have another hard-to-track down issue.

 To make matters worse, I've actually taken this code/pattern, put it
 into a quickstart - and what do you know - it works fine...! This
 means I have no way to recreate this error in a demonstrable way.
 Hopefully if I throw this out there, someone might be able to describe
 the error and I can then determine what I'm doing to cause it.
 Unfortunately google has zero results for;

 +Components can no  longer be added +wicket

 Anyway... the exception I'm getting is;

 java.lang.IllegalStateException: Components can no  longer be added
   at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertNotFrozen(AbstractAjaxResponse.java:740)
   at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertComponentsNotFrozen(AbstractAjaxResponse.java:733)
   at 
 org.apache.wicket.ajax.AbstractAjaxResponse.add(AbstractAjaxResponse.java:358)
   at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
   at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:232)
   at 
 org.apache.wicket.extensions.markup.html.repeater.tree.TableTree.updateBranch(TableTree.java:178)
   at 
 org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:204)
   at myapp.TreeUtils.expandNode(TreeUtils.java:25)
   at myapp.TreeUtils.expandAll(TreeUtils.java:19)


 It is caused when refreshing a table-tree component, that had previous 
 rendered correctly and had successfully expanded the nodes. This problem 
 happens when the table-trees parent component is refreshed, in which the 
 table is rebuilt from new, and replaced the old table. Having debugged the 
 code, it's something to do with the AjaxRequestHandler that has been 
 retrieved - in that it's components are 'frozen'. It's odd as I'm in  the 
 onConfigure() part of the lifecycle, and therefore components should be okay 
 to be added - especially as they are brand new components. Could the 
 AjaxRequestHandler being retrieved be the wrong one, stale one?

 List I said - I can't recreate it in a Quickstart, so there is obviously 
 something else in the 100k+s of the projects code that is doing something 
 else to mess it up.

 The 'Tree Utils' class looks like this;

 public class TreeUtils {

  @SuppressWarnings(unchecked)
  public static void expandAll( AbstractTree? tree ) {

  // stupid cast!! Has to happen for use to retrieve the roots, 
 generically.
  AbstractTreeObject castTree = (AbstractTreeObject) tree;

  Iterator? roots = tree.getProvider().getRoots();
  while( roots.hasNext() ) {

  Object root = roots.next();
  expandNode( castTree, root );
  }
  }

  private static void expandNode( AbstractTreeObject tree, Object
 node) {

  tree.expand(node);

  Iterator? children = tree.getProvider().getChildren(node);
  while( children.hasNext() ) {

  Object child = children.next();
  expandNode( tree, child );
  }
  }
 }


 Any pointers and tips would be greatly appreciated.

 Cheers,
 Col.
 EMAIL DISCLAIMER This email message and its attachments are confidential and 
 may also contain copyright or privileged material. If you are not the 
 intended recipient, you may not forward the email or disclose or use the 
 information contained in it. If you have received this email message in 
 error, please advise the sender immediately by replying to this email and 
 delete the message and any associated attachments. Any views

Re: Components can no longer be added

2013-12-09 Thread Sven Meier

Hi,

once rendering of components via Ajax has started, you cannot update 
components.


AbstractTree#expand() is a convenience method that updates the expanded 
branch automatically, hence you get the IllegalStateException.


You should just add all expanded nodes to your tree's model. That's 
faster and won't trigger any updates:


  tree.getModel().addAll(addNodes);

If you always start with all nodes expanded, you might want to use a 
custom set, which inverses its contents. See 
org.apache.wicket.examples.tree.FooExpansion for inspiration.


Regards
Sven


On 12/09/2013 06:28 AM, Colin Rogers wrote:

Wicketeers,

I have another hard-to-track down issue.

To make matters worse, I've actually taken this code/pattern, put it into a 
quickstart - and what do you know - it works fine...! This means I have no way 
to recreate this error in a demonstrable way. Hopefully if I throw this out 
there, someone might be able to describe the error and I can then determine 
what I'm doing to cause it. Unfortunately google has zero results for;

+Components can no  longer be added +wicket

Anyway... the exception I'm getting is;

java.lang.IllegalStateException: Components can no  longer be added
  at 
org.apache.wicket.ajax.AbstractAjaxResponse.assertNotFrozen(AbstractAjaxResponse.java:740)
  at 
org.apache.wicket.ajax.AbstractAjaxResponse.assertComponentsNotFrozen(AbstractAjaxResponse.java:733)
  at 
org.apache.wicket.ajax.AbstractAjaxResponse.add(AbstractAjaxResponse.java:358)
  at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
  at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:232)
  at 
org.apache.wicket.extensions.markup.html.repeater.tree.TableTree.updateBranch(TableTree.java:178)
  at 
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:204)
  at myapp.TreeUtils.expandNode(TreeUtils.java:25)
  at myapp.TreeUtils.expandAll(TreeUtils.java:19)


It is caused when refreshing a table-tree component, that had previous rendered 
correctly and had successfully expanded the nodes. This problem happens when 
the table-trees parent component is refreshed, in which the table is rebuilt 
from new, and replaced the old table. Having debugged the code, it's something 
to do with the AjaxRequestHandler that has been retrieved - in that it's 
components are 'frozen'. It's odd as I'm in  the onConfigure() part of the 
lifecycle, and therefore components should be okay to be added - especially as 
they are brand new components. Could the AjaxRequestHandler being retrieved be 
the wrong one, stale one?

List I said - I can't recreate it in a Quickstart, so there is obviously 
something else in the 100k+s of the projects code that is doing something else 
to mess it up.

The 'Tree Utils' class looks like this;

public class TreeUtils {

 @SuppressWarnings(unchecked)
 public static void expandAll( AbstractTree? tree ) {

 // stupid cast!! Has to happen for use to retrieve the roots, 
generically.
 AbstractTreeObject castTree = (AbstractTreeObject) tree;

 Iterator? roots = tree.getProvider().getRoots();
 while( roots.hasNext() ) {

 Object root = roots.next();
 expandNode( castTree, root );
 }
 }

 private static void expandNode( AbstractTreeObject tree, Object node) {

 tree.expand(node);

 Iterator? children = tree.getProvider().getChildren(node);
 while( children.hasNext() ) {

 Object child = children.next();
 expandNode( tree, child );
 }
 }
}


Any pointers and tips would be greatly appreciated.

Cheers,
Col.
EMAIL DISCLAIMER This email message and its attachments are confidential and 
may also contain copyright or privileged material. If you are not the intended 
recipient, you may not forward the email or disclose or use the information 
contained in it. If you have received this email message in error, please 
advise the sender immediately by replying to this email and delete the message 
and any associated attachments. Any views, opinions, conclusions, advice or 
statements expressed in this email message are those of the individual sender 
and should not be relied upon as the considered view, opinion, conclusions, 
advice or statement of this company except where the sender expressly, and with 
authority, states them to be the considered view, opinion, conclusions, advice 
or statement of this company. Every care is taken but we recommend that you 
scan any attachments for viruses.




-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Components can no longer be added

2013-12-08 Thread Colin Rogers
Wicketeers,

I have another hard-to-track down issue.

To make matters worse, I've actually taken this code/pattern, put it into a 
quickstart - and what do you know - it works fine...! This means I have no way 
to recreate this error in a demonstrable way. Hopefully if I throw this out 
there, someone might be able to describe the error and I can then determine 
what I'm doing to cause it. Unfortunately google has zero results for;

+Components can no  longer be added +wicket

Anyway... the exception I'm getting is;

java.lang.IllegalStateException: Components can no  longer be added
 at 
org.apache.wicket.ajax.AbstractAjaxResponse.assertNotFrozen(AbstractAjaxResponse.java:740)
 at 
org.apache.wicket.ajax.AbstractAjaxResponse.assertComponentsNotFrozen(AbstractAjaxResponse.java:733)
 at 
org.apache.wicket.ajax.AbstractAjaxResponse.add(AbstractAjaxResponse.java:358)
 at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
 at 
org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:232)
 at 
org.apache.wicket.extensions.markup.html.repeater.tree.TableTree.updateBranch(TableTree.java:178)
 at 
org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:204)
 at myapp.TreeUtils.expandNode(TreeUtils.java:25)
 at myapp.TreeUtils.expandAll(TreeUtils.java:19)


It is caused when refreshing a table-tree component, that had previous rendered 
correctly and had successfully expanded the nodes. This problem happens when 
the table-trees parent component is refreshed, in which the table is rebuilt 
from new, and replaced the old table. Having debugged the code, it's something 
to do with the AjaxRequestHandler that has been retrieved - in that it's 
components are 'frozen'. It's odd as I'm in  the onConfigure() part of the 
lifecycle, and therefore components should be okay to be added - especially as 
they are brand new components. Could the AjaxRequestHandler being retrieved be 
the wrong one, stale one?

List I said - I can't recreate it in a Quickstart, so there is obviously 
something else in the 100k+s of the projects code that is doing something else 
to mess it up.

The 'Tree Utils' class looks like this;

public class TreeUtils {

@SuppressWarnings(unchecked)
public static void expandAll( AbstractTree? tree ) {

// stupid cast!! Has to happen for use to retrieve the roots, 
generically.
AbstractTreeObject castTree = (AbstractTreeObject) tree;

Iterator? roots = tree.getProvider().getRoots();
while( roots.hasNext() ) {

Object root = roots.next();
expandNode( castTree, root );
}
}

private static void expandNode( AbstractTreeObject tree, Object node) {

tree.expand(node);

Iterator? children = tree.getProvider().getChildren(node);
while( children.hasNext() ) {

Object child = children.next();
expandNode( tree, child );
}
}
}


Any pointers and tips would be greatly appreciated.

Cheers,
Col.
EMAIL DISCLAIMER This email message and its attachments are confidential and 
may also contain copyright or privileged material. If you are not the intended 
recipient, you may not forward the email or disclose or use the information 
contained in it. If you have received this email message in error, please 
advise the sender immediately by replying to this email and delete the message 
and any associated attachments. Any views, opinions, conclusions, advice or 
statements expressed in this email message are those of the individual sender 
and should not be relied upon as the considered view, opinion, conclusions, 
advice or statement of this company except where the sender expressly, and with 
authority, states them to be the considered view, opinion, conclusions, advice 
or statement of this company. Every care is taken but we recommend that you 
scan any attachments for viruses.


Re: Components can no longer be added

2013-12-08 Thread Bernard
Hi,

I am an expert in shooting myself in the foot with Wicket / Java
problems.

In a situation like this, I would do the same as you do - isolate the
pattern and make a quickstart. Unfortunately, this approach is full of
assumptions, and my statistics say that this succeeds only in 20% of
all cases.

So I usually have to do it the hard way: Take a copy of the
application and strip it down generation by generation until the
culprit is isolated in its most simplistic form.

I think in 50% of all cases, I could see my own fault. In the other
50% I submitted a Wicket jira issue, where again in 50% of these it
was my fault not Wicket.

Regards,

Bernard



On Mon, 9 Dec 2013 05:28:52 +, you wrote:

Wicketeers,

I have another hard-to-track down issue.

To make matters worse, I've actually taken this code/pattern, put it into a 
quickstart - and what do you know - it works fine...! This means I have no way 
to recreate this error in a demonstrable way. Hopefully if I throw this out 
there, someone might be able to describe the error and I can then determine 
what I'm doing to cause it. Unfortunately google has zero results for;

+Components can no  longer be added +wicket

Anyway... the exception I'm getting is;

java.lang.IllegalStateException: Components can no  longer be added
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertNotFrozen(AbstractAjaxResponse.java:740)
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertComponentsNotFrozen(AbstractAjaxResponse.java:733)
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.add(AbstractAjaxResponse.java:358)
 at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
 at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:232)
 at 
 org.apache.wicket.extensions.markup.html.repeater.tree.TableTree.updateBranch(TableTree.java:178)
 at 
 org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:204)
 at myapp.TreeUtils.expandNode(TreeUtils.java:25)
 at myapp.TreeUtils.expandAll(TreeUtils.java:19)


It is caused when refreshing a table-tree component, that had previous 
rendered correctly and had successfully expanded the nodes. This problem 
happens when the table-trees parent component is refreshed, in which the table 
is rebuilt from new, and replaced the old table. Having debugged the code, 
it's something to do with the AjaxRequestHandler that has been retrieved - in 
that it's components are 'frozen'. It's odd as I'm in  the onConfigure() part 
of the lifecycle, and therefore components should be okay to be added - 
especially as they are brand new components. Could the AjaxRequestHandler 
being retrieved be the wrong one, stale one?

List I said - I can't recreate it in a Quickstart, so there is obviously 
something else in the 100k+s of the projects code that is doing something else 
to mess it up.

The 'Tree Utils' class looks like this;

public class TreeUtils {

@SuppressWarnings(unchecked)
public static void expandAll( AbstractTree? tree ) {

// stupid cast!! Has to happen for use to retrieve the roots, 
 generically.
AbstractTreeObject castTree = (AbstractTreeObject) tree;

Iterator? roots = tree.getProvider().getRoots();
while( roots.hasNext() ) {

Object root = roots.next();
expandNode( castTree, root );
}
}

private static void expandNode( AbstractTreeObject tree, Object node) {

tree.expand(node);

Iterator? children = tree.getProvider().getChildren(node);
while( children.hasNext() ) {

Object child = children.next();
expandNode( tree, child );
}
}
}


Any pointers and tips would be greatly appreciated.

Cheers,
Col.
EMAIL DISCLAIMER This email message and its attachments are confidential and 
may also contain copyright or privileged material. If you are not the intended 
recipient, you may not forward the email or disclose or use the information 
contained in it. If you have received this email message in error, please 
advise the sender immediately by replying to this email and delete the message 
and any associated attachments. Any views, opinions, conclusions, advice or 
statements expressed in this email message are those of the individual sender 
and should not be relied upon as the considered view, opinion, conclusions, 
advice or statement of this company except where the sender expressly, and 
with authority, states them to be the considered view, opinion, conclusions, 
advice or statement of this company. Every care is taken but we recommend that 
you scan any attachments for viruses.


---
This email is free from viruses and malware because avast! Antivirus protection 
is active.
http://www.avast.com


-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h

RE: Components can no longer be added

2013-12-08 Thread Colin Rogers
Yeah, I know exactly what you mean - I'm sure it's something I'm doing! :)

I might have to do as you suggest... I was just hoping for a 'you'd only get 
this error if you'd done something stupid like' and give me something to go 
on! ;)

Cheers,
Col.

-Original Message-
From: Bernard [mailto:bht...@gmail.com]
Sent: Monday, December 9, 2013 5:23 PM
To: users@wicket.apache.org
Subject: Re: Components can no longer be added

Hi,

I am an expert in shooting myself in the foot with Wicket / Java problems.

In a situation like this, I would do the same as you do - isolate the pattern 
and make a quickstart. Unfortunately, this approach is full of assumptions, and 
my statistics say that this succeeds only in 20% of all cases.

So I usually have to do it the hard way: Take a copy of the application and 
strip it down generation by generation until the culprit is isolated in its 
most simplistic form.

I think in 50% of all cases, I could see my own fault. In the other 50% I 
submitted a Wicket jira issue, where again in 50% of these it was my fault not 
Wicket.

Regards,

Bernard



On Mon, 9 Dec 2013 05:28:52 +, you wrote:

Wicketeers,

I have another hard-to-track down issue.

To make matters worse, I've actually taken this code/pattern, put it
into a quickstart - and what do you know - it works fine...! This means
I have no way to recreate this error in a demonstrable way. Hopefully
if I throw this out there, someone might be able to describe the error
and I can then determine what I'm doing to cause it. Unfortunately
google has zero results for;

+Components can no  longer be added +wicket

Anyway... the exception I'm getting is;

java.lang.IllegalStateException: Components can no  longer be added
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertNotFrozen(AbstractAjaxResponse.java:740)
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.assertComponentsNotFrozen(AbstractAjaxResponse.java:733)
 at 
 org.apache.wicket.ajax.AbstractAjaxResponse.add(AbstractAjaxResponse.java:358)
 at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:239)
 at 
 org.apache.wicket.ajax.AjaxRequestHandler.add(AjaxRequestHandler.java:232)
 at 
 org.apache.wicket.extensions.markup.html.repeater.tree.TableTree.updateBranch(TableTree.java:178)
 at 
 org.apache.wicket.extensions.markup.html.repeater.tree.AbstractTree.expand(AbstractTree.java:204)
 at myapp.TreeUtils.expandNode(TreeUtils.java:25)
 at myapp.TreeUtils.expandAll(TreeUtils.java:19)


It is caused when refreshing a table-tree component, that had previous 
rendered correctly and had successfully expanded the nodes. This problem 
happens when the table-trees parent component is refreshed, in which the table 
is rebuilt from new, and replaced the old table. Having debugged the code, 
it's something to do with the AjaxRequestHandler that has been retrieved - in 
that it's components are 'frozen'. It's odd as I'm in  the onConfigure() part 
of the lifecycle, and therefore components should be okay to be added - 
especially as they are brand new components. Could the AjaxRequestHandler 
being retrieved be the wrong one, stale one?

List I said - I can't recreate it in a Quickstart, so there is obviously 
something else in the 100k+s of the projects code that is doing something else 
to mess it up.

The 'Tree Utils' class looks like this;

public class TreeUtils {

@SuppressWarnings(unchecked)
public static void expandAll( AbstractTree? tree ) {

// stupid cast!! Has to happen for use to retrieve the roots, 
 generically.
AbstractTreeObject castTree = (AbstractTreeObject) tree;

Iterator? roots = tree.getProvider().getRoots();
while( roots.hasNext() ) {

Object root = roots.next();
expandNode( castTree, root );
}
}

private static void expandNode( AbstractTreeObject tree, Object
 node) {

tree.expand(node);

Iterator? children = tree.getProvider().getChildren(node);
while( children.hasNext() ) {

Object child = children.next();
expandNode( tree, child );
}
}
}


Any pointers and tips would be greatly appreciated.

Cheers,
Col.
EMAIL DISCLAIMER This email message and its attachments are confidential and 
may also contain copyright or privileged material. If you are not the intended 
recipient, you may not forward the email or disclose or use the information 
contained in it. If you have received this email message in error, please 
advise the sender immediately by replying to this email and delete the message 
and any associated attachments. Any views, opinions, conclusions, advice or 
statements expressed in this email message are those of the individual sender 
and should not be relied upon as the considered view, opinion, conclusions, 
advice or statement of this company except where the sender expressly, and 
with authority, states them to be the considered view