Recent Comments


re: Setting up and using Bing Translate API Service for Machine Translation
Friday @ 5:56pm | by Rick Strahl

@Mario - the data is JSON and UTF-8 encoded. The delta sign is part of a UTF-8 sequence to represent an extended character. Not sure how you're capturing the data, but if you're using an HTTP client that doesn't automatically decode data you'll need to do the UTF-8 decoding explicitly.
re: Setting up and using Bing Translate API Service for Machine Translation
Friday @ 12:18am | by Mario Vernari

Rick, ask MS to thank you, because I was throwing all the code in the can.
I really couldn't agree more on the blurry yet few-documented APIs. I needed a trivial C# Console example, but the only one I've found it looks obsolete.
You gave me (us) some very useful tip on how to use those APIs.

Maybe it's worthwhile to mention some trouble I've found related to "strange" characters in the string. In the specific, I tried to send a Greek-delta sign in the string, but it is always treated as a "?".
Hints?

Thank you anyway and good luck!
re: ASP.NET Frameworks and Raw Throughput Performance
Thursday @ 1:25pm | by Spencer

The services we are building are async and have db calls within them, but the dbs run on dedicated servers separately, so there is always a bit of waiting in them. I was basically just doing some simple test runs to get a basic idea of how many servers we were going to need to support N users simultaneously. When i hit the snag with the real services i setup some cookie cutter ones including using your test solution to see what the raw performance would be with minimal dependencies.

I thought i turned off the anti-virus, but i guess it had turned itself back on my personal box. :-) The numbers are now hitting around 6k for the raw service calls on my personal box. The interesting thing is i don't remember seeing anti virus software running on our work server but there must be something running that is not obvious and was not showing itself in the task manager. Definitely the firewall was off but i'll have to do a bit more digging on that. Now at least i know i'm not crazy since i knew i'd seen higher numbers in the past. Thanks again for your input.
re: Adding Files to the Windows MRU/Recent Document List
Wednesday @ 3:04pm | by Rick Strahl

@Jerome, thanks for the heads up on the Charset.Ansi flag.

As to the scroll-resizing that's on purpose. Once you scroll past the sidebar content the screen widens to give you more space for text and images. I find that useful for my own reading - didn't think it annoying, but curious if others think the same thing. Not such a big deal on big screens but certainly nice when you're on a tablet.
re: Adding Files to the Windows MRU/Recent Document List
Wednesday @ 5:01am | by Jerome Viveiros

Very nice. I've used SHAddToRecentDocs before, since my app was a tool capable of viewing other app's file types, but this only worked for the global Windows Recent Files list in Windows 7. I had no idea of all the steps required to do this with my own file types, so this will come in very handy.

It may be worth adding, for the sake of anybody who takes MS code analysis warnings seriously, that the character set passed *must* be CharSet.Ansi; otherwise the function will fail. My pinvoke declaration looked like this:
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Globalization", 
    "CA2101:SpecifyMarshalingForPInvokeStringArguments", MessageId = "1"),
DllImport("shell32.dll", CharSet = CharSet.Ansi)]
public static extern void 
    SHAddToRecentDocs(ShellAddToRecentDocsFlags flag, 
    [MarshalAs(UnmanagedType.LPStr)] string path);


Also, since I'm a new reader here, I don't know if anyone else has mentioned, but when you scroll down this blog in Firefox and Chrome (but not IE), when you scroll past the bottom of the content populated in the left pane, the right one animates and scrolls to the left to take up the whole width. It's cool, but <em>really</em> distracting.
re: Updated DeleteFiles Utility now on Chocolatey
Tuesday @ 3:55am | by Uwe

Thanks for using (and mentioning) my long path library!
re: ASP.NET Frameworks and Raw Throughput Performance
April 12, 2015 @ 9:49pm | by Rick Strahl

@Spencer, it sounds like you're hitting IO limitations (CPU not maxed). What are you doing in your own tests? If you hit a database as part of testing your request/sec is going to drop drastically.

So I would first set up basic helloworld requests and test those just to see the max throughput you could possibly expect.

Also make sure to turn of Anti-Virus/Firewall software while running these tests. They can drastically slow down and throttle requests especially if you run to custom non-80 ports.
re: ASP.NET Frameworks and Raw Throughput Performance
April 12, 2015 @ 3:10pm | by Spencer

Great article. i pulled down this code to do some comparisons on web api performance. I was seeing insanely slow RPS of around 170 on my work laptop using my code with the service hosted locally. So i downloaded this and didn't see much of an improvement. I then put this same code on my desktop at home which is running a i7-2600K 3.4Ghz quad core with 24 gigs of ram. the cpu never gets up over 60% but the RPS only hits around 600 RPS using anywhere from 20 to 100 concurrent users and the hosting type never seem to make much difference. I know i've seen multi thousand RPS numbers when building old asmx services but i'm scratching my head on whats causing the issue now. It seems like there is some unusual thread contention going on but i haven't dug too deep yet. Any ideas?
re: Hosting the Razor Engine for Templating in Non-Web Applications
April 12, 2015 @ 9:04am | by Iaacov

Hi Rick,

First, thanks for this great tool.

We successfully use the RazorHosting wrapper inside a Windows Service that delivers template-based emails.

The host container is started in the service OnStart event and stopped in OnStop.
The template runs in a separate AppDomain.

The problem arises when the service stays idle for more than 5 minutes. In this case the template's lifetime expires and doesn't compile any new code.

The RazorBaseHostContainer class has an InitializeLifetimeService method which, according to documentation, appears to exists for this purpose but I couldn't figure out how to use it.

Can you please explain me how to solve this problem?
re: Bitmap types, Binary Resources and Westwind.Globalization
April 12, 2015 @ 3:45am | by David McQuiggin

By the way Rick, I render my html for SPA views from MVC, for many reasons, but also due to the localisation scenario (HTML text, JavaScript messages, and Routes). Subsequently all data is handled via WebAPI. Its a very nice fit.
re: Bitmap types, Binary Resources and Westwind.Globalization
April 12, 2015 @ 3:10am | by David McQuiggin

@Rick - The View Models do not actually contain translations...

a) I use a class to contain read only properties for each 'key' that will be translated, e.g. 'RequiredFieldAttribute', which returns a value from a single method that detects the CurrentUICulture (you could easily pass that through in non-web scenarios), and returns the relevant value from a pass-through cache implementation which is injected.

b) When the T4 for ViewModels is run it creates default translations for all DataAnnotations in the database (if they do not already exist), and as it walks the Code Dom of the target namespace and processes the ViewModels for translatable values, if a translation does not exist in the database, an entry is created for the default culture, and an attribute that calls the Translate method for say, "DisplayName", is updated or added to the property in the View Model, with the relevant key.

Apart from that, the ViewModel is not altered. In fact I am actually in the process of testing a 'buddy class for meta data approach', which I have used for data annotations on DTOs, and may work out to be cleaner.

c) A similar approach is taken for Views, but it is a bit more messy as it has to work with token replacement rather than Code Dom, but it basically does the same thing, if an element has an HTML-5 data attribute that indicates it should be translated, then if it has existing text, that is added to the database, and a call to the ViewTranslations class is inserted in its place. Additionally, attributes to support in place translation are added, that are similar to the example you post above. They describe the editor type for Mercury editor, and the result is that there is design time alteration of code, runtime WYSIWYG editing of text, and good performance through caching, and requiring any custom model binders, custom base view pages, reflection etc.

d) I use T4 for several other things depending on the scenario - I derive constants for route names, controller and actions are callable by strongly typed, parameterised Url and Html.Action etc helpers (I dont use T4MVC as it far too heavy for my needs). I use other T4s to create 'strongly typed' AJAX calls to my controllers, to create client side model definitions from my View Models in TypeScript if I am creating an SPA, etc...

P.S Looking forward to seeing your article about use of your framework with SPAs!

David
re: Bitmap types, Binary Resources and Westwind.Globalization
April 11, 2015 @ 12:01pm | by Rick Strahl

@David - you get no argument from me when it comes to embedding binary resources - I wouldn't do it, but again it's something that is supported in native Resx so I have to support it. I was just curious if others are using embedded binary resources for anything whether it's images or text etc. If there's *anything* stored this way that has a good reason then the feature has to be there.

Luckily the choice of whether you use that particular functionality is entirely up to the developer and like you I would opt for external resources.

Thanks for bringing up your T4 implementation. Sounds interesting. Have you shared this anywhere? Sounds that would be really interesting to check out.

Personally I'm not a fan of T4 and code generation in general, but I like the idea that the model can hold translation values on it. Of course this would end up making the model much larger than usual because it would have to account for all translated values. And therein lies the rub. Ultimately I don't really want to have to do extra work other than embedding localized values into the UI *in one place*. I also would prefer that it works with plain HTML pages and not just with .NET related code.

I've been playing around with live editing of resources in different ways. The library has had support for WebForms and resource editing since WebForms actually had meta data that described the localization items. I had some logic that would find all the localized controls and then inject edit buttons into the page so you could jump to the appropriate item in the editor.

I've been thinking to do the same for MVC/HTML pages, but I realize that it won't be as smooth an implementation as the WebForms way because there's simply no metadata there - that would have to be embedded into the document. I've been thinking about an approach like this:

<body data-resource-set="MyPage">
<div data-resource-id="HelloWorld">@DbRes.T("HelloWorld")</div>
</body>


where these data-resource-xxx attributes are used by JavaScript to provide either pop up editors or link to the resource page. It adds extra noise but it would work for even plain HTML at least.
re: Bitmap types, Binary Resources and Westwind.Globalization
April 11, 2015 @ 3:36am | by David McQuiggin

Personally, although I admire the implementation, I agree with the suggestion that it is better to store a Uri or relative path.

For example, think of the situation where you will be using a Content Delivery Network... or a different media such as video.. a Uri can cope neatly with both scenarios. Typically I have uploaded such media content to Azure Blob storage, which is dirt cheap, with a database entry and a simple utility to allow me to manage them (crud operations on content). These can then be versioned, deployed to a CDN.

Slightly off-topic: I have found this to also be the case when investigating embedding Views, JavaScript etc in a DLL that could be used in a Plugin architecture; ultimately you have to add the complexity of locating, extracting and rendering the content, and you have to inflict custom view page base classes, custom resource handlers etc on *every* page or partial you are rendering, when in fact it is only required for a small percentage of an application. The same will most likely be true of images.

But its great library; I especially like your admin interface. I have a slightly different approach that ends up with the same result; I use T4 templates to scan ViewModels properties and meta data, validation messages, strings and HTML elements that have a specific HTML5 data element, which are replaceable tokens as I explain below.

This creates a relevant database entry with the default content in the invariant language, and a static class providing static fields for returning text according to a key, and that is localised from the database values via an injected provider that can offer different pass through cache options (NullCache, InMemoryCache, RedisCache). The T4 uses CodeDom FileDom to manipulate say the HTML, to replace the original content (of say a div), with a call to the static property of my 'Translations' class, and also adds attributes to the element.

These attributes enable me to hook in Mercury Editor to perform WYSIWG edit in place, updating, previewing and saving the content via WebApi to update the database, for the currently selected culture. This allows editing content and adjusting it to account for differing text length to obtain correct flow within the design. The admin area also allows importing, exporting and changing localised route names etc.

The performance is very good.
re: AngularJs and Promises with the $http Service
April 09, 2015 @ 11:28am | by Hardik

Thanks for the perfect explaination, it clears out lot of fundamentals of promise in angularjs.
re: Back to Basics: UTC and TimeZones in .NET Web Apps
April 09, 2015 @ 4:21am | by Matt Roberts

Stellar job, this was a really nice summary of some techniques I've used and then forgotten about and had to re-google, thanks!
re: Using CSS Transitions to SlideUp and SlideDown
April 05, 2015 @ 10:50pm | by Saurabh Udaniya

you are setting height as
element.css("max-height", height); 
I tried your solution with angular directive and it was not working, however adding "px" to it
element.css("max-height", height+"px"); 

saved my time so thanks for this article.
re: Bitmap types, Binary Resources and Westwind.Globalization
April 01, 2015 @ 9:32am | by Visar Gashi

I agree with the comment as well, storing the string for a web application should be sufficient. This might be more useful for thick client apps, I am assuming this works for mobile as well. Perhaps for standardization, you can include the functionality, but discourage its use for web applications?

Great library by the way, I have done something similar for multiple projects, evolving the idea with each one, but never going far enough to build a library. I hope to use yours for my next gig.
re: ASP.NET MVC Postbacks and HtmlHelper Controls ignoring Model Changes
March 31, 2015 @ 8:52pm | by Ben Gichamba

Thanks for this post. Had spent a couple of hours wondering what I am doing wrong.
re: Bitmap types, Binary Resources and Westwind.Globalization
March 28, 2015 @ 1:28am | by Rick Strahl

@Frank - yup totally agree. I don't believe it really makes sense to store binary resources, but in this case I have to support it since that's what Resx supports. You can also use this stuff outside of ASP.NET where you might need to have some resource access.
re: Bitmap types, Binary Resources and Westwind.Globalization
March 27, 2015 @ 10:01pm | by frank

It sounds like if someone needs a localized embedded image for a web app, the easiest thing for them to do is have a string resource that contains the data url. Then the processing concerns go away.
re: Azure VM Blues: Fighting a losing Performance Battle
March 25, 2015 @ 7:27pm | by nom-nom

We recently migrated a medium-ish sized system from two dedicated hosted servers at RackSpace over to Azure. We run a data api that serves 3k/6k (off-peak/peak) requests per minute - about 7M requests a day total to about 70,000 unique clients, some international.

We're having a lot of sporadic issues. In fact, as I write this one of the websites in our group has been returning 503's for 25 minutes for no discernible reason.

We're using about dozen D-series cores of cloud service for our main api app. It does a fair bit of image generation using System.Drawing, GDI+, 3rd party native libraries, etc. An A2 cloud service for recurring jobs and the Scheduler feeding to a storage queue to initiate them. An A2 for a few data ingestion apps and FTP, mounts a storage file share that's shared with the recurring job processor and api. Another A2 cloud service for periodic video encoding and image generation. A handful of websites in one pool - our public storefront and a site just running ImageResizer off our blob storage along with some internal tool sites. 13GB Redis cache.

Our main DB is currently a P3 because Azure has some bug where our database was failing over 10+ times a day and our apps would be unable to connect to our DB for 1-2 full minutes at a time, several times a day. We also use a P1 master and P2 active readable secondary DB.

I can't even begin to enumerate all the many little weird issues we experience, but the end result is that we've barely had a single day go by without all our klaxons blazing at least once. Service downtime is not an exceptional event, it's a matter of course.

There's also no effective way to get questions about these events answered, short of perhaps paying the $1000 a month support plan. Currently we submit tickets and get non-answers after 5-7 days.
re: A jquery-watch Plug-in for watching CSS styles and Attributes
March 25, 2015 @ 10:16am | by Rick Strahl

@Tibi - this was asked before and the behavior is by design. When a property changes you get passed the list of properties with their state so you can decide on what you need to address. There seems to be no need to raise multiple callbacks for each change because you're going to get exactly the same data with each of them.

If you want to handle multiple callbacks, go through the list of props and determine what needs to be done based on the values.
re: Using an alternate JSON Serializer in ASP.NET Web API
March 25, 2015 @ 10:13am | by Rick Strahl

This article refers to a pre-release version and yes JSON.NET is the default serializer now. However, this article still serves as guide for replacing the default serializer with something else.
re: A jquery-watch Plug-in for watching CSS styles and Attributes
March 25, 2015 @ 4:17am | by Tibi Neagu

First off - amazing plugin! Really hits the nail on the head for a lot of us out here.

I've just started using it and noticed that if you add more than one watcher on the same element, only the first callback will be called.

Maybe I'm doing something wrong or is this a limitation of the Mutation API?

Thanks!
Tibi

P.S. I've also opened an issue on Github: https://github.com/RickStrahl/jquery-watch/issues/6
re: Using an alternate JSON Serializer in ASP.NET Web API
March 25, 2015 @ 12:21am | by Dennis

Rick,

Have you updated this article lately. Looks like ASP.NET Web API implements JSON.NET already or am I confused? Yeah I know it is two years old a lot has changed.
re: ASP.NET MVC, Localization and Westwind.Globalization for Db Resources
March 24, 2015 @ 11:49am | by Rick Strahl

@KA - The core library can be used completely outside of the ASP.NET context, so if you have a Windows (non Web) app you can use database resources in that as well using the ResourceManager or DbRes.

When running under ASP.NET using the Web package you get two different project options to run under: WebForms or Project where WebForms uses Local/Global Resource folders and naming conventions or Project which uses simple files and that can be used with any .NET project and application.

All the front end stuff in the localization UI depends on the Web package and it assumes that ASP.NET is available, so if you run the Web Admin form HttpContext is always there. All the tooling that is used however is available in classes that you can call directly from your own applications/code.

For a WCF project you would just use the core library that has no dependencies on HttpContext - there are only two support classes in the core library that rely on System.Web - DbRes (which has helpers that return HtmlString) and the various exporters that default paths to the default web root path *if* Http context is available.

if you find other places in the core library, please file an issue on GitHub and I'll take a look at it.

re: ASP.NET MVC, Localization and Westwind.Globalization for Db Resources
March 24, 2015 @ 5:35am | by KA

Hey Rick,

Really cool stuff, I am impressed.
I have one question. Saw that for retrieving the resources you use HttpContext.GetBlobal or local resources. Is there any other way to retrieve the resources. For example if you use a WCF Service and is on TCP the HttpContext is null.
I mean somehow to be protocol independent.

Thanks.
re: A dynamic RequireSsl Attribute for ASP.NET MVC
March 22, 2015 @ 1:27pm | by Tim

Hi Rick,

We use this little trick when decorating classes/methods:

#if !DEBUG
[RequireHttps]
#endif

public ActionResult MyAction()
{
...
}


For those not familiar, this uses the debug flag set up against the project configuration in Build tab. 'Define Debug constant'. You can configure whether the flag is set or not for each project build profile.
re: Creating a dynamic, extensible C# Expando Object
March 20, 2015 @ 11:29am | by Chief

I am using the Expando object to facilitate an adhoc data query in my application where the returned data is a result of a sql query built during run time. Not tied to strong typed is so very VFP like.

Thank you.
re: ASP.NET MVC, Localization and Westwind.Globalization for Db Resources
March 18, 2015 @ 10:28am | by Douglas Hammon

Good stuff. Looking forward to your post about SPA scenarios
re: Article: A low-level look at the ASP.NET Architecture
March 15, 2015 @ 3:04am | by Veverke

Excellent and a must read article. I share the philosophy that understanding the inner workings of things may contribute greatly for further creations - besides the fact the seeing the big picture gives lots of satisfaction.

A must read !!!
re: Azure VM Blues: Fighting a losing Performance Battle
March 14, 2015 @ 8:49am | by roger geisert

I has similar issues. Someone here mentioned setting up an affinity group which I did. Now it's quite snappy.
re: Prefilling an SMS on Mobile Devices with the sms: Uri Scheme
March 14, 2015 @ 3:01am | by JĂșlio

This post helped me figure out how to get SMS URIs to work.

Here’s a little follow up: http://blog.julianklotz.de/2015/03/14/the-sms-uri-scheme/
re: Publish Individual Files to your Server in Visual Studio 2012.2
March 13, 2015 @ 2:38am | by Costin

It seems that extra settings in the publishing profile are not taken into account on individual publishing.

In my publishing profile I have added some custom settings to minify CSS and JS files. When I publish the entire project, everything works as expected, but if I want to publish just the Scripts folder, the JS files don't get minified anymore.

Also, I have set up the profile to precompile source files, so almost everything ends up in the bin folder. However, there's no way to publish only this folder.
re: Using FiddlerCore to capture HTTP Requests with .NET
March 12, 2015 @ 9:40am | by Ira

Greate job! thank you!
but I have 1 trouble.
in my local machine Fiddler creates certificate and FiddlerCore Api works perfectly.

but I need to build my project also on CI TeamCity and there I have some problem.
FiddlerCore could not create certificate.
my code fails on this line:
"CertMaker.createRootCert()"
with next error message:
"System.IO.FileNotFoundException : Cannot locate: MakeCert.exe. Please move makecert.exe to the Fiddler installation directory.
at Fiddler.DefaultCertificateProvider.CreateCert(String sHostname, Boolean isRoot)
at Fiddler.DefaultCertificateProvider.CreateRootCertificate()".

In my project I have 2 dlls: BCMakeCert.dll and CertMaker.dll;

and here is my method:
"void InstallCertificate()
{
if (!CertMaker.rootCertExists())
{
if (!CertMaker.createRootCert())
{
throw new Exception("Unable to create certificate for FiddlerCore.");
}
if (!CertMaker.trustRootCert())
{
throw new Exception("Unable to trust certificate for FiddlerCore.");
}

X509Store certStore = new X509Store(StoreName.Root, StoreLocation.LocalMachine);
certStore.Open(OpenFlags.ReadWrite);
try
{
certStore.Add(CertMaker.GetRootCertificate());
}
finally
{
certStore.Close();
}
}
}"

where I miss something??

thank you a lot!
re: RequestValidation Changes in ASP.NET 4.0
March 11, 2015 @ 5:04pm | by fib(Littul)

just encode with javascript ?! - amounts to writing a massive encoder/decoder that will be broken each time W3 changes things, just about. Just try this ... examples:
xmlhttp.open("POST", "page.aspx?val1=abc&val2=<d", false(or true));
or anything "<(letter)"...
or anything that has '&' in it...
The above is with RequestValidation in force.
Examples: if you encode '<d' ... no go!
if you swap '<' or & with certain 3 character sequences and of course, decoding code galore on the server side... wow... things can be made to work... but the code is horrendous. Don't know, show me what I am missing.
so, hypothetically <div would become xxx, <p...zzz, ... etc... ...xxx may fail in a porno context! lol
re: Web Browser Control – Specifying the IE Version
March 11, 2015 @ 12:22am | by Govindarajan

Hi Guys,
I'm running a windows service to render a HTML content on WebBrowserCotrol and take the screenShot of the output and save it in the specified local directory. I'm able to achieve this if i'm logged in the server, if I'm logged out of the server I'm getting the script error. I think it still try to find the registry entry in the HKEY_CURRENT_USER

I have tried all the below option

HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION

Any idea on this?

Regards,
Govind
re: Cordova and Visual Studio CODE Magazine Article
March 06, 2015 @ 3:30am | by Rick Strahl

Thanks Dave. If you've already been doing Cordova development there's probably not much new stuff here, except maybe the focus on Visual Studio, which I was rather impressed with in how easy it makes the development process even with iOS.
re: Cordova and Visual Studio CODE Magazine Article
March 05, 2015 @ 8:27pm | by Dave Ward

Nice. I just pulled my first print copy of CODE magazine out of the mailbox this afternoon and thought that would be an interesting article to read since I've been doing a lot of Cordova work lately myself. Didn't realize you wrote it. I will definitely find some time to read it now.
re: <main> HTML5 Tag not working in Internet Explorer 9/10/11
March 05, 2015 @ 12:39pm | by Rick Strahl

@Sean - thanks for checking... and confirming what I suspected that main was treated as an inline tag.
re: <main> HTML5 Tag not working in Internet Explorer 9/10/11
March 05, 2015 @ 8:53am | by Sean W.

I was a bit curious about this, so I hacked up a dirt-simple test case in JSFiddle. You can try it yourself (with jQuery):

Before main. <main>Foo</main> After main.
<script>console.log($("main").css("display"));</script>


Chrome prints "block" to the console. Firefox also prints "block". IE10 prints "inline".

The W3C and WHATWG recommend this should be the default style rule:

main { unicode-bidi: isolate; display: block; }


I ran the same test including "unicode-bidi" on a few browsers, and got these results:

Firefox 36: main { unicode-bidi: -moz-isolate; display: block; }
Chrome 40:  main { unicode-bidi: normal; display: block; }
IE 11:      main { unicode-bidi: normal; display: inline; }
IE 10:      main { unicode-bidi: normal; display: inline; }
IE 9:       main { unicode-bidi: normal; display: inline; }
IE 8:       main { unicode-bidi: normal; display: inline; }
IE 7:       main { unicode-bidi: normal; display: inline; }

// For comparison:
IE 10:      gronk { unicode-bidi: normal; display: inline; }

It's interesting that none of the three major browsers get the unicode-bidi property right by default. Firefox comes closest.

But these results suggests to me that the IE team simply forgot to include a stylesheet rule for <main>, since it shows the same properties as "gronk" or any other unknown element.
re: ASP.NET Frameworks and Raw Throughput Performance
March 05, 2015 @ 4:16am | by Rick Strahl

Currently the answer is no. vNext is very slow compared to say Web API or current MVC, but it's also not optimized yet. In my tests I ran in with beta 2 perf was somewhere in the 75% range from what MVC/Web API produced.

I haven't added vNext to the tests because of the unstable and changing environment and the really crappy perf at the moment. This will get better once they get closer to a fixed set of features and release candidates I think.

To be honest I don't expect performance to be greatly improved over current tech, but scalability - higher overall request load might be the case if code is properly async optimized.

We'll just have to wait.
re: ASP.NET Frameworks and Raw Throughput Performance
March 05, 2015 @ 2:41am | by Yassine

Thank you for this great article.

I agree with Andy, would vNext be faster ? ( because they have merged Web api and Mvc, and is more lighter because it doesn't reference System.Web and the heavy 200mb framework ? ( lighter means small memory print to handle each request... ) )

These are good questions to answer :) .

Thanks again
re: Azure VM Blues: Fighting a losing Performance Battle
February 27, 2015 @ 7:15am | by Marty Glynn

We're getting similar results on Dell - which is apparently an Azure implementation.
re: .NET 4.5 is an in-place replacement for .NET 4.0
February 27, 2015 @ 5:54am | by Ole

Thanks for this explanation!

As much as I like doing c# and .net tech, .NET 4.5 is causing major headaches in our web application projects, mainly asp.net mvc.

Some of our backend libs still are 4.0 since they're mainly used in WinForms applications where we don't want to force the clients to do a new download.

But as good as it is, Visual Studio 2013 is a pain, when using asp.net MVC and you do NOT want to use 4.5, especially if you're using nuget for all those nifty packages like bootstrap, jquery, log4net etc.

I sometimes don't understand why the VS and .NET teams don't have the Developers in mind, who are actually using their stuff. I would like to keep costs low, but I'm wasting my companies money on such issues.
re: ASP.NET Frameworks and Raw Throughput Performance
February 27, 2015 @ 5:31am | by Andy

I've always referred to this article over the years in my various discussions of performance :) Any chance you might be able to revisit it for the new 2015 technologies (MS has put a lot of effort into performance since 2012)
re: Using FontAwesome Fonts for HTML Radio Buttons and Checkboxes
February 27, 2015 @ 3:22am | by Rick Strahl

@Allen - thanks for catching the missing CSS. Fixed.

Not sure why you can't click the checkboxes. Does it work if you take the with-font off? Does the sample form work for you? I can't see a reason that it work with the keyboard but not the mouse. The mouse target should work for both the label and the actual check box. I use the exact code you have in an actual application with out the angular bindings without problems. You might want to double check the actual HTML that is rendered with dev tools and Inspect Element to ensure that there isn't something that's getting injected into the middle.

@Pawel - it works down to IE 9 which is the first IE version that partially supports CSS3 which is what makes this work.

re: Using FontAwesome Fonts for HTML Radio Buttons and Checkboxes
February 27, 2015 @ 1:08am | by Allen

Great article.

I believe your consolidated css at the bottom does not contain the css to make the actual checkbox/radio button invisible.

Also when I use the following html:

<input name="rememberMe" type="checkbox" class="with-font" data-ng-model="vm.loginData.useRefreshTokens"><label for="rememberMe"> Remember me</label>

I am unable to click on the font-awesome checkbox, I can use keyboard shortcuts to check and uncheck the checkbox but not the mouse? Any ideas what I'm doing wrong? This is all in Chrome.

Cheers.
re: Using FontAwesome Fonts for HTML Radio Buttons and Checkboxes
February 26, 2015 @ 11:47pm | by Pawel

I wonder if it works well in old IEs?