ASP Components & Efficiency

Results 1 to 4 of 4

Thread: ASP Components & Efficiency

  1. #1
    Scott S Guest

    Default ASP Components & Efficiency

    I am writing an messageboard component, it will be similar to this one in look & feel. basically I&#039m doing this for the practice, i had an old asp script that threaded messages from an access database. This component is using an SQL 7 db instead of access & is a component instead of scripts to make it more robust.<BR><BR>My question is, when building the Message threads with replys & things, is it faster to send them directly from the component? I would do this by referencing the "Microsoft Active Server Pages Object Library" from Visual Basic. <BR>then i could build and display the messageboard/threads directly without having to send a large variable back. <BR>it would work something like this:<BR><BR>Dim oResponse as Response<BR><BR>oResponse.Write SomeVariable<BR><BR><BR><BR>or is it faster to put them all into a large variable and pass that back to the asp script? which is more "expensive" to execute? Which would be more robust?

  2. #2
    Ian Stallings Guest

    Default RE: ASP Components & Efficiency

    My gut feeling is that writing directly from the component would be a cheaper solution but I have no data to back this up. Maybe you should test both methods using a performance test and see which one uses more memory, processing %, etc. This might not be the quickest solution but it certainly would clarify which is the better method, if any.<BR><BR><BR>Ian Stallings

  3. #3
    Jason Miller Guest

    Default RE: ASP Components & Efficiency

    According to Microsoft (URL below)...<BR><BR>"Do not register your component with MTS unless you need transactions. ObjectContext can be expensive in terms of performance. [afaik, ObjectContext requires that the .dll be registered in MTS -- please give me lots of info on MTS if I&#039m wrong; I freely admit I don&#039t know enough about MTS]<BR><BR>Do not use OnStartPage and OnEndPage methods to access the ASP intrinsics. These methods are provided for legacy support with Internet Information Server (IIS) 3. Use ObjectContext. However, if you have an ActiveX EXE, then you cannot use ObjectContext and must use OnStartPage."<BR> <BR>-- From<BR><BR>Practically, I use the component. In terms of portability, it&#039s more robust since there&#039s less exposed to the developer-users for them to break (#1 concern for me). I haven&#039t done massive testing, but on my little tests, I haven&#039t seen performace loss when using a context-enabled component. <BR><BR>How any of this weighs for IIS 5, I really don&#039t know.<BR><BR>HiH, <BR>Jason

  4. #4
    Tomas T Guest

    Default RE: ASP Components & Efficiency

    This is a very valid question.<BR><BR>Writing directly to the response stream from the component is probably faster but it won&#039t scale as good as a true three-tier solution. Therefore you should try to use the ASP objects only from an ASP file.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts