February 2009 - Posts - More Wally - Wallace B. McClure


Giving people what they want, More Wally. This is the technical and personal blog site of
Wallace B. (Wally) McClure.

This Blog


Technical Sites


More Wally - Wallace B. McClure

This blog will have all kinds of posts about Wally McClure. In it, there will be tons of .NET and computer programming posts as well as Wally's views on life in general. As you might guess, this site and blog help you get More Wally in your life. What more could anyone want? iPhone, Android, Xamarin.iOS, Xamarin.Android, Mobile, HTML5, .NET, ADO.NET, ASP.NET, AJAX, jQuery, jQuery Mobile, ASP.NET AJAX, and Windows Azure............follow me on twitter at Wally

February 2009 - Posts

  • Cloud Privacy and Security


    Recently, there was a post about about cloud computing not allowing for privacy.  I think that there are two separate issues regarding privacy.

    • Security of the platform.  The platform that is running your application must be secure.  If the platform is not secure, who knows what will happen.  Anyone can get it.  You need to trust the platform that you are running on and the vendor of that platform.
    • Security of the network.  Network access must be secure.  If someone gets through your network security to your application, you aren't very secure.
    • Security of the application.  The application you are running on must be secure.  Think sql injection, clear passwords, http/https, and that kind of stuff.
    • Working with your vendor.  If you are storing data in someone else's application (Facebook, Twitter, Salesforce), make sure that you understand the agreement that you have signed.

    Another thing to look at is the difference between the Cloud and an application running on the Cloud.  The Cloud is just a platform to build an application on.

    So, when you look at privacy, understand that there are many layers to privacy and security.  Its more than just about Facebook changing their terms of service on a whim.  Even then, they did change the terms back fairly quickly.

    That's my $.02.

  • ASP.NET Podcast Show #136 - Rachel Appel on Dynamic Data

  • TabIndex on asp:textbox and asp:mediaplayer (silverlight media player) in Internet Explorer

    This is an FYI for myself.  I find that I remember blog posts much better than twitter posts.  Much easier to see and everything.

    In IE, I was finding that I couldn't set focus on a textbox when I had a textbox and the silverlight media player on the page.  In Firefox 3, everything worked fine.  After much testing and some discussion with my business partner, I set the tabindex property of the controls so that the textbox ahd a tabindex of a very small value and the mediaplayer had a tabindex of a much higher value.  Once I did that, IE seems to be working much better.

    Posted Feb 25 2009, 01:29 PM by wallym with no comments
    Filed under:
  • Political Ideology as Software Development

    As most of you know, I'm not one to spend a lot of time saying negative things about others online.  I find its more important to work on the positives than to focus on the negatives.  Unfortunately, we seem to be at a cross roads in our country with bailouts, free money and such.  At the same time, there seems to be this ideological warefare going on in the world of software development.  Now that I have been around for 41 (ugh) years, I have decided to change that some.  I plan on being a little more vocal about some of the idiotic arguments I see going on.

    Political Affiliations

    I've been tested and I'm pretty much right in the middle of political ideology. That's strange because I align myself with the Republicans.  Republicans say that they are for low taxes, business, and fiscal responsibility(haven't seen that under George Bush).  Democrats are suppossedly for taking care of the little man and making sure that all groups are taken care of.  I'm disgusted by both`.  Its obvious that neither represent the common good.  Based on a general stereotype of each, I'll associate them with some disturbing trends in software development.

    The Jeff/Joel Republicans

    Jeff Atwood and Joel Spolsky seem to be similar to the Republicans.  Theres always a need to build a business.  Technology supports the business in a consulting world.  Rarely in any business is technology the business.  Throw something out, see if it floats.  Now, now, now.  They're all about business.  App doesn't scale, don't waste time optimizing, just throw hardware at the problem.  Programmer's are expensive, hardware is cheap.  That's the Jeff/Joel ideology.  Go, go, go, now, now, now.  Biz, biz, biz.  In our world, we can't just keep boring money and spending it as we have done over the past 8 years.  In the consulting world, these ideas don't work either.  Customers don't want to just buy hardware.  There is a cost associated to just buying hardware.  Gartner Group would call this "Total Cost of Ownership" meaning that there is a cost to figure out which server to buy, getting the server installed, setup, and actually in place in your data center.  Jeff/Joel, you guys are the Republicans of today.  I've talked about this before.  I don't think Jeff/Joel are the problem.  Its actually their followers that are the problem. 

    In my world, the things that Jeff/Joel make some amount of sense.   The idea of getting out and getting something done is important.  Unfortunately, the followers of Jeff/Joel don't seem to care about the future cost of all of this hardware over the next few years.  Sounds like what we've been living under the past few years.

    TDD/ALT.NET Democrats

    There is another group out in the world.  I've not been able to figure out if the group is TDD, ALT.NET, or something else.  As a result, I've been mixing them in my head.  However, they have a common thread.  That thread is the concept that everything has to be right before they go forward.  WTF?  Everything has to be right?!? You are f'ing kidding me.  Does anyone expect everything to be completely setup and completed in a software project/product.  This sounds like just like the Democrats wanting to make sure that every little group is taken care of (who's watching out for software developers in East Tennessee?).  Can we get something out and solve a business problem?  Can we get something out before a potential competitor does?  WTF do you mean we have to wait until all of these automated crap is 100% perfect.  How much time does this waste do we sit around waiting for the perfect solution?  Lots.  I'm often reminded of the line "Perfect is the enemy of the good." Try explaining this to someone on the business side. 

    This has been on my mind since I was up at MS last summer. I sat in a talk about testing in VS.NET and listened to an hour of "Your tests are wrong and my tests are right."  All I could think of was "How about we solve the customer's problems instead of talking ideology."


    I'm a centralist.  I think both sides have some merit.  Don't throw some piece of crap out there thats obviously going to break.  Don't wait forever to solve a business problem. Solve the problem and then iterate to make it better.  Realize also that building software isn't like building a home.  You aren't really ever done with, well you aren't done with it until the money runs out.  My point in this is to pull a little bit from each side that makes sense for your situation.  Nothing works perfectly in all situations.  Understand the right pieces to use and use them.

     PS. I reserve the right to change something if I find that I am not clear or wrong(like that would ever happen).  Feel free to email me your thoughts at wbm [at] wallym [dot] com

  • Sticker Ideas for the ASP.NET Podcast

    So far, I've created four stickers for the ASP.NET Podcast.  Three of these stickers feature Presidents Bill Clinton, George Bush, and Barack Obama.  In the interests of fair play, I'm thinking of branching out with some other stickers.  Here are the ideas I have:

    • Picture of the Republican Elephant and the caption "When I'm not sending money to the rich people that don't need it, I'm listening to the ASP.NET Podcast."
    • Picture of the Democratic Donkey and the caption "When I'm not trying to spend tons more money and get the Chinese to buy more US debt, I'm listening to the ASP.NET Podcast."
    • Picture of Ann Coulter and the caption "When I'm not bitching about super liberal Washington Post columnists, I'm listening to the ASP.NET Podcast."
    • Picture of Keith Olberman and the caption "When I'm not lying to the American people and screaming about the evils of  News Corp. and Rupert Murdock, I'm listening to the ASP.NET Podcast."

    So, tell me what you think, or feel free to submit your own.  Email me at wbm at wallym dot com with your votes and submissions.  I am looking for slogan ideas that would work across national boundaries.

    PS. None of the slogans above are going to show up in a real sticker.  They are jokes.  They are showing my frustration with what I see happening in the United States right now.

  • ASP.NET Podcast Show #135 - Development Methodologies as Religion

    Subscribe to all

    Subscribe to MP3 only

    Original Url: http://aspnetpodcast.com/CS11/blogs/asp.net_podcast/archive/2009/02/03/asp-net-podcast-show-135-development-methodologies-as-religion.aspx 


    Show Notes:

    • Superbowl, football, Cowboys (you have got to be kidding me).
    • Refactoring, TDD, and the great religious debates of software systems.
    • Coaching systems. Great Players make Great Coaches. Systems need to be molded to players.  Don't force one size fits all.
    • Ok, I feel better now.
    PS. Apologies for the late posting.
  • Atlanta Cloud Computing User Group

    I'll be speaking on Windows Azure at the Atlanta Cloud Computing User Group this evening.  If you are in the area, come by.



  • Lost

    Yesterday, we got beat 45-28. It sounds worse than it was. It was 30-26 at the start of the fourth qtr. We had no answe for Will. Brad did everything he could by scoring 19 pts. He made a 3 ptr. He scored on a driving layup at the end of the 3rd qtr with Will guarding him. Alas it was not meant to be.
  • We won won 28-21 on January 31

    We trailed 9-2 in the second quarter. We closed to 14-10 at the half. Went ahead 18-16 at the end of the third qtr. The final score was 28-21. Brad had 23, yes 23 points.
  • We lost 38-17

    Back on January 24, we got creamed 38-17. Brad had 9 points. It was a hard day from the beginning.
  • Performance is Important - Why Jeff Atwood(CodingHorror.com) is wrong and right about Performance


    I have recently been involved in a discussion on performance.  One of the big discussion items is the area of developer productivity vs. application performance.  Now, we all make tradeoffs like this every day.  Is it better to buy or to build?  Is it better to code at a high level or low level?  Is it better to get something out sooner that may not be optimized vs. getting it out later and providing a better experience for the user?  Is it better to code at Java/.NET vs. a lower level (think C++/C or assembler)?  Personally, I've coded in assembler and it REALLY SUCKS!  I did it for a few quarters at Georgia Tech and I hated the complete experience.  I've coded in C/C++ and it was marginally better, but this was in my unix days.  I'm a .NET junkie and I will continue to be so.  I believe that providing high level tools to make development easy is a good thing.  I am willing to pay a performance price to get a solution out to a customer sooner.  This is something that makes sense in the consulting work that I do every day.  However, there are times when doing performance analysis and optimization does make sense.

    Performance and Orders of Magnitude

    Lets talk performance.  Performance tends to fall into a general area of Orders of Magnitude to complete an operation.  Based on the number of items an algorithm operates on, called N, algorithms tend to complete based on a function that looks something like

    O(N) = A N^3 + B N^2 + C N log(N) + D N + E log(N) + F (comment: higher/different orders are entirely possible, I'm just thrown out some common ones)

    Out of that function, we tend to drop the constants (A, B, C, D, E, and F) and we tend to look only at the highest order of magnitude problem.  This means that it is typically more important to work on the part of an algorithm that is causing the N3 problem than the log(N) problem.  From a numeric standpoint, this makes sense.  After all, if we have 50 items to process and we look at 50^3, we get a problem of the order 125000.  If we have a log(50), that's 1.69, which is a big difference.  Also, we need to understand the number of items we are dealing with.  With an algorithm dealing with 3 items it may not be a big deal with your algorithm works on an order of N^2.  If you have a 100 items, N^2 can be a big deal.

    Where does the choice of raw algorithms come up?   The answer is typically it depends.  It tends to not come up as much in the consulting world and much more in the product world.  However, in the consulting world typically involves a lot of database interaction, as a result, there is a complete section in this devoted to the topic.

    Database Access 

    Now, the problem in the consulting world is a little bit different.  The world tends to run on data and that data is typically in databases.  Bill Vaughn is recognized for saying that all data access technologies wait at the same rate.  This is true.  Its very important to realize that a query that takes 5 seconds to run, but is run 100k times a day is a bad thing when it should only be taking 350 milliseconds to run if it had been optimized.  So, its better to only get back the data that you absolutely need.  Going off process/server to get data is really expensive.  Don't muck it up with something that looks like:

    select * from table  <!-- I've seen this done to get a simple calculation, no joke.

    You want to do something that looks more like this:

    select col1, col2, col3 from table where col4=val4

    In addition, you want to make sure that your database is optimized.  You want to make sure that you have primary keys, foreign keys, and a good indexing strategy.  How you access your data is important.  I like some routines that I have developed over the years.  The routines protect from Sql Injection and they are pretty simple to use.  They aren't for everyone.  Stored Procedures are also a pretty good thing to use.  They can be used to generate dynamic sql internally, so its really your choice.

    Algorithms and dividing the work

    Algorithms come in many shapes and sizes.  Generally, they fall into having a certain percentage of their work is serializable and some is parallelizable. Work that is only serializable can only be done 1 step at a time.  No matter how many CPUs or threads you attempt to use, you aren't going to get any benefit.  The only way to help these applications with hardware is to get faster CPUs with a higher frequency and more instructions per second.  Going from a system with 1 cpu to a system with 4 won't necessarily help these parts of an application.  Algorithms that are parallizable are much more interesting in the current environment.  With these algorithms, adding more CPUs, threads, cores and such will general improve the performance of these algorithms.  There is always some overhead involved in managing the different threads and such, but the over benefit is an increase in the amount of work that can be performed.

    In a consulting gig, there are typically parts of an application that can be divided out into parallizable work.  For example, a web request is typically an entity to itself, so http requests typically get mapped to different threads.  The requests don't typically interact with each other, so this is a place where you can get a win.  Fortunately, this is taken care for you by the web server vendor.

    The Problem

    As this performance argument was going on, my mind went to an article by Jeff Atwood I had seen discussed a few weeks ago on twitter.  The article is at http://www.codinghorror.com/blog/archives/001198.html.  Basically, the article talks about why its a poor idea to do performance optimization when looked at from a cost benefit analysis.  The thinking is that programmers are expensive and hardware is cheap, so based on that, just throw more hardware at a problem until it gets fixed.  I'm sure that for some customers, this is an acceptable solution, however, I have not seen them.  First off, you have to understand where your potential bottlenecks are.  Its your job as a developer to understand this.  You have to understand database performance.  If you don't know about sql, primary keys, foreign keys, and indexes, go learn about them.  You have to understand what your application is doing and be able to pinpoint the bottlenecks.  Just claiming that you need more better hardware is craziness and will probably make the customer question you.

    Turn this around and lets look at this from a customer's perspective in the consulting world.  I have an application that has been written in house and must support a set number of users.  To get more hardware to support the application requires the initial outlay of cash, signoffs from managers, appropiate space must be provisioned in your data center, the server must actually get there, the application must be setup on the server.  The cost of these things is significant.  Its a hard to thing to fathom because they don't show up in a budgetted line item, but they exist.  To get a $5,000 server setup might cost $15,000-$40,000 depending on the bureacracy that one must go through just to get the power turned on to a running application.  This doesn't even count the yearly maintennance cost of the server or the support that must go into the operating system on the server.  Before the Linux folks freak out and claim that their OS is free, its only free like a pet is free.  It still has to be maintained.

    Looking at the cost of a developer's time for a month vs. the $20-50k to actually get a server up and going is a completely different discussion than the $5k initial outlay of cash for a server.


    One of the things that I heard during this discussion was that it was important to not do stupid things.  "Doing stupid things gets you into trouble."  Amen, my bothers and sisters.  We all agree on that.  Its your job to not do stupid things.  How do you not do stupid things?  You educate yourself.  You learn.  You don't just take the defaults of settings.  You figure out what is going on.  You have to learn.  Learn Sql.  Learn algorithms.  Learn, learn, learn.

    Why the performance analysis is wrong

    Yeah, just throwing hardware at a problem is wrong.  Its wrong in a given set of circumstances.  Generating an application that takes on the order of N^3 or N^2 is just plain wrong.  No amount of hardware is going to fix this problem.  It shows that a developer doesn't know their algorithms.  Spend the time to fix your algorithm.  Spend the time to optimize your data access if a simple calculation requires way too much data.  Spend the time to get rid of these N^3 and N^2 parts of your algorithm.

    Why the performance analysis is right

    I've seen developers try and squeeze the last little bit of performance from an application.  As I said, working on those N^3, N^2, and database problems can give you easy wins.  The problem is that developershumans don't tend to take a balanced look at things.  People tend to gravitate to one extreme or the other other.  In this case, there are folks that will attempt to optimize forever.  Does it matter if an application scales at 5 N Log(N) or 3 N Log(N)?  No, it really doesn't matter.  You typically don't need to worry about that level of optimization.

    At this point, I am reminded of an optimization that a professor I had at Georgia Tech did when he worked at IBM.  He was working in their mainframe area.  He found an operation that was taking a large amount of time (read minutes).  He spent weeks counting cycles and improving it.  A performance analysis was done and after all of this time, no improvement was found.  He was shocked.  How could all of his time not improve things?  The problem was that this method was only called during a backup of the system.  Yeah, that writing to tape operation.  Know where your bottlenecks are.  Its your responsibility to know when an improvement needs to be made and when it doesn't.  :-)

    Final Thoughts

    Ok, that's it.  Go forth.  Be intelligent with your applications.  Don't do stupid things!

    PS.  I reserve the right to change whatever I said in whatever way I said it.

2006 - Wallace B. McClure
Powered by Community Server (Non-Commercial Edition), by Telligent Systems