Re: Objects.cloneModel() on google app engine

2010-01-20 Thread Pedro Santos
Hi Lionel, I had the same issue, but calling the setDefaultModelObject, that
call methods on IPageVersionManager at some point. In my case, the solution
was simple change that call for comp.getDefaultModel().setObject()

On Tue, Jan 19, 2010 at 11:32 PM, Lionel Port lionel.p...@gmail.com wrote:

 Hi,

 I'm using wicket on google app engine and am having trouble with the
 sort link headers on data tables.

 It looks like when a sort link is clicked the method
 Objects.cloneModel() is called. This creates a
 ReplaceableObjectOutputStream wrapper around the ObjectOutputStream to
 do the copy using serialization/deserialization. Unfortunately this
 class tries to call enableReplace on the the underlying
 ObjectOutputStream so that it can replace component objects with just
 their name (to stop component hierachy being serialized).

 It seams the google app engine security permissions deny calling
 enableReplace on the ObjectOutputStream.

 Does any one know of a work around to get the sort links working?

 regards,
 Lionel

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




-- 
Pedro Henrique Oliveira dos Santos


Re: Objects.cloneModel() on google app engine

2010-01-20 Thread Lionel Port
The gae security restriction looks pointless because
Objects.cloneModel is just using a ByteArrayOutputStream (why should
there be restrictions on that?) but because the Objects calls are all
static I can't override the method with a working clone method also
because the OrderByLink.sort method is final I can't fix there either.

As a workaround for any one who is interested, it looks like
cloneModel is only used in this case if the component is versioned so
I set called setVersion(false) on the orderByLink and it avoids this
problem area.

On Wed, Jan 20, 2010 at 12:32 PM, Lionel Port lionel.p...@gmail.com wrote:
 Hi,

 I'm using wicket on google app engine and am having trouble with the
 sort link headers on data tables.

 It looks like when a sort link is clicked the method
 Objects.cloneModel() is called. This creates a
 ReplaceableObjectOutputStream wrapper around the ObjectOutputStream to
 do the copy using serialization/deserialization. Unfortunately this
 class tries to call enableReplace on the the underlying
 ObjectOutputStream so that it can replace component objects with just
 their name (to stop component hierachy being serialized).

 It seams the google app engine security permissions deny calling
 enableReplace on the ObjectOutputStream.

 Does any one know of a work around to get the sort links working?

 regards,
 Lionel


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



Re: Objects.cloneModel() on google app engine

2010-01-20 Thread Pedro Santos
Thank u! that will work for me too

On Wed, Jan 20, 2010 at 8:21 AM, Lionel Port lionel.p...@gmail.com wrote:

 The gae security restriction looks pointless because
 Objects.cloneModel is just using a ByteArrayOutputStream (why should
 there be restrictions on that?) but because the Objects calls are all
 static I can't override the method with a working clone method also
 because the OrderByLink.sort method is final I can't fix there either.

 As a workaround for any one who is interested, it looks like
 cloneModel is only used in this case if the component is versioned so
 I set called setVersion(false) on the orderByLink and it avoids this
 problem area.

 On Wed, Jan 20, 2010 at 12:32 PM, Lionel Port lionel.p...@gmail.com
 wrote:
  Hi,
 
  I'm using wicket on google app engine and am having trouble with the
  sort link headers on data tables.
 
  It looks like when a sort link is clicked the method
  Objects.cloneModel() is called. This creates a
  ReplaceableObjectOutputStream wrapper around the ObjectOutputStream to
  do the copy using serialization/deserialization. Unfortunately this
  class tries to call enableReplace on the the underlying
  ObjectOutputStream so that it can replace component objects with just
  their name (to stop component hierachy being serialized).
 
  It seams the google app engine security permissions deny calling
  enableReplace on the ObjectOutputStream.
 
  Does any one know of a work around to get the sort links working?
 
  regards,
  Lionel
 

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




-- 
Pedro Henrique Oliveira dos Santos


Re: Objects.cloneModel() on google app engine

2010-01-20 Thread Lionel Port
Thanks Pedro,

Hope it helps. From your answer looks like we may have a slightly
different problem with the same cause. Looks like the cloneModel()
method is depended on from a couple of spots but it all related to
versioning of components. Ideally it would be good if we could just
replace the implementation of cloneModel with one that works on GAE.
Anyway I'll stick with this for now till it comes and bites me again.

regards,
Lionel

On Wed, Jan 20, 2010 at 9:26 PM, Pedro Santos pedros...@gmail.com wrote:
 Thank u! that will work for me too

 On Wed, Jan 20, 2010 at 8:21 AM, Lionel Port lionel.p...@gmail.com wrote:

 The gae security restriction looks pointless because
 Objects.cloneModel is just using a ByteArrayOutputStream (why should
 there be restrictions on that?) but because the Objects calls are all
 static I can't override the method with a working clone method also
 because the OrderByLink.sort method is final I can't fix there either.

 As a workaround for any one who is interested, it looks like
 cloneModel is only used in this case if the component is versioned so
 I set called setVersion(false) on the orderByLink and it avoids this
 problem area.

 On Wed, Jan 20, 2010 at 12:32 PM, Lionel Port lionel.p...@gmail.com
 wrote:
  Hi,
 
  I'm using wicket on google app engine and am having trouble with the
  sort link headers on data tables.
 
  It looks like when a sort link is clicked the method
  Objects.cloneModel() is called. This creates a
  ReplaceableObjectOutputStream wrapper around the ObjectOutputStream to
  do the copy using serialization/deserialization. Unfortunately this
  class tries to call enableReplace on the the underlying
  ObjectOutputStream so that it can replace component objects with just
  their name (to stop component hierachy being serialized).
 
  It seams the google app engine security permissions deny calling
  enableReplace on the ObjectOutputStream.
 
  Does any one know of a work around to get the sort links working?
 
  regards,
  Lionel
 

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




 --
 Pedro Henrique Oliveira dos Santos


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



Objects.cloneModel() on google app engine

2010-01-19 Thread Lionel Port
Hi,

I'm using wicket on google app engine and am having trouble with the
sort link headers on data tables.

It looks like when a sort link is clicked the method
Objects.cloneModel() is called. This creates a
ReplaceableObjectOutputStream wrapper around the ObjectOutputStream to
do the copy using serialization/deserialization. Unfortunately this
class tries to call enableReplace on the the underlying
ObjectOutputStream so that it can replace component objects with just
their name (to stop component hierachy being serialized).

It seams the google app engine security permissions deny calling
enableReplace on the ObjectOutputStream.

Does any one know of a work around to get the sort links working?

regards,
Lionel

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