Chang-chang-a-ching-changa-langa-langa: Why Your User Community is Fluent in English and You Are Not the King February 6, 2010
Posted by ActiveEngine Sensei in .Net, ActiveEngine, Business Processes, Coaching, Fluent, Problem Solving, software economics.Tags: ActiveEngine, ActiveEngine Sensei, bad software, balance, communication, new thinking, Problem Solving
add a comment
Get ready for the sound of one hand clapping, but first, fire off the song as it get’s your head straight.
Some of you want to be Elvis too much. Sensei’s going to tell you a story so you know what he’s talking about. You see, users of your apps are waaaay smarter than you, and spend more time in their fields than you ever hope to do. You need a little love. It’s called fluent interaction. Fluent. Interaction. Lord have mercy.
Process mapping helps, but in the end that takes you to overly scientific abstractions, and while user stories help some they, too, stray with you as the sole author. You in the chair, just the important details from the user, but mostly you. Should you consider yourself not Mort but an Elvis, you may want to ask yourself what Elvis you want to be:
Kick-ass Karate Elvis![]() |
Drug Ridden Elvis Wanna Be![]() |
Back to the story. Last episode, in a spate of productivity and a dose of SQL-NoSQL fever, Sensei created a slim document management solution that can be quickly applied to an existing framework with minimal impact to database schema and code base. Sitting around the conference room table the comment arose from Annie, the project lead from the Sales group:
“Why do I have to save a commission record first before I can attach a document? That interrupts my flow. I want to put in everything that I want and save, period. No dialog box thingy prompting to save first, come back and do something else. Why can’t we just do it”
Long silence. The sound of one hand clapping.
One of Sensei’s report-to’s jumped in: ”Because in order to associate the document to the commission you have to save that commission first in the database, then take the id from the record and associate it document. This allows you to retrieve it later on.”
Annie: So. Can’t that just happen behind the scenes? If it’s two steps the sales gal won’t do it. She’s got calls to make.
Ssensei drifted out in research land, or as normal people call it, he spaced out for a bit. NetFlix sprang to mind, iPhone too, where you delete, it does it, but you can bring it back. Take the confirmation response out of the equation. Give the user a chance to undo their mess, but don’t get in their way. It’s fun to pretend to be the King, but what a wake up slap. The technology was right, but the user was seeing the benefit because “putting the stuff in was too clunky”. Sensei went and did want Annie wanted. Annie thinks its great. Good technology made better by the user, not the King.
Fluent. Interaction. Lord have mercy. You see, Annie’s right and user stories, UML and other brain death would never capture the essense of her perspective, particularly after she used the software. Yeah, soft deletes are great theory, but you are not thinking like a user. In order to be a better King, you gotta give the concert they want to hear. You have to know that the fans have created you, have shaped your persona. You have to know your fans, almost be them.
Elvis had a come back concert in 1968 but it almost didn’t happen as there was a huge fight with NBC. The network insisted that the show would be like a Bing Crosby special given that the air date was during the Christmas holiday season. Elvis wanted an intimate environment where he could perform up close, live with his fans. He thrived off of close contact with his fans. Know your audience. Elvis was right, and it helped re-launch his singing career and revive his legend. It was one of his best performances. For the fans.
You need to listen to your users. Spend the time to hone your craft,
but work even harder to make them fans. What do they need? Is the concert for them or for you? Are you learning just to be smart or for their benefit? Fluent solutions require interaction with the fans. Thank you. Thank you very much.
More Inspiration January 30, 2010
Posted by ActiveEngine Sensei in ActiveEngine, Personal Development, Problem Solving.add a comment
New inspirational video is up on the Hope section. Enjoy.
Fluent Thinking – C# Plus SQL Equals CouchDB. Maybe. January 23, 2010
Posted by ActiveEngine Sensei in .Net, ActiveEngine, C#, New Techniques, Open Source, Problem Solving.Tags: ActiveEngine, C#, CouchDB, Data Model, Document Management, new software, new thinking, SQL Server
1 comment so far
I’ve gone too far to turn around
It’s hard to reach for you
When I’m lying face down
I can’t relieve my soul
I’m lost in a moment
Lying face downSaving Abel
There are moments when life brings too much possiblilty to your attention and your mind catapults into overload. Take the great potential that CouchDB has, as an example. Elegant, simple. Damien Katz has ignited a real fire storm with his work and may have single handedly given rise to the not-a-RDBMS movement. Sometimes developing under the gun, Sensei has to admit that the 3rd normal form restrictions can be a little inhibiting. Really, a collection of value pairs will do quite nicely, and XML, when it doesn’t run on for more that 1 page can be quite descriptive, it still is not quite the solution for quick configuration solutions. JSON is just about right, easy to manipulate, and this is why Damien chose this as the structure for a document in CouchDB.
“But Sensei, I have SQL Server. We aren’t allowed to say the L-word!”
“You mean Linux, right? Just checking.”
There may be constraints imposed by the environment you have at your disposal.
And if you have a current system in production you might have a hard justifying to the powers that be that you should download a LAMP server from JumpBox just so you can introduce doucment managment into your current production system. Or perhaps you have an extensive data model and are concerned that that the meta data would too complex to store with the documents.
Here’s a simple yet effective way to introduce a “CouchDB lite” version to a current database platform that is applicable to SQL Server, Oracle, MySql and provides a flexible way to store meta data for quick retrieval. It’s not badass like Sam Jackson, but it’s not ridiculous like the beast picture next to him either.
The goal stated succinctly:
- Provide the abilty to associate a document to a record in an existing DBMS
- Provide the abilty to store the meta data related to a specific record or a document type.
- Ensure that future meta data and document types will not a change in the cardinality of the database schema nor require the addition of additional database attributes.
- Provide a object oriented framework that adheres to the Open-Closed principal; that is, open to extension but closed to modification.
Previously Sensei has opined regarding fluency, and this solution adheres to those prinicipals. For existing RDBMS a single table can introduce the simplicity and clarity you seek. All document meta data can be stored in a table aptly named Document:
CREATE TABLE [dbo].[Document]( [DocumentId] [int] IDENTITY(1,1) NOT NULL, [UserId] [int] NOT NULL, [Name] [varchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [PostedDate] [datetime] NOT NULL, [DocumentHash] [varchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [Attributes] [varchar](8000) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, CONSTRAINT [PK_Document] PRIMARY KEY CLUSTERED ( [DocumentId] ASC )WITH (IGNORE_DUP_KEY = OFF) ON [PRIMARY] ) ON [PRIMARY] GO SET ANSI_PADDING OFF GO USE [REIMS_DEV] GO ALTER TABLE [dbo].[Document] WITH CHECK ADD CONSTRAINT [FK_Document_User] FOREIGN KEY([UserId]) REFERENCES [dbo].[User] ([UserId])
In brief, this table stores an identity key for each document, the name of the document, a foreign key that represents the user / person who saved the document, and the date when the document was posted. The attribute DocumentHash is a hashkey comprised of the DocumentId, the UserId, the Name of the document, and the PostedDate. The DocumentHash value is prepended to the document name to create a unique document. Consider it a way to associate the document with a specific record in the database. In other words, you should be able to re-create a haskey from the data attributes that matches the value pre-pended to the file name of the document. Another nice by-product is that you can version documents quite easily.
Focus next on the column named Attributes, as this is where the magic happens. The meta data for each document is stored here as JSON. This takes the following form:
[{"Key":"Owners","Value":"79,2,4,79"},
{"Key":"BonusId","Value":"95"}
{"Key":"BonusTypeId","Value":"3"},
{"Key":"DealId","Value":"1035"}]
This JSON serilization of an array of Key/Value pairs is a format that allows you store whatever meta data you wish. Notice the first line named “Owners”. This allows you to store the user id’s of all users who have the ability to delete or edit the document. You can set security based on this attribute, and implement a document centric security framework that can exist in addition to security place on the share where the document is stored.
As stated earlier, any type of data can be stored in the Attributes column. If you notice line 2 that reads “BonusId” you see that keys to other tables in your database schema that can saved with the document record. This feature allows you to maintain the relationship of a document back to a particular record or set or records.
You may be asking yourself why the Key Value nomenclature in the JSON string. The attributes can be deserialized to an object of type List<KVPair> where KVPair has the following structure:
namespace BusObj
{
[Serializable]
public class KVPair<TKey, TValue>
{
public TKey Key { get; set; }
public TValue Value { get; set; }
public KVPair(TKey k, TValue v)
{
Key = k;
Value = v;
}
public KVPair() { }
}
}
The Key Value pair lends itself to simple querying. Since the attributes can vary from document to document, the meta data can include identity keys to records in your existing database schema, information regarding folder structure where the documents can be stored, and what ever other piece of important information of you need to retain. Once the JSON is deserialized to List<KVPair> you can use lambdas to query your documents. Consider the following code that is used to determine document ownership where the owners are represented as
{"Key":"Owners","Value":"79,2,4,79"}:
public bool IsDocumentOwner(int userId)
{
Enforce.ArgumentGreaterThanZero<int>(userId,
"Document.IsDocumentOwner - parameter userId can not be null");
// No attributes?
if(this.DocumentAttributes.Count == 0)
{
return false;
}
return DocumentAttributes.Find(x => x.Key == "Owners")
.Value.Split(',')
.Select(s => int.Parse(s)).ToList()
.Contains(userId);
}
As you can see, multiple users can be designated as an owner of a document. Any operation that is to be performed on a document can be quickly validated against the owner list, so actions such as deleting or displaying document can be quickly validated. Since the attributes are stored as JSON, you can easily augment existing documents.
The possiblities here are quite exciting. Perhaps you are looking for a quick an easy way to store configuration of objects but XML would prove to be too complicated to maintain. You could create an entry in the Document table with the attributes you wished to store and retrieve quite easily. Or, you can easily create a categorization system for documents that sit out on shares and you need to correlate these documents to records in a accounting package. There are numerous things you could do to make your life easier.
Full source code will be posted soon where an in depth discussion of the implementation will continue.
The Economics of Authority – Windows Workflow and Why You Should Cash In Before Rolling the Dice January 18, 2010
Posted by ActiveEngine Sensei in ActiveEngine.Tags: ActiveEngine, C#, new thinking, Stateless, Windows Workflow
add a comment
Although many measure their success by their salaries, bonuses and bank accounts, this report card can be a limiting factor when starting a new endeavor. If you follow this train of thought too closely your creative muscles will atrophy and very likely you will be unable to capitalize on opportunities as they arise. Or worse yet, you will be unable to recognize the need for you to break out of mold.

Sometimes you can obtain a payment of a different kind from struggling with a new idea: authority, recognition, reputation, knowledge, and maybe skill. For those of you who are feeling limited by your development environments , flexing your creative muscles can be an even greater challenge. There is also a danger for a great many of those who are too comfortable, as they are so accustomed to their current development frameworks they don’t know that they are “out of shape”.
It is too easy to become a subject matter expert, drink the cool aid and parrot every podcast that you hear that technology X is the leading edge solution. Going to the next client offers a new opportunity to build a solution based on the gibberish that was misconstrued as leading edge. If it’s new enough then there is a chance that few others will be able to actually challenge the new silver bullet’s validity as a viable solution. In software we do this all the time. It is a form of lying. While in the short term it may appear that you are enhancing your authority by bringing new solutions to a client, in reality you are diminishing your authority.
Getting out the big guns for a fight, Sensei is taking a stand as he recently repudiated the recommendation to use Windows Workflow Foundation.
The Quest for Fluency – An Introduction December 29, 2009
Posted by ActiveEngine Sensei in ActiveEngine.3 comments
In a different post I’ve discussed how chess master Josh Waitzkin mastered the field of chess and a martial art, winning world championships in both fields numerous times. In true Budo fashion, by learning to focus Josh was able to achieve an elevated ability to evaluate multiple
contingencies and make innumerable judgments rapidly. In his quest, Josh discussed how certain mental patterns enabled him to make logical connections and solve thorny problems as if by reflex. So deeply ingrained were these mental heuristics that the imagery that they projected onto his thoughts actions “seep” into his martial arts training. Josh possessed the capabilities of rapid recall, projection and judgement. All in an instant. A turbo ActiveEngine.
The meme of “10 years to master a subject” is passing again in the software development circles. Mary Popendieck gave an excellent presentation that discusses the deliberate practice of performance and how you must make measures in order to improve. 10 years alone is not enough as you need to make objective judgments to gauge the effectiveness of your efforts. What is at issue is whether you can achieve this during your work day.
Not all organizations are concerned with developing your fluency; rather, they want efficiency but may not be able to judge when GTD leads to too much context switching and re-work. Your job as a practitioner of ActiveEngine-do is to prepare yourself and solve the short term problems of business with your steady practice, enduring devotion to mastery. It’s tough to do. Customers see screens, they don’t get it that the ice berg goes on forever beneath the surface of the ocean. Management’s objective is to get along with the current regime and hope that resources and budgets won’t be further reduced by silly decisions such as “Hey, database administrator over there! We never have any issues, what are you really doing? You’re fired”. Or worse, “let’s outsource our core development to a foreign country that is 8 hours ahead of us. Oh, you’ll be tired from talking on the phone at night, but that’s ok, as you’ll won’t be doing the real work. Gotta go – next meeting to attend!”
Creating a working model of your software solution becomes the most important item on your agenda. Without one you will be enslaved by capricious, vacuous wishes of the business units. You need to create an environment where the business team can join you, the developer, in a shared heuristic. That is, you need to be able to summon their creativity and guide it every time you meet. Two minutes of warm up, then go. Discipline them, and you will be better able to concentrate.
“Scenarios”, “persona’s”, “Spec’s” and other dev-speak nomenclature are now forbidden. Replace those words with “story”, “description” and “model”. Be prepared to demo alot, so HTML, JSON and Javascript are your friends. it is assumed you know your way around the server and database, but set these strengths aside as they are not needed yet. Be prepared to spend time on the aesthetics up front, as you need to fluency of communication, and colors will hang people up. It is unfortunate, but that is a law. In the martial arts, certain small details are focused on as their mastery opens up your performance. Presentation of the working model is one of those details. Get it right and you’ll find yourself riding a huge wave of good synergy with very little surprises in store for all parties.
You also need to eliminate, if you can, customer / developer impedance mis-match when translating the working model to functioning code. The simpler the code is, the less you have to summon up into your skull and retain in order to work. Think of it as working with an unfettered mind. It would be nice if your model of the problem domain could just become working code, instead of you switching gears and creating a map of business requirements to packages. Over the course of the next few months Sensei will introduce some tools to help you along the way.
More than .Net, jQuery, S3 and Corporate-Speak November 24, 2009
Posted by ActiveEngine Sensei in ActiveEngine, Coaching.Tags: Philosophy
add a comment
This new section of ActiveEngine called “Hope” will focus on inspiration, endurance and hope. Those are the foundation of your ActiveEngine. Your ideas can not be forged without them.
The corporate droogs can not rob you of these ingredients, although they may try. Look above, not around for your inspiration. Listen to the unwanted but eerily familiar voice that you squelch in your meetings, PowerPoint presentations and esoteric vocabulary.
First round is a gentle reminder of why we need to break free.
Uno – Dos – Tres Mono! What MonoDevelop Means for your ActiveEngine November 18, 2009
Posted by ActiveEngine Sensei in .Net, ActiveEngine, Linux, Mono, New Techniques, Open Source.Tags: C#, Mono, MonoDevelop
3 comments
Much of Sensei’s philosophy is based on stepping out of your comfort zone. When practiced frequently you enable yourself to pilot your way through situations where you may have to possess more confidence than facts. And let’s face it, sometimes it just out right fun to wing it when you test your skills with the unknown.
MonoDevelop is a platform that will do that very thing. It will change the way you think about your application’s architecture as you can branch out from
the Windows stack. Why not a C# back-end with PHP as your UI / presentation layer? Why wait for “IronPHP”? For the curious, MindTouch, an open source Wiki / CMS engine does just that. It runs on both Windows and Linux with the core engine is written in C#. This engine includes an embedded script parser written in C#, as well as an implementation of tuples and an excellent XML utility class that will make you wonder why you ever why Micorosoft could not have made something, well, easier.
If you are nodding your head in agreement, but are still skeptical that you have the time to make the leap to Linux, MonoDevelop is deployed with a openSUSE VMWare slice that only requires 512 MB of memory. Really light weight. It takes longer to download than it does to spin it up. It’s just ready to go. the IDE is based SharpDevelop and comes with Intellisense that admittedly does not play well with some cases Lambda’s and Anonymous Types. This may become apparent when you import an assembly, and it slowed Sensei down for a bit. Know that this is a failing of the intellisense, as when you get a clean build and test you’ll find that your code is all right. You’ll need to have confidence in your code and may have to devise additional tests to validate that everything is working.
Save this failing of the IDE, the remaining features are quite nice. THE IDE LOADS REALLY FAST! I mean Microsoft should think this through. VS Studio, while feature rich, is a dog with respect to speed. Personally Sensei thinks we’ve been lulled into thinking that 2 GB is a minimum and that’s “progress”. When compiling, watch your CPU on the host machine. Remember your Guest OS is using 512 MB and it produces a build quickly. It’s rather impressive. For VS on Windows Sensei uses 4 GB of RAM and there are times when he sits waiting. Hmmm…
MonoDevelop comes integrated with NUnit, and natively supports Boo – yeah, the stuff that Ayende raves about – MoonLight, which is a port of SilverLight, and of course ASP.Net. MonoDevelop lacks robust refactoring features. If you have ever used Resharper or DevExpress you’ll have shared the same regrets that Sensei has about having wasted time in the IDE. The same holds for MonoDevelop. In fact, there are times when the refactoring add-ins throw exceptions. Outside your comfort zone you will be. That was Yoda talk.
So where are we with all the man-ish developer bravado? Mono can be a lateral jump for you into a new series of platforms.
Using VMWare you can easily setup test environments and fail. Fast. Yeah, that’s a good thing. With most Linux builds you have the chance to use Lua, a really fast embedded scripting environment. Lua is native to a new open source database called Tokyo Cabinet you gives you the choice storing data in Value Pairs, B+Tree, or normal indexed table schema. Here’s a cool presentation detailing the possibilities. More comfort zone? How about NHibernate and Spring.Net? They have been reportedly ported to Linux with Mono.
Wrapping it up ’cause Sensei’s running long. Just do it. There are many possibilities here that you are missing if you stay safe. There are many views that are beyond Microsoft’s vision that they provide for you. And that’s the point. You’ll be more agile on your next gig if you’ve already solved problems beyond the scope of normal. Yoda translation: ”Agile you will be.”
Holy Snikies – Emit jQuery with C#!!! October 29, 2009
Posted by ActiveEngine Sensei in .Net, ActiveEngine, C#, New Techniques.Tags: jQuery
add a comment
Brief but exciting and really cool.
There’s a new .Net solution called JSM that will take code like this:

and emit this:

Head over this nice presentation for further details, or read this gentleman’s post. This looks very cool. Question is whether you can use plug-ins as well.
Source code is here.
Why Your Code is a One Way Time Machine October 19, 2009
Posted by ActiveEngine Sensei in ActiveEngine, Agile vs Waterfall, Mythology, Problem Solving, software economics.add a comment
What type of duress are you under? The unfortunate among us have been sentenced to slavery by our evil nemesis from the past. We all have this enemy, and at one time or another have succumbed to the enemy’s evil plot. The enemy from the past is YOU.
When you sit down to create a solution, you need to balance solving the problem with being able to maintain and implement changes to the logic you have selected. All logic changes, and there are very few times when you have the finite scope defined to be able to accommodate new ideas. ”Rewrite!” is the cry of many who have written good solutions that have solved the problem but more than likely are not very maintainable. ”Broken Cardinality” is the bane of all DBA’s, and this is very serious indeed. Sensei can’t help you with that – go beat your business analyst who didn’t drive home the rules of relational databases!
What Sensei will say is put your tools after you think you’ve solved your users problems in a two week sprint, step back and project into the future: will this code be readable; can you augment the logic without altering the methods; will you be happy with yourself at midnight trying to fix something? Addressing these concerns helps you maintain your solution.
The real challenge is to help yourself next year. The-future-you needs your help, but The-future-you will hate you if you misconstrue YAGNI in your design phase with avoid-refactoring-at-all-costs while you code. Forget the sprint. Putting something into a customers hands too soon masks the complexity of what you have done for them and undersells your true talents. They’ll be happier if you can quickly implement changes without impacting the existing environment. Congrat’s – The-future-you just bought a beer!
Dave Ward at Encosia Just Rocks! October 15, 2009
Posted by ActiveEngine Sensei in ActiveEngine, New Techniques, Problem Solving.Tags: jQuery
add a comment
If you are looking to have your mind just blown away at how hard we’ve been toiling with the tool set for .Net development, watch Dave Ward’s screencast on learning jQuery with FireBug. Forget Visual Studio and Intellisense, forget MS Ajax. Go find out how much time you have been wasting.
Dave has a brilliant series on jQuery and the beauty is he keeps it simple, but it is extremely effective. Mind-meld with his posts and find out why he is smarter than Spock! Take it on out with a jam.



Subscribe to this Blog!