Archive for the ‘programming’ category

Podcast recommendation

2010/11/24

I have find new podcast that I want to share with you. It is called “This Developer’s Life” and is produced by well known digerati Scott Hanselman and Rob Conery.

I listen to a lot of podcasts, about 50 % of them produced by Leo Laporte’s TWIT Network (This Week in Tech, Macbreak, This Week in Google, FLOSS Weekly and occasional Security Now).

What I like about Leo’s network is professionalism of audio production, usually good and interesting panel with topics that are worth listening to. Few other podcasts come even close to the TWIT level of perfection.

Except this one which is much better. Not necessarily from audio or production point of view – although they are both very good. This developers life goes way beyond what Twit does. It is not a dialog of few interesting geeks, it is story. Story nicely designed, well crafted, interwoven with really good music. It changes from dialog to story with commentaries, but keeps you interested. An episode usually
focuses on single theme and contains several stories. Topics are not technology, but the area where technology overlaps with life: motivation, audacity, highs and lows of programming career

Great selection of guests, including cybercelebrities such as John Resig or Miguel de Icaza.

I almost never listen to a podcast episode twice. For this one, I do.

Highly recommended.

http://thisdeveloperslife.com/

Excellent free Git tutorial

2009/01/02

Two screencasts, about 80 and 40 minutes long are available at:

http://excess.org/article/2008/07/ogre-git-tutorial/

Courtesy by fellow Ottawan Bert Trojanowski. Really nice job of providing deep enough technical understanding with good illustrative examples.

If you want to get into distributed version control (which is IMHO way to go), check this out.

Free eBook on ALT.NET

2008/09/27

It is always a nice surprise to find something that is free and actually useful on the Net :-) . Like this one: a fellow Ottawan Karl Sequin wrote and generously made available as free download “Foundations of programming” eBook.

He touches many topics of various levels from high level design concepts (dependency injection) to low level “Back to Basics” – how memory allocation and pointers work. Especially the later is often neglected and overlooked (and consequently misunderstood) by younger developers who started their education with a garbage collected language such as Java or C# and never were exposed to beauty and horrors of C ;-)

The book is using .NET and C# as platform, but the applicability of the chapters goes way beyond the Windows or Microsoft world. After all, Alt.Net has very close relations with Java world.

If you have time, give it a look. Were it not free, I would say it is worth every penny. Now I can only say it is definitely worth the time you spend on it.

Thanks Karl, I hope I’ll meet you in person sometimes. The advantage of living in Ottawa is that you have lots of smart people around you :-) .

After the Spring Storm

2008/09/25

Few days ago, I have received an email asking to attend the SpringSource conference and offering $300 discount if I decide to buy before end of month. The timining was pretty ironical, considering the recent contraversy about SpringSource Entreprise Maintenance policy change. The was a heated discussion on TheServerside.com and even FAQ was compiled by Rod Johnson to explain the whole thing.

So what is the issue: SpringSource, commercial entity behind community driven Spring Framework decided to capitalize on the investment and push the community toward paid service suport contract. Whether or not it was related to funding round and VC’s entering the game, is not important. Unfortunately, the terms were not really well explained and SpringSource did initially very poor job explaining and communicating the actual change. The community overreacted and lot of people started to call for code fork, project Summer or similar – or switching to different framework.

What the change really means is that maintenance releases will not be available (as binary, official downloads) after 3 months, unless you pay for the support. It means that using new policy after let’s say release 2.0, only for three months everybody could download binary distributions of 2.0.1, 2.0.3 etc. If at the end of month 3 you would need fixes in the 2.0 branch, you would be on your own. The source code repository with 2.0 branch would still be available, with fixes committed (see later) but without tags (or labels) and certainly without pre-packaged download of 2.0.4, 2.0.5. You could compile the actual head of the 2.0 branch yourself, but it would not be clear what version you actually run.

This is actually not such terrible limitation as it may seem. Maintaining old code base and backporting the changes from trunk into fixes in branches is lot of work, requires testing and so on. SpringSource did invest a lot into the codebase and as commercial entity provides service to the users. The release management and software maintenance is slightly different type of work that developing new great release, and I can imagine that there are even less contributors and volunteers for this (seldom appreciated) kind of work. Multiply that with many branches and you’ll see the magnitude of the problem.

What did SpringSource do wrong, in my opinion is that they are taking away something that was available for the community for free and that created lot of negative sentiment. There are two ways how to push people to pay for free service – and cutting unless you pay is wrong one. Right way is to offer more on top of what is available for free, something that has value specifically for enterprise clients. There are several areas where there is a need: more and much better samples, template applications, guides, tutorials. Their availability has huge value for customers in saving development time and better quality of the products using the Spring platform.

There are several technical subtleties that are in open: the FAQ says that the changes and fixes from trunk will be available in the maintenance branches, but does not say when. Delaying changes can be powerful argument … Lack of tags in public repository also implies existence of private repository with these tags – how else could the SpringSource build the “supported releases”. The existence of two repositories in project (unless you use distributed VCS, of course) is often starting point of splitting project to payware and limited “community edition”. I hope this will not happen to Spring.

The most unfortunate impact of the maintenance policy decision may be for the Spring based opensource projects, that helped a lot to establish acceptance of the platforms over last few years. Dilema of facing either cascading changes of permanent upgrades just to keep in sync with latest trunk version, or permanently monitoring the branch to see which of the changes are important – in absence of “official” maintenance release with defined bug fixes etc can be an issue for many projects. I hope SpringSource will find workarounds and solutions for these.

Despite of that, forking Spring would be very bad idea. The very last thing enterprise Java needs is another framework that is esentially same or very similar than existing one. SpringSource employs brilliant engineers, Spring community also has great contributors – what is the point of splitting the forces when there is no architectural disagreement, the issue is “just money” ?

Forking also does not solve the core problem: who will be providing the community service of maintaining and building the old releases. The maintainers of Summer codebase (or whatever the name of Spring forked successor would be) will face the same dilema – choose between working for free forever or finding way how to employ enough manpower to keep the balls rolling.

I would recommend that instead of forking Spring codebase, whoever feels like it, try instead to fill in the gap and provide the “inofficial official” builds, a “community maintenance releases” as counterpart and alternative to official SpringSource maintenance releases for enterprise (== paying) customers. This would actually help the project and all projects that depend on it much more than asking them to switch.

It would also not hurt SpringSource – I am convinced that they would loose very little revenue (if any) because of that. It has been done (Centos vs RHEL). If my project would be based on Spring platform and not on commercial Java server (which it is not) and the support cost would be reasonable (which it IMHO is), I would happily pay for priviledge to have access to the people of Juergen Holler’s caliber (and many others).

Let’s face it, folks: when it comes to support and software maintenance and similar less attractive areas of our profession, there is definitely no such thing as free lunch …

Three great Git resources

2008/09/20

Before I forget :-)

1) The Git Magic

2) Two git books Pragmatic Git Book and Git internals – nice complement each other

3) Linus Torvalds slightly offensive and very funny talk at Google

in addition to great, precise but not necessarily most digestable manual

Good read – not only for software architects

2008/09/08

The 97 things that every software architect should know:

http://97-things.near-time.net/wiki

Actually, it’s 87 but new are still coming. You may add your piece if it is not yet there …

Milos – thanks for the link.

Objective C: I really miss namespaces

2008/09/02

One feature that I strongly miss from Objective C are namespaces. Inability to avoid name clash between your  classes sometimes really stands in your way.

I am reading S. Kochan’s book “Programming in Objective C” and in one of the examples he creates the class Point. Unfortunately, there already is struct Point defined in mactypes.h.

The solution is easy – rename the darn Point to something like TKPoint … at least that is what Cocoa naming guide recommends. It is probably matter of getting used to it  – but I still find the solution suggested by Kevin Hoffman much more elegant – too bad it is only theoretical. Much nicer than NSHack ;-)

XCode annoyances

2008/09/01

I have started to seriously play with Objective C and XCode about week ago. So far it was very pleasant experience. I really like the language – feels like Ruby (or Smalltalk if you want) with rocket launcher: very powerful, blastingly fast and dangerous like hell. No array boundary checks as in Java :-) .

The XCode was not bad experience either. Here my very long Eclipse and Visual Studio history is going a bit in the way, as the things often works quite different. Not necessarily worse, but different. It would be too early to judge it – not before I get more proficient in both Objective-C and XCode and learn more Cocoa goodness.

Two things however are so annoying, that I have to mention them right now:

1) Setting breakpoints was gamble – sometimes it worked, sometimes it did not. I could not figure out why, until I found here that you must in Preferences -> Debug switch off the ‘Lazy loading symbols’. After re-entering the breakpoints, I finally got it to behave as expected.

2) Trying to add existing files to a projects crashes the XCode with the following:

The console window shows error:


PM Xcode[34563] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '
*** -[NSAutoreleasePool stopObservingModelObject:]: unrecognized selector sent to instance 0x32da240'

which is clearly a bug. I tried to reboot (it was about time after running for over two weeks anyway), no help.

Weird is that I remember doing that before without any problems ... Workaround is use drag and drop, of course, but I wish Apple would fix this Really Soon, as it is plainly embarrassing ...

I have seen crashes like this in Visual Studio, but Eclipse was rock solid environment despite the very complex plugins ecosystem, so it is hard to go back to use something blowing under your hands ...

Agile development team member mantra

2008/04/21

Introducing code review and pair programming has often an impact on relationships in the team – especially when a critique needs to be delivered. It takes great degree of experience on both sides to communicate defects in the code for both the reviewer as well as for the code author to get something useful out of it.

I found this at http://www.finetix.com/blogs/finetixblogs.html which can be helpful (page is 404-ing now, but I luckily saved it in Google Docs way back) :

Everyone, including me, repeat after me:

  • I am not my code. A criticism of my code doesn’t have to be a personal attack on me.
  • I am not the tools that I use.
    A criticism of my tools shouldn’t be construed as a personal attack on me.
  • I am not the programming language that I use

I will try to remember it (and read it to all participants) next time we get into the passionate discussion about whether inheritance or delegation is the correct approach to implement feature X :-)

On hardwood floors and software engineering

2007/11/05

I am in the middle of a non-computer related project. Last week we have decided to get rid of carpeting in my home office and library and to put in the hardwood floor. My wife picked the wood and color, I picked the contractor, with my son’s help we moved out the furniture and the renovation started. The most painful thing was shutting down and disconnecting all the computers and servers – only the lonely router is hanging on the wall and suffering the dust and noise of the power tools. As result, my family is now server-less and until we finish and connect them back, we have to survive using the notebooks only. Fortunately, I have at least one notebook available for each household member, except the cat. Even more fortunately, she (the cat) does not mind.

Surprisingly, this project reminded me of something that is so familiar when you are working in enterprise IT environment and deal with real life systems and real companies: you cannot do just one thing. After we uncovered the carpets, we have discovered few hidden issues that had to be fixed before we could put the hardwood in. In process of fixing it, another issue popped up and we ended up replacing the plywood that was under the carpet. As result, what was supposed to be done in 2-3 days, will take twice as long and will carry according price tag. In all this we are extremely lucky having very good, capable, hard working and honest contractor doing the work.

So, does all this renovation have anything else in common with software engineering? I think it does. Year or so ago, we had this discussion about metaphors, paradigms and models for the software development process. One of the discussion’s topics was why is our (presumably engineering) profession so bad in estimating the time and effort required. Look at the guys building the houses – Steve challenged us – they can tell with 5-10% precision when they will be finished and how much will it cost. Even better, when customer changes his/her mind in the middle of the project, the impact of the change on timeline and price can be determined with fairly high accuracy.

We have talked about obvious differences between building a house and building a software system. The house is pretty much always the same – can be bigger or smaller, but the variations are very small compared to possibilities of software systems. There is very small selection of materials, the components are well standardized and the process of building has been tested and fine tuned on millions of houses built. The workforce in construction business is very much standardized as well – the productivity can be easily measured and deviations between the most and least productive worker are much smaller than in software world. The laws of physics help too – by making the completely wrong combinations of components more obvious and easier to spot. In short, construction of a house is bad metaphor for building a software system.

What seems to be much better metaphor (if we have to stay in the realms of construction business) is house renovation. Here you have to make assumptions and will make discoveries as you progress – and this maps nicely to the process of requirement “gathering” (whoever created the term gathering was idealist, in reality it is much closer to digging for requirements, but back to the topic). You start assuming that your job is to put in hardwood floor – or to integrate two software systems. In reality, your job is to resolve unknown number of problems of unknown complexity in order to even start.

You have the legacy of existing house, plumbing, infrastructure – similar as you have legacy enterprise systems, databases, data feeds, business owners and so on. You may be aware of some them before you start, but their true size, nature, status and complex interdepencies will became fully understood only during the process of renovation (or integration).

So what is the moral of the story and what is the right approach ? I have no answer that would work in every situation. What worked for me – is honest communication and transparent decisions. Make sure that the customer understands what is included in the estimate, what are your assumptions and what can potentially be hidden issues if there is an indication you may find some. Whenever you discover something that may change the scope, do not delay telling the client and make sure he/she understands all possible pathways and their consequences.

Be generous – if you need to invest extra time to make sure the recommended decision is the best option for the client, invest that effort regardless whether the cost will be covered by the client. If you go that extra mile, in long run you will be always rewarded – with repeated business, better rate or at least the good karma for doing the right thing.

Document all agreements, discoveries, options presented and decisions – they may be great reference when facing similar decision in your next assignment. And sometimes the document trail you leave behind may be only existing documentation of the system in question. The contractor that comes next, will thank you for that. If you do your part properly, that somebody may be the future you.


Follow

Get every new post delivered to your Inbox.