I guess this post isn’t so much for us “professional” web developers as it is for the hobby developers. Having that said, I can probably think of about a hundred reasons why this would actually be good for me as a pro as well…
Microsoft has currently an Azure feature called Windows Azure Web Sites in preview. It is probably about to be released pretty soon, or at least I hope so. But I don’t want to get into Windows Azure Web Sites as such. What I want to have a quick chat about, is how extremely easy it is to get up and going with a simple website using Azure Web Sites and WebMatrix.
WebMatrix as a tool, is basically a small development environment, bundled with a bunch of things like IIS Express so on. It also has a whole heap of predefined templates, making it really easy to get up and running with a new blog or whatever. It also supports node.js and php development, which is quite neat…
More...
The Unit of Work pattern is a really useful pattern that I really haven’t given a lot of thought to for some reason. Generally it just seems to need very little attention. I guess frameworks around us shield us from it… But I guess it the more you learn, the more you think of, and the more time you spend working on things that you previously never invested much thought in.
Anyhow, recently, working with Entity Framework (yes…it is another EF post…) I realized that this pattern is really key to a lot of things, and it isn’t always that easy to implement. So I decided to Google it and borrow heavily from some smarter person than me who had already built a nice solution for it. Unfortunately, all the information I found regarding UoW and EF was overly simplified, and generally based around abstracting away EF in a single repository.
More...
Ok, so first of all, it has been a VERY long and VERY quite period on my blog. I guess that is just the way it is, sometimes life just takes up too much time to be able to blog to the extent I want to. On the other hand, I have been very busy with some cool projects, including some cool technologies, so it is all good I guess.
Now back from the dead I hope that my blogging will pick up, and this is the first in a series of blog posts about things I have figured out during my silent months. I know that Entity Framework is far from what I normally blog about, but it is still something I use, and something I spent some times getting my head around. Understanding EF as such isn’t that hard, the hard part was getting it to work in a fashion that suited me, and one of the things I don’t like is just adding a gazillion repositories on top of EF and be done with it. And I don’t like stepping 15 levels into my objects, lazy loading things as I go along. And I want things to be as DRY as possible. So I prefer having more “emancipated” objects. I want my objects to have freedom to do what they need to do. This makes the programming so much simpler and easier to follow… But it also requires some features like DI… And on top of that, being a bit paranoid, I prefer abstracting away my ORM as much as possible…
So this post is about how I have decided to use EF in my current projects, and I would love any feedback you got…
More...
In my previous post I gave a semi-quick introduction to NancyFx. This time, I want to take Nancy and combine it with Azure ACS. Not a very complicated thing as such, but still something I want to do as I enjoy working with both technologies.
Just as in the last post, I will self-host Nancy in a console application, and use NuGet to get it going. I will also re-use the “www.nancytesting.org” domain I set up in my hosts file in the last post.
Once I got my console application going with a host, and an empty NancyModule, it is time to start looking at the ACS.
More...
As part of not doing very much coding lately, I have decided that I am going to try to spend more time trying out new frameworks and technologies. And hopefully, that will en up with a lot more blog posts with interesting stuff. This time I have looked at a ridiculously funky micro framework for building HTTP-based services called NancyFx. It is really simple to get started with, but still very powerful…and modern…
Nancy can be hosted in a variety of ways, including in ASP.NET MVC, WCF and self-hosting. In this post, I will look at hosting Nancy in a console application as I had little interest in setting up anything big. And using NuGet, it was a piece of cake to get started. Just start up a new Console application project and then NuGet Nancy.Hosting.Self.
More...
Yesterday I was invited to speak in front of a bunch of really sharp guys attending the Lead Enterprise Architecture Program, LEAP, at Microsoft here in Stockholm. The topic of the day was how to share code between projects targeting multiple frameworks/platforms. Basically “how can we share code between projects aimed at WP7, Windows 8, Silverlight and WPF” in a useful way, limiting the duplication of code as well as maintenance.
Most of my presentation revolved around a sample I had written to target all platforms. It is a very simple application, but still shows that it is very possible to get it to work.
More...
There are many ways to expose functionality and data from a server to a client. And there is probably almost as many going the other way… In Microsoft scenarios, using WCF is the obvious choice for most of us, and when people talk WCF, they generally talk SOAP based webservices.
SOAP can however be a less than ideal choice in a some cases. It is way more complicated than some of the other options, and on top of that it has a tendency to bloat the messages being sent, which can be an issue when working with mobile clients for example.
More...
SignalR is a somewhat newish open source project that makes it possible to simulate push notifications on the web. It does so using long-polling (websockets available as an extra download), so it isn’t true push as such, but it gives the appearance of push. And on top of that, it is so ridiculously simple to set up…
Unfortunately, the NuGet package for SignalR doesn’t include the Silverlight client, which the GitHub project does. This is most likely going to be fixed in the near future, but currently you will have to do it the manual way instead of using NuGet.
The server part of SignalR works fine through NuGet, however, it doesn’t play nice with the Silverlight version as a property has been renamed and causes issues. So we have to do the whole thing manually to make sure both the client and server has the modified property… Once again, it is probably going to be fixed some time really soon.
More...
Lately I have been working on an Azure project for a client (if you haven’t noticed from my Azure-centric blog posts as of late). A part of this, we have built a WCF service that exposes the functionality that we need. However, we are not actually building a client, only the service. So we don’t have a great way of testing the service. This is obviously where the “WCF Test Client” comes in.
For those of you who don’t know what this is, it is a small client that hooks up to any available service and creates a proxy for you. You can then use this proxy through the interface and call your service.
More...
I guess it is time for another Azure Service Bus post. The previous ones has been relatively popular, so I thought I would do one more post to cover one last feature in the bus. (I say one last now, but I am pretty sure I will be back…)
Topics and subscribers are the basic units behind the Service Bus implementation of the pub/sub pattern. And as expected from a “simple” pattern like this, it should be simple to implement, and it is. The basics would be, create a topic, add subscribers that subscribe to messages from the topic, and finally push some messages to the topic, which are then relayed to the subscribers. Simple as…
More...