Wednesday, May 2, 2012

The Wolverine Chromosome?

Is this Chromosome the Wolverine Gene?

I'm fascinated by code. The most fascinating code is the code that makes life work. I'm going to sidestep into genetics here a bit and wonder for a while if humans may one day look a lot like a comic book character...

So, Wolverine, as in the X-Men character Wolverine, has these key traits:

  • Heightened human senses of smell, hearing, and sight
  • Rapid healing abilities - especially from normally mortal wounds.
  • More energy than normal - I'm making an assumption here based on when he goes Berserk
  • Longer life expectancy
  • Super Agility - Strength, speed, and coordination are all heightened

All that sounds good, right? Wouldn't everyone like to be superhuman, get a longer lease on life, fewer trips to the doctor? Maybe Chromosome 11 has what we're looking for.
Chromosome 11

Maybe it is a bit like that. Chromosome 11 codes for:

  • Super Smell - About 40% of the genes that make up our sense of smell 
  • Super Senses - PAX6 - Master control of creation of sensory organs
  • Super Energy - Production of AcetylCoA for energy production
  • Super Healing - MMP7 - Wound healing and scar reduction
  • Super Senses II - BDNF - Nerve growth factor critical for balance, coordination, hearing, taste, and the sympathetic nervous system
  • Blood Cell Creation - Beta Hemoglobin. Creating red blood cells. If you have a mutation here, you may get Sicle Cell Anemia
  • Rapid energy uptake - Lipid digestion, Cholesterol creation, and fat processing genes
  • Rapid repair - Folate creation (B vitamin) critical for cell creation and rapid cell reproduction 

And I don't know where anyone would find a chromosome that codes for the creation of Claws that jut out from between your finger bones... maybe that one is still hidden in the genome somewhere!


Monday, February 27, 2012

On Patterns of Software Trends


I've been reading a Java EE patterns book Real World Java EE Patterns by Adam Bien. Lots of good ideas (although I must say it's disappointingly edited). It's like looking into a microcosm of the development experience I've "grown up" into during the last 15 years.
  • Netscape Navigator and the transition from HTML to dynamic pages
  • Applets fail.  Give way to dynamic server processing and JavaScript/ECMA
  • "Thin Client" and "RIA" dominate the 2000's - Fat client offered as opposing architectural choice. Note, most of this was in a push to wrangle the Desktop from Microsoft
  • Java goes to J2EE and Micro Edition
  • Application Server diversity splits and scatters implementations
  • Spring/Hibernate take over where J2EE leaves off
  • SOA comes into its own
  • .NET matures
  • Java EE course corrects major failings of J2EE
  • Sun Microsystems is consumed by Oracle

During this time, of course, both Oracle and Microsoft have provided their own "full-stack" in the same area. Apple became a dominant user interface provider (and therefore platform choice for development) in the last half of the previous decade.

Within both the Java and .NET communities, an explosion of languages fill the space. Knowing all of them to a level of proficiency is not an option for me.  I'm following the rule of 5 languages (more like advice) given by Bjarne Stroustrup.


The TIOBE index has kept up tabs on language popularity (and therefore market penetration). Current top 5 languages:
  • Java
  • C
  • C#
  • C++
  • Objective-C

Anyway, looking at this landscape I now find myself in, I'm trying to discern "best path" for what I ought to know.  Even within that top 5, there is a diversity that speaks volumes about the current programming environment. It's Java - for business (IBM, Oracle, FOSS), C - for low level development, C# - for Microsoft, C++ - for critical performance, and Objective-C - for Apple.

So therein lies the rub.  In development, when is it better to use one over the other? Is platform really the deciding factor in languages still? Did anything ever achieve Write Once Run Anywhere?  Seems like our industry has been chasing that dragon since C++.

One of the primary concepts in the book I mentioned above is this: Patterns exist as workarounds for shortcomings in a programming language or platform. I'd like to cover this in a future posting.

Break's over...

Wednesday, February 9, 2011

What is a Software Architect anyway?

Over at StackOverflow.com I posted this response to the question of What is a "software architect"?.

In retrospect, I still believe this is a good summary of the role, need, and title... which I see as different things people call "software architect". I'll expand on my own story a bit and add some more useful links from the original.

My Path

I was given the title and role before I had the tools to do the job. As often happens in software cultures, the "sink or swim" model would best fit description of how I got here. Well, that was about eight years ago. I bet on architectural choices like Web Services, the Microsoft .NET framework, and some back-end Java processing, and it's worked pretty well.

My software architecture has gone into several products and several versions with customer adoption and use. Whew! I made it! Stuart Smalley would be happy for my self-affirmation.

The next step has been learning, evolving, and re-evaluating where current designs stand. Where do new products fit? How do I integrate the products that came with that acquisition?

...and a host of cool, fun, and challenging problems. I actually liked software architecture.

Certification

Certification may make you an architect

... but certification won't make you a good architect. Some architects are home-grown, and are just placed in that role.

I'd like to get into a full explanation of each Architecture Framework, but that would drag down the post. Maybe I'll give a treatment of my assessment of each in new posts later.

What's the Technical Architect's role?

(I have also seen successful Enterprise Architects and Functional Architects)

  • Primarily technical leadership, like a Martin Fowler. Keeping abreast of industry trends and the effect on the software products under the architect's care.
  • They design the application architecture, specifically responsible for process-level, component-level, deployment-level items.
  • They solve the *ity problems of the system (Reliability, Scalability, etc).
  • They often handle the cross-cutting concerns of the app (Security, framework adoption, tool choice, etc).
  • Most often called on for POC or Prototyping (third party integration, platform upgrades, etc).
  • Handle SDLC issues like choosing the process for dealing with the version control system, process for the build, process for performance testing, and process for development testing.
  • Sometimes the archs that get stuck in process definition can get myopic about the software they're trying to create (IMO).
  • They can be called on to do PM, develop features, BA, Dev Mgmt, but that should be to pick up slack or ease project tightness.

The lines blur

Most shops used to get away with putting this role on a good Sr. Developer/Team Lead. When that team lead is only doing the Arch Role, then it's probably time to be fair to him/her and change labels.

Tuesday, January 11, 2011

AuthenticationNotSupportedException: DIGEST-MD5 on WebSphere

So guess what happened?

Running some simple authentication code from WebSphere failed on me. Here's the auth code...

private InitialDirContext callDirectory(String password,
String usernameWithoutDomain) throws NamingException
{
InitialDirContext ctx;
Hashtable env = new Hashtable();

env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.PROVIDER_URL, _ldapUrl );
env.put(Context.SECURITY_AUTHENTICATION, "DIGEST-MD5");
env.put(Context.SECURITY_PRINCIPAL, usernameWithoutDomain );
env.put(Context.SECURITY_CREDENTIALS, password);
ctx = new InitialDirContext(env);
return ctx;
}

And here's what WebSphere told me when it exploded.

javax.naming.AuthenticationNotSupportedException: DIGEST-MD5
at com.sun.jndi.ldap.sasl.LdapSasl.saslBind(LdapSasl.java:115)
at com.sun.jndi.ldap.LdapClient.authenticate(LdapClient.java:229)
at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2652)
at com.sun.jndi.ldap.LdapCtx.(LdapCtx.java:298)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:190)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:208)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:151)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:81)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:679)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:259)
at javax.naming.InitialContext.init(InitialContext.java:235)
at javax.naming.InitialContext.(InitialContext.java:209)
at security.ActiveDirectoryReader.openDirectoryContext(ActiveDirectoryReader.java:80)


The fix?
Took a while, but IBM support found that a setting in java.security which should have been set by default, was not set by default.

security.provider.7=com.ibm.security.sasl.IBMSASL

The number 7 above is the order that this property appears in the java.security file. This may be different in your java.security file.

Weird that it was off by default and should have been on. It was a big relief to find that it was merely a configuration change.

Thursday, January 21, 2010

TFS dangling edits, locks, and changes... eliminate!

Got an colleage who recently left the company for "greener pastures". He used TFS with the rest of us and all was well.

Last night I get an email from a buddy in California. Hey, John, dude, buddy, friend, I can't get to this file because Former Colleague has an edit lock. Can you help?

So... TFS can do this, if you have admin rights on workspaces.

First, get all of the workspaces that person has...
tf workspaces /owner:fcolleague

Then recursively destroy all their pending work...
tf lock /lock:none /workspace:WorkspaceName;USERNAME /recursive $/

Or you can obliterate the whole workspace...
tf workspace /delete workspacename[;workspaceowner]

Monday, June 15, 2009

Nullable Types

It's our friend from C#, and is a language construct for use with value types (such as int, long, double, byte, bool, etc).

int? iCanBeNull = null;

Perfectly good code, you can use nullable types for referring to data values that come across from the DB as null. This helps keep "garbage" out of the database.

How do you use them in if statements?

if( iCanBeNull.HasValue && iCanBeNull.Value > 57)
{
   //do some stuff
}

The compiler does autoboxing too (implicit conversion of nullable type to value type), but be careful! Booleans can't be used in "if" statements the same way any more, since a nullable boolean may have three values {true|false|null}. You have to instead use

if(nullableBool.Value) //works, but throws exception if it's null
{
   //do some other stuff
}
//this is bad for the compiler
if(nullableBool) //compiler error CS0266
{
   //never compiles?
}


Steffi! more input?
http://msdn.microsoft.com/en-us/library/2cf62fcy.aspx
http://msdn.microsoft.com/en-us/library/1t3y8s4s.aspx
http://blogs.msdn.com/ericgu/archive/2004/05/27/143221.aspx