| Perfil de PaulioIT BytesBlogListasScraps | Ajuda |
|
23 de julho Problems using a Blend project after upgrading to Silverlight Beta 2 I just ran into an annoying issue after upgrading to Silverlight Beta 2. Time for a story... Machine had Blend pre-beta 2 and had created a SL application. Along came beta 2 and Blend was un-installed and the latest version of Blend installed. Old Blend project was manually copied and pasted (see previous post on Blend and Beta 2) into a new Blend project, built and tested. .xap and default.html copied over to web server. When default.html was opened the page displayed the Get Silverlight banner even though the browser had the correct Silverlight. Clicking Get displayed a site saying that the site was using an old version of Silverlight. So I took the source files from Blend and opened them on a machine with Visual Studio + beta 2 toolkit. This told me that the project needed upgrading (eh and why?) so I let it and built the project. Deployed it to the web site and everything worked fine! Not sure what happened there but I'm suspicious of only having Blend on a machine, I'm not ruling out some manual mess-up but why would the Blend build not raise the problem? Oh well, I''ll put it down to beta fun. 14 de julho Browser speed wars, it's not all about rendering After reading a quick performance guide to the various new browser engines it struck me that it has missed another aspect, that I just happen to have been experimenting with...that of caching. A current customer I'm working with has some issues with poor performing and unreliable download speeds. With this in mind I've examined how three of the common browsers deal with caching, after all if you can cache a resource then the download speed becomes far less important. Using IIS6 I created a simple HTML page with containing a page of text, a single jpg and a link to a stylesheet. The page expiration is set to a year in the future and with the Etags both on and off. The results were a little surprising; Internet Explorer (6,7,8) is determined not to be caught out by changes on the server. First off I do a hard refresh and what the network traffic. Every resource is returned to the browser "as new" from GETs with lots of "200 ok" responses from the server. With every subsequent refresh IE asks the server if the resource has changed, resulting in a "304 not modified". So IE creates a server roundtrip which is small, however, is it necessary? I've specifically provided a expiration date so why is it ignoring me? Interestingly if you shut the server down, IE will ask for the server and then realise it's not there and just server up the cached version. So what happens if I change any of the resources? Well since IE asks the server each time, IE reflects the changes immediately. This is good news if you change your "static" content but not great for my customer! Firefox (3) provides a very nice compromise. As with IE the hard refresh returns all the resources. The next two requests seems to see Firefox continue to behave like IE with it asking for changes. However, after the 2nd refresh FF seems to accept that the resources are not changing and stops making server roundtrips until the item hits the expiry date. To be absolutley accurate, FF did seems to occasionally check for changes but very, very infrequently. If the server drops FF continues to server up the resource from the cache. This is good news for my customer since the server roundtrips are almost cut to zero. Safari (3.1.1.) works pretty much like IE, with the exception of when the server is down no page is rendered...boo. To give you some idea of the difference in speeds because of this caching/non-caching behaviour I ran my tests against the BBC's main news page, news.bbc.co.uk. The total time to return all the resources for a hard refresh for IE and FF was ~3.5s consisting of some 87 requests. The next two refreshes remained at 87 requests but were mainly the "has it changed" request resulting in better performance ~2.5s. However, the next refresh saw FF shine. IE remained at 87 requests and ~2.5s whereas FF, relying on its cache, only made 17 requests taking a mere 700ms. Ok ok so this doesn't take into account the rendering speed, but rendering speed does not improve your download speeds, caching can fake that improvement. So at the moment I have FF ahead of IE. I've yet to test Opera and I have to say that Safari does render very quickly but sort out your caching Web Kit! NB. If this is very important to your business please run the tests yourself, I found the following to be useful tools; FireBug's net performance tab; Fiddler2 and WireShark. 13 de julho Installing Kaspersky antivirus on Parallels running Vista Parallels "comes with" Kaspersky anti-virus software and since I'd had a few issues with AVG on my Vista host I decided that at least Kaspersky must have been tested to run on Parallels. Why do I make these assumptions? ;) Anyway to install it you simply select the menu item from Parallels. It tells you it will reboot and sure enough it does. But then nothing else happens. I tried this a couple of times and no sign of a Kaspersky tool anywhere. So I tied it again but this time I didn't allow the autorun to...run. I then right-clicked on the setup exe (kissexe or something) and said 'run as administrator'. That rebooted but this time it acutally installed. Hurray....good grief. Virus checkers, the good and bad I've previously written that I have grave doubts about Virus checkers. Well this weekend my g/f laptop (XP SP2) found itself under attack from the malware known as 'XP Antivirus 2008' - yes it's a genuine virus/malware masquerading as a anti-virus tool. Fortunatley Norton Anti-virus spotted it pretty quickly and did just enough to stop it causing too much damage. Although it didn't get rid of it completely it stopped it 'working' and with the additional help of Malwarebyte the system was soon cleaned. So 1:0 to the Virus checkers. However, the previous week my version of Vista running on the Mac via Parallels started to act very oddly. Visual Studio wouldn't compile properly, Task Manager wouldn't go away, Windows Update wouldn't...update. I quickly narrowed it down to AVG anti-virus not correctly updating. Every time I stopped it attempting to update everything else worked fine. So I tried to uninstall it, the uninstalled just stopped after about an 1 hour of doing very little. I rebooted in safe-mode and uninstalled it in an instant. Good ridance. Finally I can get back to using Vista...1:1. 07 de julho Problem connecting to an instance of a SQL Server Cluster I was asked to try and find out why a web server could not communicate with the database. After checking all the usual network configurations I was beginning to despair. Together with the sys-admin we started firing off telnet connections, pings, etc, all worked but still SQL clients failed to connect. Finally by luck more than judgement the sys-admin attempted to connect to the database without the SQL instance name. Viola it worked. It seems that when you make a clustered virtual server it forms an alias from both the server names *and* the instance name, i.e. MyServer\MyInstance simply becomes MyClusterServer. We hadn't had this problem on previous builds because we normally just have the default instance. 04 de julho Fun with IIS http compressionAh the wonderful world of System Administration. My first task of the day was test a site using HTTP compression. So I followed the instructions to turn on http compression in IIS6. What a wonderful mix of UI, XML file fiddling and vbs scripts that was...<good grief>. Finally I managed to start seeing the production of compressed files in IIS' folder. "Hurray, it's working", I foolishly thought. My specific test site just kept failing, nothing would render a page. So, like all "good" developers I set compression to global, i.e. all the sites and went to the default iisstart.htm to see if that was ok. Sure enough the compressed version of it appeared in the IIS folders and IE7 rendered it without any fuss. "Hurray, it's working"...I foolishly thought. Firefox 3 just stubbonly says, 'The page you are trying to view cannot be shown because it uses an invalid or unsupported form of compression'. However, it looks like that happening on a number of sites with FF3. So I tried Safari. What a joke, doesn't seem to want to see the page at all, moaning about a domain error. Opera 9.5, to the rescue, it acutally rendered both my test page and the iisstart.htm. Well I say rendered, it just showed me the contents of compressed file, i.e. it hasn't bothered to uncompress it! Chocolate fire-guard anyone? So time to admit defeat and go off to the TechNet forum. Oh it just keeps giving. I tried to login, complained that my account hasn't been verifyed, even though I used it about 1 year ago now. So I thought I'd register again. Every character I typed threw up a javascript error with IE asking if I wanted to debug it. What a waste of time.
So all in all my first professional brush with IIS6 compression has been...less than satisfactory.
[Edit]
I've since tried download ZipEnable from Port80 which didn't help, but then I copied the settings from http://www.codinghorror.com/blog/archives/000059.html and finally it started to work, all the browsers too.
01 de julho More Microsoft AJAX viewsI do have a tendancy to get annoyed when I think about Microsoft's web offerings of ASP.NET and more recently their AJAX libraries. I've had a little rant about it before but I thought Adam Kahtava has written a good post on the AJAX side of things here, The ASP.NET AJAX Framework is for DUMMIES!
I'm not sure I'd go so far as to say the library itself is bad, IMO it has a lot in common with Prototype, but I certainly feel the pain of pandering after the server controls. Although there are a number of "pure" AJAX libraries to choose from some also have projects/extensions to help with server controls, e.g. http://www.codeplex.com/YuiDotNet, so maybe you can move to another library without leaving the server controls behind.
|
|
|