Hi Xavier,
thanks for your effort but please don't take too much time investigating my
issues :-)
I'm using wicket 1.3.0-beta3 and wicketstuff push... well since it doesn't
show the svn version numbers the version of monday this week. Yesterday I
had a more thorough look into what's exactly happening i.e. how the push
project interacts with the wicketstuff dojo project and integrates cometd.
There I found out that in order to communicate with wicket there's an extra
round trip to the server taking place. So the channel sends a message to the
client-javascript (including the data to be shown on page) which then makes
an ajax call back to the server where the data gets rendered into xml and is
then shown on the page. I wondered if that was intentional and if yes, what
purpose it serves.
For my project I've changed the java-script function which starts the AJAX
call sothat it renderes the message to proper javascript and directly
inserts it in the document's DOM without making an additional call. This
however, makes the server site less flexible as only a javascript string can
be processed on client site - but that's ok for my app.
Xavier Hanin wrote:
>
> Michael,
>
> As I said I don't use the ChannelService myself, but I used to have
> similar
> troubles with the PushService, which I think I finally fixed, but it
> wasn't
> easy. Since the fix is in TimerChannelBehavior (which is used by both the
> push and channel timer based implementation, it should work for both, but
> I
> haven't tested. Can I ask which version of wicket and wicketstuff-push
> you're using, and also which implementation of IChannelService? If you
> want
> to investigate in the code, the core of the fix relies on the redirect and
> setRedirectId in TimerChannelBehavior.
>
> Xavier
>
> On 10/24/07, Michael Sparer <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi Xavier,
>>
>> first of all thank you for the effort you've done for the push-project.
>> Up
>> to now it really provided the features I need for my app. But now I'm
>> kind
>> of stuck. My problem is: I have two panels on one page. Both panel
>> subscribe
>> themselves as ChannelListener for the same channel. But unfortunately
>> whenever an event invoking the listeners occurred, the onEvent method
>> gets
>> executed twice on both listeners (i.e. four times). It occurrs only if
>> you
>> have two panels i.e. two listeners on the same page.
>>
>> IMO the error is somewhere in the javascript where a function gets
>> executed
>> twice...but I haven't found it so far. So do you have any clue?
>>
>> thanks
>>
>> Michael
>>
>> Xavier Hanin wrote:
>> >
>> > On 10/23/07, Michael Sparer <[EMAIL PROTECTED]> wrote:
>> >>
>> >>
>> >> Hi Xavier,
>> >>
>> >> thanks for your reply - well yes, that's certainly right. I've just
>> lost
>> >> sight of it. But I got another question: how stable is the
>> >> wicketstuff-push
>> >> project or what sections are stable and which have to be improved for
>> use
>> >> in
>> >> a professional webapp?
>> >
>> >
>> > AFAIK wicketstuff-push is developed by vincent demay and myself.
>> Vincent
>> > worked on the cometd channel implementation, and I've worked mostly on
>> the
>> > timer based IPushService implementation (where events do not come from
>> the
>> > client at all). I don't know how stable is the channel implementation
>> > since
>> > I don't use it myself, maybe Vincent could give more details (not sure
>> if
>> > it's used in production or not). For the IPushService implementation,
>> it
>> > still requires more testing and improvements, because the problem is
>> not
>> > easy to solve with a timer based polling implementation: we have to
>> detect
>> > clients disconnection, and also handle back button where pages go back
>> to
>> > life from the a serialized form. And we also need to work on a comet
>> based
>> > implementation of this push service. So I think there's still need for
>> > improvement and bug fixing in this section.
>> >
>> > BTW, I've just checked in an improvement about this problem of page
>> > deserialization which required an API change for the IPushService. If
>> you
>> > plan to use it, do not forget to do an svn update.
>> >
>> > Xavier
>> >
>> > thanks in advance
>> >>
>> >> Michael
>> >>
>> >> Xavier Hanin wrote:
>> >> >
>> >> > On 10/22/07, Michael Sparer <[EMAIL PROTECTED]> wrote:
>> >> >>
>> >> >>
>> >> >> Hi,
>> >> >>
>> >> >> today I wondered if there's a wicket-approach for pushing messages
>> >> from
>> >> >> the
>> >> >> server to the client (also called reverse ajax or pushlets). Well
>> yes,
>> >> >> there
>> >> >> is one called wicketstuff push. I looked at its examples and soon
>> >> managed
>> >> >> to
>> >> >> implement my own pushing stuff. In the examples (chat-example)
>> >> however,
>> >> >> the
>> >> >> ChannelService that delivers the messages to its listeners, is
>> stored
>> >> in
>> >> >> the
>> >> >> application. I.e. there is only one channel for the whole
>> application.
>> >> >> Now imagine I want to create an additional private-chat-room for
>> two
>> >> >> users
>> >> >> --> I'd need a ChannelService only for two users. So my question
>> is:
>> >> >> what's
>> >> >> the wicket way to pass and store such an object which is applicable
>> >> only
>> >> >> for
>> >> >> two users (sessions)?
>> >> >
>> >> >
>> >> > You can use an application wide ChannelService and use the channel
>> name
>> >> > ("chat/message" in the example) to isolate messages by
>> >> private-chat-room.
>> >> >
>> >> > Xavier
>> >> >
>> >> > Thanks in advance
>> >> >>
>> >> >> Michael
>> >> >>
>> >> >> --
>> >> >> View this message in context:
>> >> >>
>> >>
>> http://www.nabble.com/wicketstuff-push-and-sharing-an-IChannelService-tf4671463.html#a13345278
>> >> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >> >>
>> >> >>
>> >> >>
>> ---------------------------------------------------------------------
>> >> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >> >>
>> >> >>
>> >> >
>> >> >
>> >> > --
>> >> > Xavier Hanin - Independent Java Consultant
>> >> > http://xhab.blogspot.com/
>> >> > http://ant.apache.org/ivy/
>> >> > http://www.xoocode.org/
>> >> >
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/wicketstuff-push-and-sharing-an-IChannelService-tf4671463.html#a13358479
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> >> For additional commands, e-mail: [EMAIL PROTECTED]
>> >>
>> >>
>> >
>> >
>> > --
>> > Xavier Hanin - Independent Java Consultant
>> > http://xhab.blogspot.com/
>> > http://ant.apache.org/ivy/
>> > http://www.xoocode.org/
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/wicketstuff-push-and-sharing-an-IChannelService-tf4671463.html#a13381208
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>
>
> --
> Xavier Hanin - Independent Java Consultant
> http://xhab.blogspot.com/
> http://ant.apache.org/ivy/
> http://www.xoocode.org/
>
>
--
View this message in context:
http://www.nabble.com/wicketstuff-push-and-sharing-an-IChannelService-tf4671463.html#a13401455
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]