PDA

View Full Version : [CLOSED] Settings and tips for performance improvement



MTSI
Mar 14, 2014, 10:24 AM
We are seeing lot of performance issues when using ext.net controls compared to normal HTML. Is there a way or any settings to optimize the performance?

Daniil
Mar 14, 2014, 11:36 AM
Hi @MTSI,


We are seeing lot of performance issues when using ext.net controls compared to normal HTML.

If you can post two examples - one with raw HTML, another with Ext.NET controls - with the same functionality and view, we would be happy to investigate.


Is there a way or any settings to optimize the performance?

There is a few links:
http://forums.ext.net/showthread.php?13726
http://forums.ext.net/showthread.php?15699&p=66265&viewfull=1#post66265
http://www.sencha.com/blog/ext-js-4-1-performance/
http://www.sencha.com/blog/optimizing-ext-js-4-1-based-applications
http://www.sencha.com/forum/showthread.php?153565-ExtJS-Performance-Best-Practices

MTSI
Mar 15, 2014, 11:55 AM
The below sample code which is a plain html with some ext.net controls. This page is taking approx 4 sec to render in IE8 and 2 secs in Chrome which unacceptable with to server side processing.



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><META content="IE=8.0000" http-equiv="X-UA-Compatible">
<TITLE>My Dashboard</TITLE>
<META content="text/html; charset=utf-8" http-equiv=Content-Type><LINK
id=ext-theme rel=stylesheet type=text/css
href="Dashboard_files/ext.css"><LINK rel=stylesheet
type=text/css href="Dashboard_files/ext(1).css">
<SCRIPT type=text/javascript
src="Dashboard_files/ext.axd"></SCRIPT>

<SCRIPT type=text/javascript
src="Dashboard_files/ext(1).axd"></SCRIPT>

<SCRIPT type=text/javascript>
//<![CDATA[
Ext.net.ResourceMgr.init({isMVC:true,theme:"gray",appName:"Website"});Ext.onReady(function(){Ext.create("Ext.Viewport",{renderTo:Ext.getBody(),items:[{id:"panelheader",border:false,html:"<div class='header'><div class='systemlogo'></div><div class='corplogo'></div><div class='header-bottom-bar'></div><div class='loginbar'></div></div>",region:"north",bbar:{id:"Toolbar1",xtype:"toolbar",margins:"0 0 4 0",items:[{id:"mnuJobCommon",iconCls:"#PageWhiteAdd",text:"Create New Job",listeners:{click:{fn:function(item,e){setTabConfi g({title: 'New Job', url:'welcome.htm', elementid: 'addeditjob', content: 'content'});}}}},{id:"ToolbarFill1",xtype:"tbfill"},{id:"InternalLink",iconCls:"#BookOpen",text:"Help"},{id:"tblsep3",xtype:"tbseparator"},{id:"changePassword",iconCls:"#Key",text:"Change Password",listeners:{click:{fn:function(item,e){setTabConfi g({title: 'Change Password', url:'welcome.htm', elementid: 'changepassword', content: 'content'});}}}},{id:"tblsep1",xtype:"tbseparator"},{id:"signOut",iconCls:"#DoorOut",text:"Sign Out(email1@gmail.com)",listeners:{click:{fn:onSignoutClick}}}]}},{id:"tpMain",xtype:"tabpanel",margins:"0 0 4 0",region:"center",items:[{id:"Dashboard",border:false,cls:"content",loader:{loadMask:{showMask:true,msg:"Loading dashboard..."},renderer:"frame",url:"welcome.htm"},padding:10,style:"background:#f5f4f4",title:"My Dashboard",iconCls:"#ApplicationHome"}],activeTab:0},{id:"panelfooter",border:false,html:"<div class='footer'><div class='privacy'></div> <div class='appversion'>1.2.0.20349</div></div>",region:"south"}],layout:"border"});Ext.net.ResourceMgr.registerIcon(["PageWhiteAdd","BookOpen","Key","DoorOut","ApplicationHome"]);});
//]]>
</SCRIPT>

<META name=GENERATOR content="MSHTML 8.00.6001.23543"></HEAD>
<BODY>
<DIV>

<SCRIPT language=javascript type=text/javascript>
var expiryWind = null;
var notification_test = null;
var helpUrl = '/Home/OnlineHelpToDownload';


var initialSessionTimeoutMessage = "You will be logged out of the system in <span id='sessionTimeoutCountdown'>30</span> seconds. If you want to keep your session active Click OK.";
var sessionTimeoutCountdownId = 'sessionTimeoutCountdown';
var redirectAfter = 30; // number of seconds to wait before redirecting the user
var running = false; // var to check if the countdown is running
var timer2;
var timeOut = false;
var redirectTo = '/Login/Authenticate';

var onSignoutClick = function (item, e) {

}

function ShowPopUp(counter) {
}

function PopupCenter(url, title, w, h) {

}


</SCRIPT>
</DIV>

</BODY></HTML>

geoffrey.mcgill
Mar 15, 2014, 11:01 PM
This code sample looks strange.

Is Ext.NET rendering the following line?


<SCRIPT type=text/javascript src="Dashboard_files/ext.axd"></SCRIPT>

Ext.NET and Ext JS are not supported in IE Compatibility mode, so you should switch that off.

Are you testing in an IE8 simulator? What are your results if testing in a native machine running native IE8?

You could also try setting RenderScripts="CDN" on the <ext:ResourceManager>. That will pull the .js files from the CDN, which could theoretically speed things up a little.

You should also be using the HTML5 doctype.

Why are all the tags in your sample rendered in FULL CAPS?

Are you loading any other .js files into that page? Why is there that unrelated inline JavaScript rendered in the Page?

Please provide us with the simplified code sample you used to generate this sample Page.