Wednesday 1 February 2012

Installing WebStorm on Ubuntu

Get Webstorm (its worth it)

then ... 

Install Java JDK 1.6+ first (see full http://superuser.com/questions/353983/how-do-i-install-the-sun-java-sdk-in-ubuntu-11-10-oneric )

sudo apt-get install python-software-properties
sudo add-apt-repository ppa:ferramroberto/java
sudo apt-get update
sudo apt-get install sun-java6-jdk sun-java6-plugin
You may want to also add the following
sudo update-alternatives --config java
You should get the following
  Selection    Path                                      Priority   Status
------------------------------------------------------------
* 0            /usr/lib/jvm/java-6-openjdk/jre/bin/java   1061      auto mode
  1            /usr/lib/jvm/java-6-openjdk/jre/bin/java   1061      manual mode
  2            /usr/lib/jvm/java-6-sun/jre/bin/java       63        manual mode

Press enter to keep the current choice[*], or type selection number: 2
Select (2) and press enter
Now running:
java -version
Returns:
java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) Server VM (build 20.1-b02, mixed mode)

How-to setup M-Project and Espresso with Node.js on Ubuntu

git clone https://github.com/mwaylabs/Espresso.git
cd
git submodule update --init 



alias espresso='~/Espresso/bin/espresso.js'

(check version is => 1.0.0.0)
espresso version   


(init it with some example files)


cd devroot

espresso init --project=Nodey2 --example 


(spin up the m-project via the espresso server)
cd ~/devroot/Nodey2
espresso server

..calling the cloud9 ide
~/cloud9/support/node-builds-v4/node-linux32 ~/cloud9/n/cloud9.js -w ~/devroot/Nodey2 -l 192.168.1.12 -p 3101 -a x-www-browser 

interesting sample.. useful to get the first couple of pages going

get a theme going with ThemeRoller


Friday 27 January 2012

Setting up my Node.js solution in Cloud9 IDE

Now where do we go after we have a brand new toy.. I just installed Cloud9 IDE.. see how-to install cloud9 here.

I want to setup a quick web app (really, really quick). I will time it.

00:00 - Get all my favourite (sounding) node modules from npm (presume you have npm) then use...
npm install  


See all the goodies I got.. note espresso took some time. Also look them up at http://search.npmjs.org/#/ 

00:09 - I had to install mongodb separately using (can also go here ..)

sudo apt-get install mongodb
00:18 - Created a folder at ~/devroot/MongoDb/data/db for my MongoDb instances. Now to run the db server..
mongod --port 9080 --objcheck --dbpath "devroot/MongoDb/data/db" --directoryperdb --rest
Note: --rest == RestApi, --directoryperdb == create a new dir for each new db's files
Success == MongoDb web console at http://127.0.0.1:10080/ (not so sure about the port, but trust that the mongod startup script should tell you your magic port number)



00:22 - Try out the mongodb server quickly...


mongo 
db.foo.save( some json object here );
db.foo.find()
 00:24 - setup that web app... hmm
Ok. Make sure you have done a global install of express using
sudo npm install -g express 
00:26 -  Use express to setup your solution structure inside your project root
sudo express  
cd   
npm install 
Note: this  installs default packages only so I had to get other ones here by
npm install
It uses  the cache (304) so it does not waste your time. I have now installed,
ejs, mongoose, colors.. (see list above)

Lets setup some routing .. see a good guide on expressjs here .. i am not re-inventing this.

Should be easy enough from here... good luck!


Node.js and Installing Cloud9 IDE

I am a bit infatuated with node.js at the moment and the whole real-time web thing. So trying to get it going on my machine. Why??? A.) I love javascript. B.) I love javascript. Always have. Never in secret. Been glared at for writing jQuery apps, etc. I have done all the other languages too (C#, java... respect.. they've paid my wages).

So... I have been at this for a whole day... phew! Tried on windows (gave up!) and now on Ubuntu. Need to go back to the mac (yes, I admit, the war is now over). I am lazy, I like simple kits, but I like a working IDE, debugger, etc. So I hunted around and found a few...

  • WebStorm (from JetBrains and they still make that super ReSharper VS-addin)
  • Cloud9 IDE - a nodejs based web IDE - how cool.. and open-source so you can run it on your box
WebStorm was simple enough install, could find all the modules but I could not get the debugger going. Anyone good with this, please ping me at kenn9j.at.gmail.com :) 

Cloud9 IDE was not simple to get installed. Too many rig-ma-roles... but it kicked in.. and here is how...
  • Go to http://gratdevel.blogspot.com/2011/03/setting-up-cloud9-on-ubuntu-1010-32-bit.html it says most of it.. (forget windows for now)
  • If you are running a 32-bit Ubuntu on 64-bit windows vmware like me.. all will not go well. So at some point you will get... "error while loading shared libraries: libssl.so.0.9.8: cannot open shared object file: No such file or directory" 
  • Fix it with - sudo apt-get install libssl0.9.8 
  • Start cloud9.. point to your project folder and it starts up in the ide.. in your default browser... :) smile... 
path-to-node-v4-build path-to-cloud9.js -w path-to-your-project -a x-www-browser 
~/cloud9/support/node-builds-v4/node-linux32 ~/cloud9/bin/cloud9.js -w ~/devroot/Nodey -a x-www-browser 

  • Add a little app.js file with a server in there like see above. Hit run (will have to configure first time so point to your app.js) 
var http = require('http');
http.createServer(function (req, res) {
  res.writeHead(200, {'Content-Type': 'text/plain'});
  res.end('Hello World\n');
}).listen(3001, "0.0.0.0");
  • Enjoy! It's a bit slow on my vm but it can debug. (can always two-time with geany) 


Friday 5 August 2011

I just got Scrum Certified.. am I still Rogue enough?

Recently, I sat through a two day Professional Scrum Master Training (lead by Richard Banks, Thanks R) and I could not help but jot a thousand little notes on all the gaps I had not covered in my past efforts at moving teams to follow agile practices using Agile Unified Process and a lot of what I learnt from Craig Larman, Mike Cohn and Scott Ambler. When I was trying to get teams to move to agile, I often felt challenged, confrontational, stealthy, manipulative, political, diplomatic... all with a noble aim of achieving true efficiency (by shaking up the system, getting people to collaborate and apply common sense).

Now I am Scrum Certified. I'm armed with tools to go out and officially be agile. Suddenly I can see every person in the mega organisation clambering to get this certification, since someone is going to kill Waterfall (if not me). Everyone will want to be "agile" and the status quo, without a doubt, will change.

So now what? I wonder if I am simply addicted to being 'Rogue' (an agent of change) or is there some empowering force that is going to make me settle down and feel like the we have all managed to vote for the same government and we should be happy in this new world.

Mike Cottmeyer wrote Having Your Cake… Some Thoughts Around Scrum Certification

Scrum can’t have it’s cake and eat it too. It can’t be a simple framework that is not prescriptive and then start certifying people on how to do all this stuff.
But some day very very soon, the new army of certified agile people will turn it into a "process", and then someone will need to go rogue again and re-label everything to help others unlearn. Then there will be a new training, a certification and so on.. the economy needs this, right?

Sunday 8 May 2011

Will architects ever be agile

Its difficult. We cannot build the Eiffel Tower in iterations, we need a blueprint and more. But software is bit more flexible, you can refactor, its a lot more forgiving. Scrum suggests an emergent architectture over a 'predictive' style of architecture. Hmmm.. that is true for most agile projects. Of course not for solutions that have a 'solved problem', but rather for solutions needing spikes.
A good day...
Architects can work in the Product Planning team with the Product Owner and help define the architecture to support the User Stories. They can sketch out a skeleton.. an emerging road map that looks enough past the planning horizon to help the Product Owner and the development team envision the target state. And they can work with any developer or engineer (in a paired style) to develop prototypes/spikes.
Not such a good day...
Then you have special technology projects, new technology projects, flooded with new tools that only SMEs or consulting architects know about. Even the Product Owner can often feels so agitatedly dependent on their 'god-like' consulting architect that seem to promise the earth and never deliver anything tangible. And to add to it, they don't like to share enough of their expertise so the development team feels like they can't seem to go anywhere. The architects run away with the spike. No one knows whats happening. They go into a rabbit hole. And all they say at stand-ups is "its still in progress". When they are a part of our team, its difficult for the team.

What does a Scrum Master do to help?

All governance, no delivery
Architecture governance is a good thing. Larger organisations need it, the world needs it. It gives us standards which in turn gives us nice things like the internet, frameworks, etc. The best standards emerge from good development practice (not really the other way around). When governance is a gate for blueprints to be passed into development by first being vetted by people in architecture roles that have not developed for a long time, it just sounds (and turns out) ODD!

Often architects go towards consulting and end up in "reporting up" roles that slow down real development. Emergent "agile" architecture needs, Senior system engineers (aka Architects) to be able to share their expertise to bring on the younger engineers into how they see things work. Part of emergent architecture also need to "include" younger engineers in actively, 'hands-on' learning exercises, coding dojos, etc to share knowledge grow the teams capability rapidly via collaboration rather than some lame, late, incomplete, out-of-date, architecture design document.

Can emergent architecture work with governance ?
Using an emergent architecture approach requires a few key artefacts and one key activity..
  • Thing > Domain Model - (we all know this, if not google it) This should preferably not be too emergent.
  • Thing > Solution Road Map - this one is diagram with high level connections of how everything comes together, likely with 2-3 transitions states describing how the solution is expected to evolve based how much is know about the solution.
  • Thing > Mapping to Enterprise Architecture Capabilities - This is important. As architecture emerges, architects must map their solution components to an organisation domain model to allow future enterprise initiatives to weigh-in already built capabilities. This mapping must be stored in a model repository like Sparx Systems EA, ARIS, RSA or whichever tool is used to store the domain model. Preferably one that support a good "tagsonomy". 
  • People > Actively pair programming on spikes with developers and engineers - In my opinion, architects must actively participate in paired sessions to learn coding and stay close to engineering while sharing their perspective on the design for the solution as it 'emerges'.