Browse by Tags

Tagged Content List
  • Blog Post: Free Code: Deferred calls to IDispose

    I've been dealing with heavy use of Stream types recently. Not as in the fairly common usages of say, reading a text file or whatnot. We're talking Streams that transform data from one format to the other transparently to the caller, that run across various nodes in a cluster (think a Stream of Streams...
  • Blog Post: Free Code: Windsor Castle Autofactory Facility

    So I recently was working on a system that used extensive need of delayed factory support for dependencies on our components. Effectively if ClassDepending needed to use ClassDepended, the constructor parameter was instead Func<ClassDepended>. This solution was built on Windsor container. Having...
  • Blog Post: Simple WCF netMsmq Example (or Step 1 to stop reinventing yet another MSMQ clone)

    It's pretty obvious that MSMQ is a bit of a dark art out there. People know it exists, everyone knows someone somewhere that knows a guy who once did something with it, and like practitioners of esoteric arts, the technology is looked upon with distrust. In fact to the point that I see team after team...
  • Blog Post: Yes you can execute sprocs with EF Fluent API Code Only

    OK let’s make this clear. You can totally call SQL Functions, SQL SPROCS, or any other raw SQL statement and use it in EF Code Only. What you don’t get is automatic or fluent API configuration statements that perform this mapping work for you and by default, no tracking occurs on the materialized...
  • Blog Post: Map private properties with EF Fluent API

    So until we get EF 4.2 and the support for enumerations as first class citizens those of us needing support have resigned ourselves to the simple fact that we are forced to expose a property for the integer value for EF to use and wrap that value with a convenience property that casts it as the appropriate...
  • Blog Post: Windsor Container Series

    It's no secret that I am a fan of Windsor Container. Here's a really great series of Advanced Windsor Container Tricks posts that I am linking here for reference Registering Delegates & A Delegate Factory Facility Auto registration How to resolve arrays How to register and use decorators...
  • Blog Post: Silverlight, Faults, and HTTP Status Codes

    So plenty has been written about the mismatch in between the Silverlight browser plug-in and WCF messaging with fault use cases over HTTP. For those of you that didn't know about this then here's your chance to catchup: According to the documentation , SOAP faults are not supported in the WCF client...
  • Blog Post: Using reflection to determine if an event is static

    So if you happen to have an EventInfo class and need to determine if the event is static or instance, it isn't actually immeidately clear if this is supported. Most of the MemberInfo basic types expose a property named IsStatic that indicates if this member is static or not. If you've ever worked with...
  • Blog Post: Interested in POCO Entity Framework 4?

    Editorial note: EF 4.1 was released as part of the .Net 4 Platform Update 1 release. You should use the information at http://blogs.msdn.com/b/adonet/archive/2011/04/11/ef-4-1-released.aspx for training now. For those of you interested in POCO In EF4, here's a list of links that you should read to...
  • Blog Post: Modifying ASP.Net Providers at Runtime

    How to add providers at runtime programmatically So if you are like me, you are a fan of not reinventing the wheel. This is especially true of components like Membership, Roles, Authentication, Personalization and whatnot. While I take some issue with the choice of API and can think of many improvements...
  • Blog Post: Unit Testing Repositories, a rebuttal. Or "How to use proper decoupling to unit test the repository pattern"

    For primers, you need to read this post first: http://buffered.io/2008/07/29/unit-tests-boldly-crossing-boundaries-and-gently-breaking-rules/ So the other day I received an email from a group that I am assisting in understanding TDD, Test Concepts, and Separation of Concerns, and they asked, "Is this...
  • Blog Post: DataServices, IErrorHandlers, Exceptions and the Gulf between them.

    OK I am going to let you in on a dirty little secret about Astoria based services. This secret is probably not even known to you. Ready to hear it? Really? Well here it is: You'd better never have anything go wrong as you'll never know it. It devours exceptions and is hungry for more! "What?!?...
  • Blog Post: Query Providers ARE Still Data Access Code!!

    So everyone reading this (or at least hopefully everyone) will know that putting data access logic into the UI is anti-pattern of all anti-patterns. I am going to sidestep the issue of simple utilities and one-off screens and trivial applications for the purposes of this discussion. We're instead focusing...
  • Blog Post: An alternative to the WIF ClaimsPrincipal IsInRole implementation (free code)

    So let me start with by saying that I love the Geneva Framework. Stuart Kwan and team have so far produced a most excellent product. In fact, we were so impressed with it we struck an agreement with the WIF team back in early 2008 to get access to the source tree so that we can produce some highly customized...
  • Blog Post: Handling the Tri-state asynchronous result dilemma

    So in most programming languages and environments you have will define an operation that performs some type of interesting work. Let's call that ReallyInterestingMethod() ™ . ReallyInterestingMethod accepts any number of inputs and returns exactly one output ( void or value as some type). The language...
  • Blog Post: Extension methods to reduce AspNet Cookies Collection bugs

    My buddy Spook was lamenting the other day about the unintuitive behavior of the ASP.Net Cookies collection. You can read the fully bits here before continuing. I decided that methinks this is a case for some extension methods! If you are someone that wants to tweak this behavior to support the pattern...
  • Blog Post: So what would this actually take?

    This is a followup on my followup here . After rapping some with Alex I was thinking about what an expression would look like on the wire, provided it has limited capabilities allowed such as F(G(K(x))) = y F(G( [K(x) {attribute}] )) = y where selector was evaluated as some XPath perhaps...
  • Blog Post: Services discussion with Alex James

    This is a posting part of a converstation going on between myself an Alex James, metadata thinker/engineer/PM par excellence here at Microsoft. You can find the start of the conversation here . I've decided to not be an ass and write a disertation in the comments section of his blog and am posting here...
  • Blog Post: LINQ: Building an IQueryable provider series

    A set of links that I'm posting because 1) I don't want to lose them and 2) they're handy for people to read. Reusable IQueryable base classes Where and reusable Expression tree visitor Local variable references Select Improved Column binding Nested queries Join...
  • Blog Post: WCF VS Item Template Grabbag

    The latest in this series . Here's a 'grabbag' of VS item templates you are welcome to. The set consists of: a custom authorization manager a logging IErrorHandler and attribute to use it with your service WCF Duplex Service WCF One Way Service WCF Streaming Service WCF Untyped Service...
  • Blog Post: WCF Solution Template

    Another in the series of free Visual Studio templates I personally use being posted. This one creates a recomended WCF solution containing Contracts, Commands, Gateway, and Service stubs. In addition, standard items such as IErrorHandler and Authorization Manager are added. Files are attached to the...
  • Blog Post: NUnit Project Template

    This is the first in a long line of custom templates that I use on a daily basis. Nothing too fancy, it's just that they save some of the boilerplate work I have to do. This one allows you to create a new test project with NUnit, Linq, and Moq all set up for you to go. Files are included in the post...
  • Blog Post: Work Around Your ASP.Net Session Serialization Issues

    OK. We're going to assume everyone here knows about ASP.Net Session state. We also will assume that you know there's 3 modes, InProc (default), State Server, and SQL. The latter two will be the topic of discussion here. The biggest difference between the InProc and out of process state management systems...
  • Blog Post: Creating Nullable<T> When You Don't Know T

    This bit came about from a post from Brad Wilson back in July that some of my Magenic buddies sent me. I won't repeat what his issues are (you can read it for yourself) but here's the solutions to his misunderstandings regarding nullable types. Maybe I’m missing something here that’s subtle in his...
  • Blog Post: Handy Extension Methods

    This entry was edited July 16th, 2008 to include an additional extension method courtesy of Alex James //Copyright (c) 2008 James Zimmerman //Permission is hereby granted, free of charge, to any person obtaining a copy //of this software and associated documentation files (the "Software"), to ...
Page 1 of 2 (26 items) 12