Sending e-mails from the cloud based web application

by DmitryKirsanov 10. June 2016 06:26

 

 

This sounds crazy. But when you move your website to the cloud, you get problems in things you were previously taking for granted. Like sending e-mails. Basically, the problem is that many e-mail servers, usually ones of big providers, have Azure, Amazon and other cloud provider IPs blacklisted. When you attempt to use SMTP service from your virtual machine in Azure – in many cases it fails to deliver. This means, that your Azure machine can not act as mail server and shouldn’t attempt to deliver messages to recipient SMTP server directly.

Why would you use SMTP service at all? Well, mainly for the sake of performance. Your web application, be it ASP.NET, PHP, Ruby or whatever, will benefit from saving the outgoing e-mail message as text file somewhere on local hard drive, instead of trying to deliver it using TCP/IP, even if that’s done in asynchronous method.

More...

New Side Project - Currency Label

by Dmitry Kirsanov 28. January 2014 22:15

Spent 40 minutes of my life on new control for ASP.NET - the Currency Label. It allows you to add currency conversion painlessly just like a normal label. Actually, it is a normal label, just extended.

Currently it's in beta, but passed all tests so far, so you're welcome to try it on your website.

https://kirsanov.net/page/Currency-Label-control-for-ASPNET-Web-Forms.aspx

Advanced Testing in Visual Studio 2010 Team Foundation Server

by Dmitry Kirsanov 4. January 2012 17:10

Team Foundation Server 2010This is part 4 of Visual Studio Team Foundation Server 2010 for Developers walkthrough. Last time we were speaking about the unit tests, and that was useful, but very basic foundation of what you can do in terms of Test Driven Development. However, we can conventionally separate testing in Visual Studio and Team Foundation Server to 3 levels. So today we are going to talk about the second level – Advanced Testing techniques, such as Test Impact Analysis, Coded UI Tests and Load Tests.

If that’s only the middle layer of complex testing in Visual Studio 2010, what’s in the last one, you might ask? There will be test automation using Hyper-V virtualization with Virtual Machine Manager and yes, we will discuss it later as well.

But today we’ll begin with Test Impact Analysis. More...

Entering the Path of Software Developer - what you need to become one

by Dmitry Kirsanov 12. December 2011 13:37

Microsoft KidDuring my career as a Microsoft Certified Trainer, I’ve been training .NET software developers and Windows system administrators – usually they were well established professionals longing for more knowledge and ready to purchase a training course instead of a car.

But there were people, and they still appear regularly, who suddenly make a decision to become a software developer. Either it’s because they were ignited by the idea and believed in own capacity of writing new software, or out of curiosity or any other reason – be it money, prestige or worrying about own future.


So this post is for such people. If you are considering to become a .NET software developer and wondering what should be your first step – I will do my best to explain it right now. If you are seasoned .NET software developer, then perhaps you won’t find much useful information here, but you’ll have a link to give when someone will ask you that question – “I want to become a software developer, what should I do?”. More...

URL Rewriting and Routing in ASP.NET 4

by Dmitry Kirsanov 9. December 2011 13:37

How to make the URL of your page look more user-friendly or just make it self-explanatory? And anyway – look different from what it really is? In ASP.NET version 4 it’s easier than ever.

Why would we need that feature anyway?

It’s been quite popular trend in web development since the very beginning of dynamic Web – first, we didn’t want anyone to see the extension of our files, as this posed a security risk. Anyone, who could see that our page is actually an ASP page, would understand that you have Internet Information Server, which was considered “dangerous” at that time – not even because it was too bad, but because Windows NT 4 Server was user-friendly enough so people wouldn’t need to be MCSE in order to install and run web server. It wasn’t hard for Linux either, but Apache didn’t offer any dynamic contents out of the box. More...

Search Engine Optimization in ASP.NET

by Dmitry Kirsanov 30. November 2011 09:19

ASP.NET engine is a wonderful thing. It does so much for you, that in the past could take ages and would earn you the title of demigod of Web Development. In some legacy languages, like PHP, it is still the case. For example, things like Localization and cross-browser support are very natural and automatic in ASP.NET, they don’t require any time or skills. You can add support of more languages, different output formats for date and numbers, add Ajax powered controls, caching, data access, perform various other high pilotage figures without thinking. I remember the time, when saving data between post-backs was an issue, and in ASP.NET it was solved by implementing the VIEWSTATE feature, which saves the state of page controls in one hidden field between submits - that feature alone worth a thousand words.

But ASP.NET comes to the rescue not only in obvious and direct ways - some features were introduced for one purpose, but perfectly helped in other areas. And one such area is Search Engine Optimization, or SEO. More...

What’s new in ASP.NET 4.5 - Performance improvements

by Dmitry Kirsanov 29. November 2011 11:40

A long time ago, when dinosaurs were still operational,  we tried to improve performance of our HTML / CGI pages by various ways, but also having different goals for such improvements.

In the dawn of web, when U.S. Robotics 14.4kbps modem was a de-facto standard and traffic compression wasn’t widely implemented by ISP call centers, our biggest concern was the size of our files. I wouldn’t say “output”, as it was mainly static, but even when it was dynamic, like the output from CGI modules written in Visual Basic 4 or 5, it was paramount that users would not wait more than 2 seconds to get the HTML part of it.

Now even mobile phones are having unlimited data plans, home connections reach 100 Mbit/s heights and in order to decrease the size of the output we just have to tick a checkbox in IIS, so the output – be it static or dynamic, is compressed. So the era of “HTML optimizers” – tools that remove extra spaces and “unneeded” tags from your markup, is over.

Another thing that helped us to avoid traffic jams, was Ajax. It killed 2 rabbits with a single shot – decreased the traffic flow by only up/down loading the data our application needs at this time, and thus increased the response time. But this came at a cost.

Each small callback made by Ajax is no different than ordinary callback, except that it transfer smaller amount of data. But it’s a connection nevertheless. Even if keep-alive is used by browser, it still consumes a connection from server and still there are protocol issues involved. More...

CAPTCHA sample project

by Dmitry Kirsanov 28. October 2011 15:41

Good Captcha in ASP.NET will make your website free from spamI’ve created a small sample project for Mondor's Captcha (see the full project page here). As some people are asking at the forum about how to implement it in ASP.NET project, I decided to make a quick sample for both development environment and production IIS.

MS CAPTCHA is a free component for ASP.NET which implements “Completely Automated Public Turing test to tell Computers and Humans Apart” – an image which “only people” could read. In case of Mondor’s CAPTCHA, it also contains unique feature called “Arithmetic”, which displays simple formula, so even if bot will be able to read “2 + 2”, it will type “2+2” as an answer, while there should be 4.

More...