zk vs gwt zk太多请求 [英] zk vs gwt zk too many requests

查看:135
本文介绍了zk vs gwt zk太多请求的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好我正在比较zk和gwt的性能。



在我的比较中,如果框架本身将某些代码转换为js,我无法自己写任何javascript它的好(像gwt),但我不能自己写js



在以上述方式编写代码时,几乎在浏览器上执行的任何操作都会将请求发送到ZK服务器。

因此,最终如果比较由zk发送给服务器的请求数量与gwt相比太高。



我想问下面的问题。


  1. 在忽略上述情况下,其性能更好zk或gwt。 b $ b
  2. 如果我们不忽略上述情况,那么我的结论是gwts性能比zk好吗?

我知道在比较性能时可能还有其他参数......但是如果请求之间的差异如此之高,我无法真正看到zk击败gwt,有些人在一些论坛上说过。

请帮助
谢谢

解决方案

以前的帖子是基本的,但我认为必须讨论zk中的一些功能。
记住,每个请求都是一个zk事件,cos zk完全是基于事件的。


  1. 客户端事件处理

    Zk允许你实现客户端事件处理以及服务器端
    ,其中包括阻止zk向服务器发送事件。

    你可以简单地操作js中的客户端对象

    可以在
    服务器端以Java方式执行,也可以只做一些后处理,然后...

  2. <一个href =http://books.zkoss.org/wiki/ZK%20Client-side%20Reference/Communication/AU%20Requests/Client-side%20Firing =nofollow>使用客户端事件触发

    Zk得到了有用的js方法 zAu.send(zk.Event,int),让您发送自定义
    或标准事件发送到服务器。

  3. 可延迟的事件监听器

    延迟事件在客户端排队,所以你可以减少
    请求的数量。


  4. Stubonly Stubonly是一种仅用于构建客户端组件的方法。但现在只有
    可用于 zk EE



  5. 因此,你可以看到,如果你愿意,你可以将请求限制为GWT请求数量相同。

    If它对您/您的申请有意义或不适用。但是我认为你可以说zk比GWT更强大。

    你可能对 iZUML 推迟渲染也是如此。


    Hi I am trying to compare the performance of zk and gwt.

    In my comparision I cant write any javascript by myself if the framework itself converts some code into js its ok(like gwt) but I cant write js by myself

    On writing code in the above way for almost anything done on browser a request is sent to the server in ZK.

    Hence eventually if you compare the no of request sent by zk to server is too high as compared to gwt.

    i would like to ask the following.

    1. whose performance is better zk or gwt while ignoring the above.
    2. if we dont ignore the above then is my conclusion that gwts performance is better than zk right ?

    I know that there might be other parameters when comparing performance... but if the difference between requests are so high i cant really see zk beating gwt which some people have said on some forums

    pls help thanks

    解决方案

    The previous posts are basiclly, but there are some features in zk that,I think, must be talked about.
    Remember, every request is a zk-event, cos zk is completely event-based.

    1. Client-Side Event-Handling
      Zk allows you to implement client-side event-handling just as well as server-side, which includes preventing zk from firing an event to the server.
      You can simple manipulate the client objects in js as you can do it in Java on the server-side
      or just do some post processing and and then...

    2. Use Client-Side Event-Firing
      Zk got that usefull js method zAu.send(zk.Event,int) that let's you send custom or standart events to the server.
    3. Deferrable Event-Listeners
      Deferrable-events are queued at client-side, so you can minimize the number of requests.
    4. Stubonly
      Stubonly is a way to make a component client-side only. But by now this is only available for zk EE.

    So, you can see, if you like, you can limit the requests to maybe the same amount of requests of GWT.
    If it make sense or not depandce on you/your applycation. But I think you can say that zk is more powerfull than GWT.
    You maybe interested in iZUML and defer rendering too.

    这篇关于zk vs gwt zk太多请求的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆