<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Ivan's agile thinkings &#187; Constant Learning</title>
	<atom:link href="http://ivansthunks.com/blog/category/constant-learning/feed/" rel="self" type="application/rss+xml" />
	<link>http://ivansthunks.com/blog</link>
	<description>My thoughts and opinions on all things agile</description>
	<lastBuildDate>Sat, 02 Jul 2011 20:21:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Complex Systems</title>
		<link>http://ivansthunks.com/blog/2011/07/02/complex-systems/</link>
		<comments>http://ivansthunks.com/blog/2011/07/02/complex-systems/#comments</comments>
		<pubDate>Sat, 02 Jul 2011 19:57:54 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Books]]></category>
		<category><![CDATA[Constant Learning]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/?p=54</guid>
		<description><![CDATA[A lot of my reading recently seems very coincidentally related to the concept of complex systems.  What I&#8217;m reading proposes that linear (cause and affect) systems are the special case, the vast majority of systems in the universe are complex, emergent systems. Since getting my Kindle about a year ago I&#8217;m reading (and buying &#8211; go frictionless [...]]]></description>
			<content:encoded><![CDATA[<p>A lot of my reading recently seems very coincidentally related to the concept of complex systems.  What I&#8217;m reading proposes that linear (cause and affect) systems are the special case, the vast majority of systems in the universe are complex, emergent systems.</p>
<p>Since getting my Kindle about a year ago I&#8217;m reading (and buying &#8211; go <a href="http://www.elasticpath.com/elastic-commerce">frictionless commerce!</a>) more books than ever.   And because the Kindle is so convenient and I can read the same books on my Kindle, Mac(s) and IPhone it means that I generally read e-books rather than paper books.</p>
<p>However, its seems that I have defeated myself a little and should have read two of the paper books that have been sat on my shelves for over a year (since before buying my Kindle) and perhaps been that much ahead.</p>
<p><span id="more-54"></span></p>
<p>Number one is The Fifth Discipline by Peter Senge:</p>
<p><div class="amzshcs" id="amzshcs-e9bf7ab8ff737c25e202df8708e98260"><div class="amzshcs-item" id="amzshcs-item-60fa55aa49ac38fdcfedb031ada53c2a"> <a href="http://www.amazon.com/Fifth-Discipline-Practice-Learning-Organization/dp/0385517254%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0385517254"><img src="http://ecx.images-amazon.com/images/I/515ty-7SW9L._SL110_.jpg" height="110" width="76" alt="Image of The Fifth Discipline: The Art &amp; Practice of The Learning Organization" title="The Fifth Discipline: The Art &amp; Practice of The Learning Organization" /></a> </div></div></p>
<p>Number two is Out of the Crisis by W. Edwards Demming</p>
<p><div class="amzshcs" id="amzshcs-2612dad8be3ae769a344320e399df549"><div class="amzshcs-item" id="amzshcs-item-a78c87b9cdc7fb2aa295e82ca218e6d9"> <a href="http://www.amazon.com/Out-Crisis-W-Edwards-Deming/dp/0262541157%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0262541157"><img src="http://ecx.images-amazon.com/images/I/41cPHJT9e0L._SL110_.jpg" height="110" width="66" alt="Image of Out of the Crisis" title="Out of the Crisis" /></a> </div></div></p>
<p>Obviously, I don&#8217;t know what those two books say exactly, but they have been referenced and alluded to many times in my last few readings (and viewings).</p>
<ul>
<li>Learning and Perverse Incentives, a great talk by <a href="http://lunivore.com/">Liz Keogh</a>: <a href="http://www.infoq.com/presentations/Learning-and-Perverse-Incentives">watch at the most awesome infoq.com</a>.  In this talk Liz covers several examples of management incentives and controls that have very surprising outcomes (and generally not very good ones).</li>
<li>Surprising outcomes is a defining characteristic of Complex Systems as I learned from Thinking in Systems: A Primer by Donella H. Meadows.  <div class="amzshcs" id="amzshcs-19a7e813d5025d50af5a6d46e12622fa"><div class="amzshcs-item" id="amzshcs-item-a692a42f95b05b0e3052c1c9ca1f1cb4"> <a href="http://www.amazon.com/Thinking-Systems-Donella-H-Meadows/dp/1603580557%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D1603580557"><img src="http://ecx.images-amazon.com/images/I/511opot49sL._SL110_.jpg" height="110" width="73" alt="Image of Thinking in Systems: A Primer" title="Thinking in Systems: A Primer" /></a> </div></div></li>
<li>I&#8217;m currently reading Management 3.0 by Jurgen Appelo which is very explicitly bringing together a lot of the systems thinking into context for managing software development teams.  <div class="amzshcs" id="amzshcs-b273f834ca6e52b7a52150fd79336b5e"><div class="amzshcs-item" id="amzshcs-item-23d83270ff4430c28ecf6217e239b2cf"> <a href="http://www.amazon.com/Management-3-0-Developers-Developing-Addison-Wesley/dp/0321712471%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0321712471"><img src="http://ecx.images-amazon.com/images/I/51dtvyU2b4L._SL110_.jpg" height="110" width="84" alt="Image of Management 3.0: Leading Agile Developers, Developing Agile Leaders (Addison-Wesley Signature Series (Cohn))" title="Management 3.0: Leading Agile Developers, Developing Agile Leaders (Addison-Wesley Signature Series (Cohn))" /></a> </div></div></li>
<li>Influencer: The Power to Change Anything by Kerry Patterson, et al. This book is full of real-life concrete stories of people who have transformed complex systems to improve the world.  The example systems include controlling the AIDS epidemic in Thailand, eradication of the Guinea worm in African villages and how the Delancey Street Foundation has helped rehabilitate 90% of its residents.  This book really exemplifies &#8216;dancing with a system&#8217; to enact change, rather than trying to constrain and control a system and Shifting the Burden to the Intervenor. <div class="amzshcs" id="amzshcs-048f6a81abb4f9892969e77644a418e3"><div class="amzshcs-item" id="amzshcs-item-7052c9d724450affb8466d4f9a17288b"> <a href="http://www.amazon.com/Influencer-Change-Anything-Kerry-Patterson/dp/007148499X%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D007148499X"><img src="http://ecx.images-amazon.com/images/I/41bLXMol93L._SL110_.jpg" height="110" width="74" alt="Image of Influencer: The Power to Change Anything" title="Influencer: The Power to Change Anything" /></a> </div></div></li>
</ul>
<p>Whilst researching this post I stumbled on another book that is familiar to me, but only because I&#8217;ve intended to purchase it for several years, but for some reason I haven&#8217;t, which is surprising considering it&#8217;s written by the very astute Gerald M. Weinberg: An Introduction to General Systems Thinking.<div class="amzshcs" id="amzshcs-a52479c9e032787eca8eb9fec1d6f77b"><div class="amzshcs-item" id="amzshcs-item-c2406e9f889688fc683e1f69324a29fe"> <a href="http://www.amazon.com/Introduction-General-Systems-Thinking-Anniversary/dp/0932633498%3FSubscriptionId%3DAKIAIQX4B4ZEZPZQUHZA%26tag%3Damazonshowcase-20%26linkCode%3Dxm2%26camp%3D2025%26creative%3D165953%26creativeASIN%3D0932633498"><img src="http://ecx.images-amazon.com/images/I/519wB1bO2%2BL._SL110_.jpg" height="110" width="73" alt="Image of An Introduction to General Systems Thinking (Silver Anniversary Edition)" title="An Introduction to General Systems Thinking (Silver Anniversary Edition)" /></a> </div></div></p>
<p>I suppose that is now more fodder for my Kindle (and my brain): once I&#8217;ve read the two paper books, obviously.</p>
<p>So as most things are complex systems I suppose it&#8217;s likely that my reading converging on complex systems is perhaps an emergent property of one of the systems I am an element in.</p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2011/07/02/complex-systems/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>EAI and Clojure</title>
		<link>http://ivansthunks.com/blog/2010/07/04/eai-and-clojure/</link>
		<comments>http://ivansthunks.com/blog/2010/07/04/eai-and-clojure/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 04:04:26 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[EAI]]></category>
		<category><![CDATA[Polyglot]]></category>
		<category><![CDATA[clojure]]></category>
		<category><![CDATA[vancouver]]></category>
		<category><![CDATA[vandev]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2010/07/04/eai-and-clojure/</guid>
		<description><![CDATA[I had the good fortune to attend the latest VanDev meetup on EAI tools versus custom build solutions.  David Dossot gave a high-level overview of Enterprise Application Integration tools and how they compare to the ad-hoc chunks of scripting and home-grown glue that are used to integrate systems.  David covered several aspects that might affect whether you pick on [...]]]></description>
			<content:encoded><![CDATA[<p>I had the good fortune to attend the latest <a href="http://www.meetup.com/VanDev/"><font class="Apple-style-span" color="#000000">VanDev</font></a> meetup on <font class="Apple-style-span" color="#000000"><a href="http://www.meetup.com/VanDev/calendar/13621090/i/gh_event_rating_tl" class="actor" style="cursor: pointer">EAI tools versus custom build solutions</a>.  <a href="http://www.dossot.net/">David Dossot</a> gave a high-level overview of Enterprise Application Integration tools and how they compare to the ad-hoc chunks of scripting and home-grown glue that are used to integrate systems.  David covered several aspects that might affect whether you pick on or the other.  His presentation is <a href="http://prezi.com/2em9y3f2yilc/eai-when-tools-can-help/">online at Prezi</a> (which I think is a very fancy presentation system).</font><font class="Apple-style-span" color="#993300"></p>
<p>Update:</font>  David actually blogged on this too: <a href="http://blogs.mulesoft.org/presentation-eai-when-tools-can-help/">http://blogs.mulesoft.org/presentation-eai-when-tools-can-help/</a></p>
<p><font class="Apple-style-span" color="#000000">The big thing for me about this presentation was that it finally tripped a switch in my brain: <a href="http://www.eaipatterns.com/">Enterprise Application Integration patterns</a> don&#8217;t have to be about asynchronous queues and such, it&#8217;s about all the different ways systems integrate.  That includes simply copying files around, for example.  I honestly wish I&#8217;d realised this a few months ago, it would have given me the insight to stop a strange project using rails and leverage an existing EAI engine/framework.  Despite the learning curve we would now have a less custom, and more tested, system.  Better late than never?</font></p>
<p><font class="Apple-style-span" color="#000000"> </font>I&#8217;m also currently on a mild clojure kick.  Having done the <a href="http://butunclebob.com/ArticleS.UncleBob.TheBowlingGameKata">Bowling Game Kata</a> in Groovy and then followed it up with a clojure version (<a href="http://blog.8thlight.com/articles/2009/7/20/bowling-in-clojure">thanks to this link for some hints</a>) I thought I&#8217;d try to get a simple Apache Camel example up and going in clojure.  The<a href="http://codeabout.blogspot.com/2010/06/using-apache-camel-from-clojure.html"> first hit on Google</a> proved very useful for guidance.</p>
<p>Simply trying to get that (and the bowling) example up and running made me have to dig into so many different things:
<ul>
<li><a href="http://github.com/technomancy/leiningen">leiningen</a> - a clojure wrapper for maven</li>
<li><a href="http://polyglot.sonatype.org/">Polyglot Maven</a> - a wrapper for maven in several different languages so XML can be shunned</li>
<li>test-is &#8211; a simple unit testing library in clojure-contrib</li>
<li>AOT &#8211; ahead-of-time class creation, amongst other things this allows clojure to run in a binary form (no need for source in production).</li>
<li><a href="http://code.google.com/p/counterclockwise/">Counterclockwise</a> - an Eclipse plugin that adds support for clojure editing and running (with very pretty, and effective, rainbow bracketing)</li>
<li><a href="http://clojars.org/">Clojars.org</a> - a maven repo for clojure jar files</li>
<li><a href="http://nakkaya.com/clodiuno.markdown">Cloduino</a> can be used to allow clojure to interact with Arduino boards <img src='http://ivansthunks.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
<li><a href="http://www.assembla.com/wiki/show/clojure/Getting_Started">Getting started with clojure</a> - this link has a bunch of detail on getting started with clojure.</li>
<li><a href="http://github.com/relevance/labrepl">labrepl</a> - a learning environment for clojure</li>
<li>I fired up Idea for the first time in ages and install La Clojure just to try it out.</li>
</ul>
<p>Obviously, I have only scratched the surface of these things, but at least I know about them now and have a better overall handle on clojure and EAI.</p>
<p>I really do love learning new things and the VanDev meetup triggered more of this than normal.  So I encourage you all to come to VanDev or find a similar meetup near you which covers things that you really enjoy (I&#8217;ve got my eye on the <a href="http://www.meetup.com/erlang-vancouver/">local Erlang group</a> next).<font class="Apple-style-span" color="#000000">  </font></p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2010/07/04/eai-and-clojure/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>InfoQ: Nobody Needs Reliable Messaging</title>
		<link>http://ivansthunks.com/blog/2010/06/19/infoq-nobody-needs-reliable-messaging/</link>
		<comments>http://ivansthunks.com/blog/2010/06/19/infoq-nobody-needs-reliable-messaging/#comments</comments>
		<pubDate>Sat, 19 Jun 2010 20:32:23 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[Patterns]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2010/06/19/infoq-nobody-needs-reliable-messaging/</guid>
		<description><![CDATA[InfoQ is one of my favourite techy sites on the interweb.  It&#8217;s full of really great presentations, interviews and articles about many different aspects of software development.Here&#8217;s an example where Marc de Graauw writes about not needing reliable messaging.  If the business operation needs to be once-and-once-only or the operations need to be in-order then the mechanics [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.infoq.com/">InfoQ</a> is one of my favourite techy sites on the interweb.  It&#8217;s full of really great presentations, interviews and articles about many different aspects of software development.Here&#8217;s <a href="http://www.infoq.com/articles/no-reliable-messaging">an example where Marc de Graauw writes about not needing reliable messaging</a>.  If the business operation needs to be once-and-once-only or the operations need to be in-order then the mechanics should be pushed down into the business message/processing.  Don&#8217;t leave this to the transport layer, create appropriate idempotent operations and most of the problems go away.If you don&#8217;t already have InfoQ on your feed list then I can&#8217;t recommend adding it in enough</p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2010/06/19/infoq-nobody-needs-reliable-messaging/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Learning to learn</title>
		<link>http://ivansthunks.com/blog/2009/08/08/learning-to-learn/</link>
		<comments>http://ivansthunks.com/blog/2009/08/08/learning-to-learn/#comments</comments>
		<pubDate>Sat, 08 Aug 2009 17:44:34 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Books]]></category>
		<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[mindmaps]]></category>
		<category><![CDATA[sqr3]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2009/08/08/learning-to-learn/</guid>
		<description><![CDATA[I like to think that one of my strengths is my willingness to pro-actively learn new things.  Recently I have been trying to learn about learning by reading the excellent Pragmatic Thinking and Learning by Andy Hunt of The Pragmatic Programmer fame (which remains one of my favourite books of all time). A lot of [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://pragprog.com/titles/ahptl/"><img src="http://assets0.pragprog.com/images/covers/190x228/ahptl.jpg?1236205199" align="left" border="2" height="228" hspace="10" vspace="10" width="190" /></a>I like to think that one of my strengths is my willingness to pro-actively learn new things.  Recently I have been trying to learn about learning by reading the excellent <a href="http://pragprog.com/titles/ahptl/">Pragmatic Thinking and Learning</a> by Andy Hunt of <a href="http://pragprog.com/titles/tpp/">The Pragmatic Programmer</a> fame (which remains one of my favourite books of all time).</p>
<p>A lot of the content in PTL wasn&#8217;t that new to me, as I have previously read several of the books that Andy has read and references from the text.  That said, I definitely learned new things and deepened my understanding about certain areas.</p>
<p>Constant learning is definitely a incredibly valuable thing, I look for it in every potential new hire I interview.  But continually learning in the same habitual way may not be the optimal strategy.  If you apply the agile development approaches to how we learn it suggests that you should retrospect at what works, what doesn&#8217;t and that we should be prepared to try different things to see if they work better (rinse and repeat).</p>
<p>Though I&#8217;m not a novice at learning, I am a novice at learning using new tools and techniques: when was the last time you learned how to learn in a new way?  So how do I move froward from here?  According to the book, what I need is some novice/advanced beginner handrails to hold whilst I improve.  Different to the other books that I have read around this subject, PTL brings a consolidated set of next-steps in the context of the life of a software developer.</p>
<p>This is the initial list of things I am going to start:</p>
<ul>
<li>Read more deliberately using the <a href="http://en.wikipedia.org/wiki/Sqr3">SQR3 technique</a>, then blog about what I have learned.
<ul>
<li>Read PTL again, this time, read it deliberately.</li>
<li>Re-read Domain-Driven Design deliberately.</li>
</ul>
</li>
<li>Increase my blogging frequency &#8211; hopefully doing more often will make me quicker.</li>
<li>Review my blog posts once in a while &#8211; do I still agree? what have I learned since?</li>
<li>Try mindmaps again having deepened my understanding about how they might help me learn/understand.
<ul>
<li>Redraw mindmaps every now and then &#8211; let some mental mushing happen &#8211; see what my brain has subconsciously come up with.</li>
</ul>
</li>
</ul>
<p>Ever more things will come up as I continually learn and continually learn to learn.  I&#8217;m still on that journey that started the best part of 33 years ago and one that I hope doesn&#8217;t stop for a very long time yet.</p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2009/08/08/learning-to-learn/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Objective-C having read a pocket reference</title>
		<link>http://ivansthunks.com/blog/2009/08/08/objective-c-having-read-a-pocket-reference/</link>
		<comments>http://ivansthunks.com/blog/2009/08/08/objective-c-having-read-a-pocket-reference/#comments</comments>
		<pubDate>Sat, 08 Aug 2009 16:31:18 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Books]]></category>
		<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[objective-c]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2009/08/08/objective-c-having-read-a-pocket-reference/</guid>
		<description><![CDATA[On the way back from a long-weekend on Vancouver Island we had a little time to kill whilst waiting for our ferry home.  There was a Chapters store nearby, so that was an easy mascre of half and hour.  After browsing for a while and noting possible future purchases I purchased Objective-C Pocket Reference.  At 122 [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://amzn.com/0596004230" target="_blank"><img src="http://img.amazon.ca/images/I/51FBKoZAzoL._BO2,204,203,200_PIsitb-sticker-arrow-click,TopRight,35,-76_AA240_SH20_OU15_.jpg" align="left" border="0" height="240" vspace="15" width="240" /></a>On the way back from a long-weekend on Vancouver Island we had a little time to kill whilst waiting for our ferry home.  There was a Chapters store nearby, so that was an easy mascre of half and hour.  After browsing for a while and noting possible future purchases I purchased <a href="http://amzn.com/0596004230">Objective-C Pocket Reference</a>.  At 122 small pages it was a quick read and covered he basics of Objective-C&#8217;s syntax and detailed various fundamental aspects of the <a href="http://developer.apple.com/cocoa/">Cocoa</a> and <a href="http://www.gnustep.org/">GNUStep</a> and the various differences betwen them.</p>
<p>I got from it pretty much what I was hoping: an easily digestible introduction into Objective-C.  I had previously read a bunch on the web, but I always find reading books, rather than reading a screen, to be far more effective for myself.  I had many different questions answered from an attempted iPhone coding session a few months ago.</p>
<p>I have been nudging some of the guys at work to start an Objective-C/iPhone/Mac programming study group. This book will be very useful for the novices in the group (myself included) to quickly look up the fundamentals and work through the syntax impedance as they try and push a new language into their Java brains &#8211; this was definitely a sticking point with the Erlang study group we had for a while.</p>
<p>In summary, a great, concise reference &#8211; just like the title suggests.  It appears that the reviewers on Amazon also agree.</p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2009/08/08/objective-c-having-read-a-pocket-reference/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adding an auxiliary enchancer to OpenJPA</title>
		<link>http://ivansthunks.com/blog/2008/12/02/adding-an-auxiliary-enchancer-to-openjpa/</link>
		<comments>http://ivansthunks.com/blog/2008/12/02/adding-an-auxiliary-enchancer-to-openjpa/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 06:28:38 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[]]></category>
		<category><![CDATA[AuxiliaryEnhancer]]></category>
		<category><![CDATA[Enhancer]]></category>
		<category><![CDATA[OpenJpa]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2008/12/02/adding-an-auxiliary-enchancer-to-openjpa/</guid>
		<description><![CDATA[A while back I attempted to create a visualization of the relations that OpenJPA creates between the Java classes that it enhances &#8211; the intent was to help better understand a particularly intertwined persistent object graph and see if I couldn&#8217;t figure out why we were getting a few strange problems. The initial approach I [...]]]></description>
			<content:encoded><![CDATA[<p>A while back I attempted to create a visualization of the relations that OpenJPA creates between the Java classes that it enhances &#8211; the intent was to help better understand a particularly intertwined persistent object graph and see if I couldn&#8217;t figure out why we were getting a few strange problems.</p>
<p>The initial approach I took was a hilarious trip into the land of sed, perl and graphviz.  It kinda looked like it worked, but didn&#8217;t actually <img src='http://ivansthunks.com/blog/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
<p>Time passed&#8230;&#8230;more time passed&#8230;&#8230;I learned more&#8230;&#8230;more time passed&#8230;&#8230;.and then I had the wacky notion of tying directly into the Enhancer that OpenJPA uses to create the persistence enabled classes.  I haven&#8217;t done the visualization yet, but this is what I learned about actually tying in an AuxiliaryEnhancer.</p>
<h2>1. Create the AuxiliaryEnhancer</h2>
<p>The following code is the minimal you will need.  Enter this and then compile &#8211; you will need OpenJPA and serp on your classpath.</p>
<pre>
<pre class="brush: java; title: ; notranslate">package com.ij;

import org.apache.openjpa.enhance.PCEnhancer.AuxiliaryEnhancer;
import serp.bytecode.BCClass;
import serp.bytecode.BCMethod;
import org.apache.openjpa.meta.ClassMetaData;

public class Grapher implements AuxiliaryEnhancer {

    public void run(BCClass bc, ClassMetaData meta) {
        System.out.println(&quot;Running Enhancement&quot;);
    }

    public boolean skipEnhance(BCMethod m) {
         System.out.println(&quot;skipEnhance?&quot;);
         return false;
    }
}
</pre>
</pre>
<h2>2. Register the enhancer using jar based services</h2>
<p>This is something I was only barely aware off &#8211; registering concrete implementations of services through jar file meta-data.</p>
<ul>
<li>Create a file in a <strong>META-INF/services</strong>/ directory called <strong>org.apache.openjpa.enhance.PCEnhancer$AuxiliaryEnhancer</strong>
<ul>
<li>Note the dollar sign! That one caught me out for a while: I couldn&#8217;t decide whether the dot notation or the dollar notation should be used to reference the nested class.</li>
</ul>
</li>
<li>This file should simply contain the fully qualified name of the Enhancer you wrote: com.ij.Grapher</li>
<li>Jar this directory and the class file up and you should end up with a jar listing like this</li>
</ul>
<pre>
<pre class="brush: java; title: ; notranslate">
ivan-jensens-computer:jar ivanjensen$ jar tvf ../grapher.jar
     0 Tue Dec 02 21:56:42 PST 2008 META-INF/
    60 Tue Dec 02 21:56:42 PST 2008 META-INF/MANIFEST.MF
     0 Tue Dec 02 21:54:28 PST 2008 META-INF/services/
    16 Tue Dec 02 21:30:44 PST 2008 META-INF/services/org.apache.renamed.openjpa.enhance.PCEnhancer$AuxiliaryEnhancer
     0 Tue Dec 02 21:55:16 PST 2008 com/
     0 Tue Dec 02 21:55:38 PST 2008 com/ij/
   771 Tue Dec 02 21:55:38 PST 2008 com/ij/Grapher.class
   465 Tue Dec 02 21:54:46 PST 2008 com/ij/Grapher.java
</pre>
</pre>
<h2>3. Add the new jar file to the enhancer classpath</h2>
<p>I did this by adding my jar file to the classpath element of my ant script &#8211; pretty simple.</p>
<h2>4. Re-enhance your classes</h2>
<p>Re-enhance your classes and you will see the System.out.println statements all over your console.</p>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] Running Enhancement</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<pre> [openjpac] skipEnhance?</pre>
<p>One thing I noticed about this: I had to delete my persistent classes and re-enhance, only then would the &#8216;run&#8217; method be called.  The skipMethod is called whether I delete the classes or not.  I don&#8217;t know what that means yet, but I&#8217;m sure I am about to find out.</p>
<h2>Notes:</h2>
<p>I was actually using a patched version of OpenJpa 1.0.1 (for various, non-amusing, reasons), but the patches shouldn&#8217;t affect this tutorial.</p>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2008/12/02/adding-an-auxiliary-enchancer-to-openjpa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Geeky Learning-casts</title>
		<link>http://ivansthunks.com/blog/2008/09/28/geeky-learning-casts/</link>
		<comments>http://ivansthunks.com/blog/2008/09/28/geeky-learning-casts/#comments</comments>
		<pubDate>Mon, 29 Sep 2008 03:05:30 +0000</pubDate>
		<dc:creator>ivan</dc:creator>
				<category><![CDATA[Big Architectures]]></category>
		<category><![CDATA[Constant Learning]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[architecture]]></category>
		<category><![CDATA[batch processing]]></category>
		<category><![CDATA[learning]]></category>
		<category><![CDATA[podcast]]></category>
		<category><![CDATA[project failure]]></category>
		<category><![CDATA[Scrum]]></category>
		<category><![CDATA[short iterations]]></category>
		<category><![CDATA[videocast]]></category>

		<guid isPermaLink="false">http://ivansthunks.com/blog/2008/09/28/geeky-learning-casts/</guid>
		<description><![CDATA[I&#8217;m constantly reading, watching or listening to stuff that makes me learn an I recently found the following very useful and timely for the work I&#8217;m doing at the moment (or in the near future). Dave Syer from Spring Source talking about Spring Batch &#8211; extracting the essential elements of batch processing Spring style.  If [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m constantly reading, watching or listening to stuff that makes me learn an I recently found the following very useful and timely for the work I&#8217;m doing at the moment (or in the near future).</p>
<ul>
<li>Dave Syer from Spring Source talking about Spring Batch &#8211; extracting the essential elements of batch processing Spring style.  If you have to write batch jobs in Java you could do a lot worse than use Spring Batch as a base.<br />
<a href="http://www.infoq.com/presentations/syer-introducing-spring-batch">http://www.infoq.com/presentations/syer-introducing-spring-batch</a></li>
<li>Mishkin Berteig on how using (incredibly short) 2 day Scrum iterations acted as a catalyst to make a business become more collaborative and better prioritise the work for their (rather small) IT department.  Eventually determining that the IT department shouldn&#8217;t have been working on any projects other than one that would make the company more money than the rest of the projects put together!<br />
<a href="http://www.infoq.com/presentations/Short-Iterations-Mishkin-Berteig">http://www.infoq.com/presentations/Short-Iterations-Mishkin-Berteig  </a></li>
<li>A friend of mine sent me a link to a very interesting talk by Mitch Lacey about how a Scrum project he was leading went very wrong &#8211; what happens when the business just doesn&#8217;t &#8216;get&#8217; agile development.<a href="http://www.infoq.com/presentations/A-Story-of-Project-Failure-Mitch-Lacey">
<p>http://www.infoq.com/presentations/A-Story-of-Project-Failure-Mitch-Lacey</a></li>
<li>Randy Shoup on the architecture of eBay &#8211; learn that data consistency doesn&#8217;t have to be 100% but you have to trade-off with availability and data partitioning &#8211; extremely illuminating.<br />
<a href="http://www.se-radio.net/podcast/2008-09/episode-109-ebay039s-architecture-principles-randy-shoup">http://www.se-radio.net/podcast/2008-09/episode-109-ebay039s-architecture-principles-randy-shoup</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://ivansthunks.com/blog/2008/09/28/geeky-learning-casts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

