Server Workload!

Discussion in 'ASP .Net' started by Arpan, Nov 27, 2004.

  1. Arpan

    Arpan Guest

    I am a newbie in ASP.NET (using VB.NET) & work on Windows 2000 Professional.

    I find that the client browser just doesn't play any role other than rendering the page in HTML & the server does all the work. Even the various HTML/Web controls are validated by the server. So ASP.NET relying so much on the server to do even a small task - doesn't this put extra load on the server & in the process,slow down the retrieval time of ASPX pages? A Form can easily be validated using a client-side script like JavaScript (wherein the server has no idea of those validations). Now since the onus of validating the different Form fields is on the client, the result is instantaneous. For e.g. if a user submits a Form without providing his name, an alert message box will get generated at once telling him to enter his name. This not only will ensure that the client needn't "talk" to the server every now and then & increase the workload on the server which may be catering to hundreds of requests at that time but also will minimize users' time during the transaction. Or is it something like the benefits of ASP.NET far outweigh its drawbacks & deficiencies?

    The validation part is just an example I have cited.

    Thanks,

    Arpan
    Arpan, Nov 27, 2004
    #1
    1. Advertising

  2. You can let the client validate the input - it is actually directly supported by controls such as RegularExpressionValidator or CustomValidator.
    CustomValidator will let you specify a client-side script to execute.

    Doing validation does make the server work a little bit more and probably should be done on the client as well. I say as well because not doing it on the server opens up for SQL Injection for example.

    If there are any drawbacks with ASP.NET I don't know about them...
    I've used both ASP, ASP.NET and PHP and think that ASP.NET is the best of all of them. PHP is a good alternative for small sites, but as soon as the site grows it becomes harder to maintain. An ASP.NET site if built properly will generate almost the same amount of work regardless of it's size (of course a site on the Microsoft scale would be more to maintain than the local zoo website)

    // Fredrik
    "Arpan" <> wrote in message news:...
    I am a newbie in ASP.NET (using VB.NET) & work on Windows 2000 Professional.

    I find that the client browser just doesn't play any role other than rendering the page in HTML & the server does all the work. Even the various HTML/Web controls are validated by the server. So ASP.NET relying so much on the server to do even a small task - doesn't this put extra load on the server & in the process,slow down the retrieval time of ASPX pages? A Form can easily be validated using a client-side script like JavaScript (wherein the server has no idea of those validations). Now since the onus of validating the different Form fields is on the client, the result is instantaneous. For e.g. if a user submits a Form without providing his name, an alert message box will get generated at once telling him to enter his name. This not only will ensure that the client needn't "talk" to the server every now and then & increase the workload on the server which may be catering to hundreds of requests at that time but also will minimize users' time during the transaction. Or is it something like the benefits of ASP.NET far outweigh its drawbacks & deficiencies?

    The validation part is just an example I have cited.

    Thanks,

    Arpan
    Fredrik Elestedt, Nov 27, 2004
    #2
    1. Advertising

  3. Arpan

    ampra Guest

    Arpan,
    I important point that comes to my mind is that a lot of users have started disabling their "enable script to run" option in their browser because "virus-makers" have exploited that feature to run "hidden" scripts.
    In my opinion, a good programming practice would be to use client side scripting alongwith Server-side validation.

    thanks,
    ampra
    "Arpan" <> wrote in message news:...
    I am a newbie in ASP.NET (using VB.NET) & work on Windows 2000 Professional.

    I find that the client browser just doesn't play any role other than rendering the page in HTML & the server does all the work. Even the various HTML/Web controls are validated by the server. So ASP.NET relying so much on the server to do even a small task - doesn't this put extra load on the server & in the process,slow down the retrieval time of ASPX pages? A Form can easily be validated using a client-side script like JavaScript (wherein the server has no idea of those validations). Now since the onus of validating the different Form fields is on the client, the result is instantaneous. For e.g. if a user submits a Form without providing his name, an alert message box will get generated at once telling him to enter his name. This not only will ensure that the client needn't "talk" to the server every now and then & increase the workload on the server which may be catering to hundreds of requests at that time but also will minimize users' time during the transaction. Or is it something like the benefits of ASP.NET far outweigh its drawbacks & deficiencies?

    The validation part is just an example I have cited.

    Thanks,

    Arpan
    ampra, Nov 27, 2004
    #3
  4. If the user turns off JavaScript, they may as well forget about an ASP.Net
    web site. It just won't work properly. ASP.Net relies upon JavaScript for
    far more than form validation. JavaScript is central to the Event model that
    ASP.Net uses to connect client-side events to server-side event handlers.

    --
    HTH,
    Kevin Spencer
    ..Net Developer
    Microsoft MVP
    Neither a follower
    nor a lender be.

    "ampra" <> wrote in message
    news:...
    Arpan,
    I important point that comes to my mind is that a lot of users have started
    disabling their "enable script to run" option in their browser because
    "virus-makers" have exploited that feature to run "hidden" scripts.
    In my opinion, a good programming practice would be to use client side
    scripting alongwith Server-side validation.

    thanks,
    ampra
    "Arpan" <> wrote in message
    news:...
    I am a newbie in ASP.NET (using VB.NET) & work on Windows 2000
    Professional.

    I find that the client browser just doesn't play any role other than
    rendering the page in HTML & the server does all the work. Even the various
    HTML/Web controls are validated by the server. So ASP.NET relying so much on
    the server to do even a small task - doesn't this put extra load on the
    server & in the process,slow down the retrieval time of ASPX pages? A Form
    can easily be validated using a client-side script like JavaScript (wherein
    the server has no idea of those validations). Now since the onus of
    validating the different Form fields is on the client, the result is
    instantaneous. For e.g. if a user submits a Form without providing his name,
    an alert message box will get generated at once telling him to enter his
    name. This not only will ensure that the client needn't "talk" to the server
    every now and then & increase the workload on the server which may be
    catering to hundreds of requests at that time but also will minimize users'
    time during the transaction. Or is it something like the benefits of ASP.NET
    far outweigh its drawbacks & deficiencies?

    The validation part is just an example I have cited.

    Thanks,

    Arpan
    Kevin Spencer, Nov 27, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark Kamoski
    Replies:
    7
    Views:
    8,615
    Mark Kamoski
    Aug 9, 2003
  2. Hazzard
    Replies:
    2
    Views:
    530
    Yan-Hong Huang[MSFT]
    Jul 23, 2003
  3. =?Utf-8?B?UGVyZG8=?=
    Replies:
    0
    Views:
    570
    =?Utf-8?B?UGVyZG8=?=
    Feb 6, 2004
  4. -
    Replies:
    2
    Views:
    386
    Alan Krueger
    Jul 29, 2005
  5. Ted
    Replies:
    30
    Views:
    321
    smallpond
    Feb 26, 2008
Loading...

Share This Page