<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss 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" version="2.0">

<channel>
	<title>MyArch</title>
	
	<link>http://myarch.com</link>
	<description>Builds and bytes</description>
	<pubDate>Tue, 09 Dec 2008 01:52:36 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.1</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/myarch" type="application/rss+xml" /><item>
		<title>Building Windows NT</title>
		<link>http://myarch.com/building-nt</link>
		<comments>http://myarch.com/building-nt#comments</comments>
		<pubDate>Tue, 09 Dec 2008 01:52:36 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/?p=118</guid>
		<description><![CDATA[	I&#8217;ve been reading a relatively old but nevertheless fascinating book called Showstopper about development of Windows NT. I was struck by the author&#8217;s account of NT&#8217;s build process, specifically its low degree of automation.

	NT was obviously a high-intensity, almost a death march kind of project and so the builds had to be churned out at [...]]]></description>
			<content:encoded><![CDATA[	<p>I&#8217;ve been reading a relatively old but nevertheless fascinating book called <a href="http://www.amazon.com/Show-Stopper-Breakneck-Generation-Microsoft/dp/0029356717/ref=sr_1_9?ie=UTF8&#038;s=books&#038;qid=1228778060&#038;sr=8-9" title="">Showstopper</a> about development of Windows NT. I was struck by the author&#8217;s account of NT&#8217;s build process, specifically its low degree of automation.</p>

	<p>NT was obviously a high-intensity, almost a death march kind of project and so the builds had to be churned out at a quick pace:<br />
<blockquote><br />
...the number of builds grew from a couple to a half dozen  some week&#8230;<br />
</blockquote></p>

	<p>This may not sound like much, but since NT was getting quite big and complex, it kept the guys in the build lab busy. The builds were so critical that at some point the technical lead of the project, <a href= "http://en.wikipedia.org/wiki/Dave_Cutler_(software_engineer)">Dave Cutler</a>, had to take over the build lab. This, however, did not improve the way builds were done. One of the members of the build team remembers:<br />
<blockquote><br />
He is not giving us the list, he&#8217;s basically saying, &#8216;Go to this directory and sync this file.&#8217; He&#8217;s saying,  &#8216;Pick up this file, do this, do that&#8217;.<br />
</blockquote><br />
The release process was pretty haphazard too according to another team member:<br />
<blockquote><br />
We have all these cowboy developers, just slinging code like crazy, calling out: &#8220;We need another build!&#8221;<br />
</blockquote><br />
And, of course, continuous integration was not invented yet:<br />
<blockquote><br />
We&#8217;d think we were all done for the day, then test the build and it wouldn&#8217;t boot. We&#8217;d run around looking for the programmer whose code broke it.<br />
</blockquote></p>

	<p>I don&#8217;t think this situation was unique to Microsoft back then. But I also think that the attitude toward CM and development process automation has changed over the last 16 years. Today, automated builds is pretty much the norm for all but the smallest projects. Continuous integration and automated testing is becoming widespread. There is a dizzying array of build systems, <a href="/yet-another-build-server" title="">build servers</a>, version control systems and other CM and development tools.</p>

	<p>There is a long way to go however. Implementing solid build/deployment and release management automation is still hard. Most large projects end up having to dedicate multiple highly skilled people to solving this problem. Home-grown script-based automation is still pretty much the state of the art. This is going to change. The tools will become more intelligent and advanced. I hope it won&#8217;t take another 16 years.</p>





 ]]></content:encoded>
			<wfw:commentRss>http://myarch.com/building-nt/feed</wfw:commentRss>
		</item>
		<item>
		<title>XML Alternatives and YAML</title>
		<link>http://myarch.com/xml-alternatives-and-yaml</link>
		<comments>http://myarch.com/xml-alternatives-and-yaml#comments</comments>
		<pubDate>Thu, 20 Nov 2008 03:31:58 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<category><![CDATA[Operations]]></category>

		<guid isPermaLink="false">http://myarch.com/?p=104</guid>
		<description><![CDATA[	The need for a more human-friendly alternative to XML is apparent to many people, myself included. This is the reason why quite a few different light-weight markup languages have been created over the last several years. I guess they are called &#8220;lightweight&#8221; because they don&#8217;t use XML-like tags that tend to clutter documents. I&#8217;ve looked [...]]]></description>
			<content:encoded><![CDATA[	<p>The need for a more human-friendly alternative to <span class="caps">XML</span> is apparent to many people, myself included. This is the reason why quite a few different <a href="http://en.wikipedia.org/wiki/List_of_lightweight_markup_languages" title="">light-weight markup languages</a> have been created over the last several years. I guess they are called &#8220;lightweight&#8221; because they don&#8217;t use <span class="caps">XML</span>-like tags that tend to clutter documents. I&#8217;ve looked at several of them and found <a href="http://yaml.org" title=""><span class="caps">YAML</span></a> to be the most mature out of the bunch as well as quite human-readable (as opposed to, say, <span class="caps">JSON</span>) and easy to understand. You can find some very good side-by-side <span class="caps">XML</span> vs. <span class="caps">YAML</span> comparison <a href="http://yaml.kwiki.org/index.cgi?YamlExamples" title="">here</a> or <a href="http://www.ibm.com/developerworks/xml/library/x-matters23.html" title="">here</a>, the difference in readability is stunning.</p>

	<p>From what I understand, <span class="caps">YAML</span> is popular in the Ruby world and it is used for various <a href="http://www.symfony-project.org/book/1_0/08-Inside-the-Model-Layer" title=""><span class="caps">PHP</span> projects</a>.  However, it is almost unknown in Java/J2EE circles. Which is a shame. While annotations somewhat limited the spread of &#8220;XML hell&#8221; in Java applications, <span class="caps">XML</span> still remains a de-facto file configuration format. I would venture to say that except for few outliers, <span class="caps">YAML</span> would be a better option as a format for configuration files. Why is it the case? One reason is that <span class="caps">YAML</span> format simplifies application support. Developers often say that they don&#8217;t care about readability of <span class="caps">XML</span> since they use <span class="caps">IDE</span> or editors that hide the complexity of <span class="caps">XML</span>. Indeed, being able to work with <span class="caps">XML</span> in a nice tree view-based editor is appealing. But this does not work when application configuration needs to be quickly analyzed and potentially updated on some remote machine that most likely only has VI or notepad (which is usually the case in production environments, which I find very ironic &#8211; shouldn&#8217;t the production machine have the most advanced editors and analysis tools to make troubleshooting as efficient as possible?) in response to some production problem.  For configuration files, readability and ease of understanding is the key.</p>

	<p>Of course, there is also an old trusty property/name-value format. It is, however, very limited, since it does not support any kind of nesting or scoping. So all properties become essentially global and haven&#8217;t we learned already that global variables is not a good thing?</p>

	<p><span class="caps">YAML</span>, on the other hand, allows for expressing arbitrary complex models. Anything that can be expressed in <span class="caps">XML</span> can also be expressed using <span class="caps">YAML</span>.</p>

	<p>On the downside, <span class="caps">YAML</span> does not have a very broad ecosystem. There are not that many <a href="http://www.digitalhobbit.com/archives/2005/09/15/yaml-editor-support/" title="">editors that support <span class="caps">YAML</span></a>. There is a <a href="http://code.google.com/p/yamleditor/" title=""><span class="caps">YAML </span>Eclipse plugin</a>, but in only gives color highlighting, no validation (here is <a href="http://noy.cc/symfoclipse/download.html" title="">another plugin</a> which I have not tried yet). There is no metadata support, at least for Java, although there is a <a href="http://www.kuwata-lab.com/kwalify/" title="">schema validator</a> for Ruby (its Java port seems to be dead). There is also no <span class="caps">XSLT</span> equivalent.</p>

	<p>There are two <span class="caps">YAML</span> parsers for Java &#8211; <a href="https://jvyaml.dev.java.net/" title="">jvyaml</a>  and <a href="http://jyaml.sourceforge.net/index.html" title="">JYaml</a>. They kinda work, but there is certainly room for improvement in terms of error messages and just the ability to detect and reject an incorrect document. Since <span class="caps">YAML</span> is supposed to be a language with minimal learning curve, the parsing has to be intuitive and bulletproof.</p>

	<p>I still think that despite the shortcomings <span class="caps">YAML</span> is the way to go. Perhaps I will give a closer look to one of these parsers and see if I can tweak it a bit.</p>

 ]]></content:encoded>
			<wfw:commentRss>http://myarch.com/xml-alternatives-and-yaml/feed</wfw:commentRss>
		</item>
		<item>
		<title>Why are Environments So Poorly Supported?</title>
		<link>http://myarch.com/why-environments-are-so-poorly-supported</link>
		<comments>http://myarch.com/why-environments-are-so-poorly-supported#comments</comments>
		<pubDate>Thu, 13 Nov 2008 05:04:38 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/?p=99</guid>
		<description><![CDATA[	A concept of &#8220;environment&#8221; permeates software development lifecycle. No application is released into production directly from developers PCs. There has to be a place where an application can go through various stages of testing. We use different environments for that purpose, e.g., &#8220;QA environment&#8221; or &#8220;acceptance environment&#8221;.

	An &#8220;environment&#8221; is just a collection of resources which [...]]]></description>
			<content:encoded><![CDATA[	<p>A concept of &#8220;environment&#8221; permeates software development lifecycle. No application is released into production directly from developers PCs. There has to be a place where an application can go through various stages of testing. We use different environments for that purpose, e.g., &#8220;QA environment&#8221; or &#8220;acceptance environment&#8221;.</p>

	<p>An &#8220;environment&#8221; is just a collection of resources which could include middleware and OS/filesystem resources. In the simplest case, an environment for a <span class="caps">J2EE</span> web application consists of a single application server. Complex applications consisting of multiple components could utilize many different resources, including several different middleware products (e.g., app server, Web server, messaging infrastructure, <span class="caps">ESB</span>).</p>

	<p>For any IT organization it is important to know how their resources are used. <span class="caps">ITIL</span> has a concept of <a href="http://en.wikipedia.org/wiki/CMDB" title=""><span class="caps">CMDB</span></a> that&#8217;s supposed to contain all IT resources. However, the granularity of <span class="caps">CMDB</span> implementations is usually too high (typically, a server  level) which makes it difficult to use for software development. Also, <span class="caps">CMDB</span> is not really integrated with development processes and tools, it&#8217;s kind of a thing on its own.</p>

	<p>Ideally, the environment concept must be supported by development, version control, change management and build/deploy tools. Environment metadata can be used to automatically install an application in a given environment. Testing tools can use this metadata to generate &#8220;smog&#8221; tests or to adjust existing test cases (e.g., by using different URLs/endpoints). There should be a capability to produce various reports showing what version of what application is installed in what environment.</p>

	<p>Sadly, all these wonderful features are mostly missing from modern development and CM tools. Developers rely on scripting and informal use of environment variables. Essentially, today, each application has its own &#8220;selfish&#8221; view of what an environment is. This makes providing consistent operations and support difficult. This is especially true in virtualized environments where each logical environment may consist of many different VMs.</p>

	<p>Case in point are build servers and build tools. I looked at several build servers and found explicit environment support only in <a href="http://www.anthillpro.com/html/products/anthillpro/default.html" title="">AntHill</a>.  All the others I looked at (several, I won&#8217;t name them) omit the environment concept completely (except for some lame support of environment variables). To me, this is really odd. While build servers have their root in continues integration, their key selling point in an enterprise is actually release management (at lease for commercial products; there are many great open source build servers to choose from if continuous integration is the only goal). So how can a release process be automated if the foundation of this process is missing entirely from the tool that&#8217;s supposed to help with the automation?</p>

	<p>Build tools are the same way. There is some deployment support in both Maven (<a href="http://cargo.codehaus.org/Maven2+plugin" title="">Cargo plugin</a>) and Ant, but no way of supporting environment as an entity.</p>


 ]]></content:encoded>
			<wfw:commentRss>http://myarch.com/why-environments-are-so-poorly-supported/feed</wfw:commentRss>
		</item>
		<item>
		<title>Will Recession Provide a Boost to SOA?</title>
		<link>http://myarch.com/will-recession-provide-a-boost-to-soa</link>
		<comments>http://myarch.com/will-recession-provide-a-boost-to-soa#comments</comments>
		<pubDate>Mon, 20 Oct 2008 03:24:31 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[SOA]]></category>

		<guid isPermaLink="false">http://myarch.com/?p=94</guid>
		<description><![CDATA[	There is no doubt that IT budgets will be cut next year. The size of the cut is hard to predict, but I think that it could exceed the Gartner&#8217;s forecast.

	This, however, could finally give a shot in the arm to the long stagnated SOA projects. What makes me say that? Well, as I&#8217;ve been [...]]]></description>
			<content:encoded><![CDATA[	<p>There is no doubt that IT budgets <a href="http://blogs.zdnet.com/BTL/?p=10403" title="">will be cut next year</a>. The size of the cut is hard to predict, but I think that it could exceed the Gartner&#8217;s forecast.</p>

	<p>This, however, could finally give a shot in the arm to the long stagnated <span class="caps">SOA</span> projects. What makes me say that? Well, as I&#8217;ve been <a href="/soa-need-not-be-costly" title="">advocating all along</a>, <span class="caps">SOA</span> represents an inexpensive way of adding flexibility and achieving new goals. <span class="caps">SOA</span> does not have to require significant new investments. Done smartly, it could be a great way of implementing new functionality without ripping the existing systems apart, which is undoubtedly won&#8217;t fly in light of highly constrained budgets.</p>

	<p>To prove this point, in spite of lackluster economy, <a href="http://blogs.zdnet.com/service-oriented/?p=1179" title="">the demand  for <span class="caps">SOA</span> architects has been booming</a>.</p>

	<p>There is one caveat to this view &#8211; organizations need to stop approaching <span class="caps">SOA</span> from the infrastructure standpoint (i.e., what <span class="caps">ESB</span> product do I need?) and start using it as a solution to real business needs. I&#8217;m not entirely sure that it&#8217;s going to happen, but bad economy could be just the motivation for that.</p>




 ]]></content:encoded>
			<wfw:commentRss>http://myarch.com/will-recession-provide-a-boost-to-soa/feed</wfw:commentRss>
		</item>
		<item>
		<title>Updated Jython Ant Task</title>
		<link>http://myarch.com/updated-jython-ant-task</link>
		<comments>http://myarch.com/updated-jython-ant-task#comments</comments>
		<pubDate>Sun, 12 Oct 2008 04:49:23 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Ant]]></category>

		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/?p=92</guid>
		<description><![CDATA[	I&#8217;ve updated Ant Jython task with a number of new features:

	
		Jython path is now handled by a separate JythonPath task.
	

	
		Jython interpreter is now scoped to Ant project. This means that you can have multiple Jython calls withing the same project that share common imports and variables.
	

	
		Jython task now supports nested text, similar to the &#8220;script&#8221; [...]]]></description>
			<content:encoded><![CDATA[	<p>I&#8217;ve updated <a href="/ant-jython-task">Ant Jython task</a> with a number of new features:</p>

	<ul>
		<li>Jython path is now handled by a separate JythonPath task.</li>
	</ul>

	<ul>
		<li>Jython interpreter is now scoped to Ant project. This means that you can have multiple Jython calls withing the same project that share common imports and variables.</li>
	</ul>

	<ul>
		<li>Jython task now supports nested text, similar to the &#8220;script&#8221; task.</li>
	</ul>
 ]]></content:encoded>
			<wfw:commentRss>http://myarch.com/updated-jython-ant-task/feed</wfw:commentRss>
		</item>
		<item>
		<title>Ant Jython Task</title>
		<link>http://myarch.com/ant-jython-task</link>
		<comments>http://myarch.com/ant-jython-task#comments</comments>
		<pubDate>Thu, 21 Aug 2008 02:57:51 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Ant]]></category>

		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/ant-jython-task</guid>
		<description><![CDATA[MyArch Jython task has a number of advantages over built-in &#60;script language="jython"&#62; 
way of invoking Jython from Ant.  

Specifically, the task provides the following benefits:



More graceful exception handling. Jython code invoked using "script" could generate long error stack that includes the Java stack trace of the "script" task. This is especially painful if you [...]]]></description>
			<content:encoded><![CDATA[<p>MyArch Jython task has a number of advantages over built-in &lt;script language="jython"&gt; <br />
way of invoking Jython from Ant.  </p>

<p>Specifically, the task provides the following benefits:</p>


<ul>
<li>More graceful exception handling. Jython code invoked using "script" could generate long error stack that includes the Java stack trace of the "script" task. This is especially painful if you invoke other Ant tasks from Jython (you can do it using MyArch <a href="/jython-ant-wrapper-examples">PAnt</a> utility) that add their own Java stack trace. MyArch Jython task produces a brief readable error stack. I personally think that unwieldy error traces is a <a href="/secret-weapon-of-lamp-applications">big issue</a> in the industry and it's far from innocuous. </li>
</ul>




<ul>
<li>You can use Ant properties as parameters (the task makes them available in the local namespace of the calling script).</li>
</ul>




<ul>
<li>Ant "project" object is passed in the global variable "antProject" (available from the built-in namespace). In other words, "antProject" is available to all modules/functions invoked using "jython". </li>
</ul>




<ul>
<li>Convenience "import" attribute. </li>
</ul>




<ul>
<li>There is also a JythonPath task for easily setting jython path from Ant path. </li>
</ul>




<ul>
<li>Jython interpreter is initialized once per Ant project. All scripts invoked from the same Ant project reuse the same built-in namespace. So you can define variables and imports in one call and use them in a subsequent call. </li>
</ul>




<ul>
<li>Task name ( the name that prefixes all console output from Ant for a given task) is generated automatically based on the supplied Python code.</li>
</ul>



<p>Example:</p>

<p>Ant code:</p>


<pre>
<code>
&lt;jythonPath pythonPathRef=&quot;python.path&quot; /&gt;
&lt;property name=&quot;testProp&quot; value=&quot;testVal&quot; /&gt;

&lt;jython&gt;
print &quot;Property from ant:&quot;, testProp
# define a var that we can use in other scripts
s=&quot;test&quot;
&lt;/jython&gt;

&lt;jython&gt;
print &quot;Var created earlier: &quot;,s
&lt;/jython&gt;

&lt;jython  import=&quot;from testmodule import *&quot; exec=&quot;test(testProp)&quot;  /&gt;
</code>
</pre>



<p>"testmodule" python code:</p>


<pre>
<code>
def test (prop):
    print &quot;Passed parameter: &quot;,prop
    print &quot;Test property: &quot;,antProject.properties[&quot;testProp&quot;]
</code>
</pre>



<p>Jython task attributes:</p>


<ul>
<li>exec - python code to execute. This has to be a single line, e.g., <code>mod.fun()</code> although you could combine multiple statements separated by ";".</li>
<li>import - a convenience attribute for providing "import" statement. Its only purpose is to make the task invocation more readable. Alternatively, you can have "import" as part of the"exec",e.g., <code>exec=&quot;import mod;mod.fun()&quot;</code>.</li>
<li>execfile - execute a python script. This has to be an absolute path to a python file.</li>
</ul>




<p>JythonPath task attributes:</p>


<ul>
<li>pythonPath - python.path to use.</li>
</ul>




<ul>
<li>pythonPathRef - the python.path to use, given as reference to a <span class="caps">PATH </span>defined elsewhere.</li>
</ul>





<p>Jython task is part of myarch-antutil project. <a href="/download/id/2/myarch-antutil-0.5.zip">Download jython task</a>.</p>

<p>You may also be interested in <a href="/jython-ant-wrapper-examples">PAnt - Ant python wrapper</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://myarch.com/ant-jython-task/feed</wfw:commentRss>
		</item>
		<item>
		<title>WebSphere 7 Supports Properties-Based Configuration</title>
		<link>http://myarch.com/websphere-7-supports-properties-based-configuration</link>
		<comments>http://myarch.com/websphere-7-supports-properties-based-configuration#comments</comments>
		<pubDate>Thu, 21 Aug 2008 01:52:55 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[WebSphere]]></category>

		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://myarch.com/websphere-7-supports-properties-based-configuration</guid>
		<description><![CDATA[IBM WebSphere 7 (currently in beta) comes a property-file based configuration tool that provides a "human-consumable" interface to the currently XML-based configuration repository of the application server. This is another proof that XML is simply not the right mechanism for managing configuration of complex software products. 
From the release notes:

Properties (name/value pairs) files are more [...]]]></description>
			<content:encoded><![CDATA[<p>IBM <a href="https://www14.software.ibm.com/iwm/web/cc/earlyprograms/websphere/wasndv7/">WebSphere 7</a> (currently in beta) comes a property-file based configuration tool that provides a "human-consumable" interface to the currently XML-based configuration repository of the application server. This is another proof that XML is simply not the right mechanism for managing configuration of complex software products. </p>
<p>From the release notes:<br />
<BLOCKQUOTE><br />
Properties (name/value pairs) files are more consumable for human administrators than a mix of XML and other formats spread across multiple configuration directories.<br />
</BLOCKQUOTE></p>
<p>Kudos to IBM for recognizing that. </p>
<p>It is still not clear though how hierarchical relationships between configuration objects will be supported. </p>
<p>Back in WAS 6 world, I've been using a simple jython script that converts python named parameters into wsadmin format. This is an example of a resource described in this format:</p>
<pre>
<code>
 WASConfig.DataSource(parent="testJDBCProvider", name="testDS", jndiName="jdbc/testDS",
                              description="Test DataSource", propertySet=dict(
                              resourceProperties=[
                                  dict(name="dbName", value="testDB", type="java.lang.String" ),
                                  dict(name="connectionAttribute",value="", type="java.lang.String")
                               ]))

</code>
</pre>
<p>I think that a slightly more streamlined python-based format will be superior to properties.</p>
]]></content:encoded>
			<wfw:commentRss>http://myarch.com/websphere-7-supports-properties-based-configuration/feed</wfw:commentRss>
		</item>
		<item>
		<title>Jython in WebSphere Portal</title>
		<link>http://myarch.com/jython-in-websphere-portal</link>
		<comments>http://myarch.com/jython-in-websphere-portal#comments</comments>
		<pubDate>Mon, 11 Aug 2008 00:07:42 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<category><![CDATA[WebSphere]]></category>

		<guid isPermaLink="false">http://myarch.com/jython-in-websphere-portal</guid>
		<description><![CDATA[Most developers and administrators working with WebSphere Application Server (WAS) know that both JACL and  Jython languages can be used for various WAS administration and configuration tasks. However, JACL has always been a preferred choice, simply because this is the default language used by the product's admin tool (wsadmin) and also because JACL examples [...]]]></description>
			<content:encoded><![CDATA[<p>Most developers and administrators working with WebSphere Application Server (WAS) know that both <a href="http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/cxml_jacl.html">JACL</a> and  Jython languages can be used for various WAS administration and configuration tasks. However, JACL has always been a preferred choice, simply because this is the default language used by the product's admin tool (wsadmin) and also because JACL examples and documentation are more complete. </p>

<p>Using JACL might have been a valid option just a few years back (when WAS just came out) given the uncertainty surrounding the Jython project. Today, however, jython is clearly alive and well; an alpha version supporting Python 2.5 was announced recently. Therefore there is really no point in using JACL any longer, except may be for shops with a large collection of existing JACL scripts. JACL syntax is quite arcane compared with Python and the language is clearly not as widely used. </p>

<p>IBM confirmed this view by releasing <a href="http://www-1.ibm.com/support/docview.wss?rs=180&#038;uid=swg24012144">JACL to Jython</a> converter a couple years back.</p>

<p>Unfortunately, up until recently, jython was not officially supported in another IBM product, <a href="http://www-306.ibm.com/software/websphere/portal/">WebSphere Portal</a>, which comes with wpsript tool for managing pages, deployable modules and other portal artifacts. </p>

<p>But since portal scripting relies on wsadmin's shell, jython is in fact fully supported by the product, it's just not documented. 
All that you need to do to switch to jython is to invoke wsadmin with "-lang jython" and "-wsadmin_classpath " followed by the list of portal jars (you can copy the classpath from SCRPATH variable definition in wpscript.sh).</p>

<p>As an example, I put together a simple <a href="/files/portal/portaladmin.py">Jython script for cleaning up a page hierarchy</a>. Removing pages before applying an XMLAccess script with page definitions allows to start portal configuration from a clean "known" state. Very often, especially in a development environment, an application's page hierarchy gets polluted with various "test" pages created by developers. The script gets rid of them.</p>

<p>In WebSphere Portal 6.1 Jython is finally made a first-class citizen. The product's documentation <a href="http://publib.boulder.ibm.com/infocenter/wpexpdoc/v6r1m0/index.jsp?topic=/com.ibm.wp.exp.doc/admin/adpsiabt.html">proclaims</a> that JACL support will be phased out and that jython is the way to go. Surprisingly, though, all examples still use good old JACL. I assume it's just a matter of time before they convert. </p>
]]></content:encoded>
			<wfw:commentRss>http://myarch.com/jython-in-websphere-portal/feed</wfw:commentRss>
		</item>
		<item>
		<title>Yet Another Build Server</title>
		<link>http://myarch.com/yet-another-build-server</link>
		<comments>http://myarch.com/yet-another-build-server#comments</comments>
		<pubDate>Thu, 31 Jul 2008 04:24:34 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/yet-another-build-server</guid>
		<description><![CDATA[Thoughtworks has finally release a successor for their venerable Cruise Control - Cruise build server. The UI certainly looks nice and it seems quite flexible. There is even a free version (which is limited to two computers), which is great.

What is not clear though is how this product is different from AntHill, Buildforge, Bamboo, TeamCity, [...]]]></description>
			<content:encoded><![CDATA[<p>Thoughtworks has finally release a successor for their venerable Cruise Control - <a href="http://studios.thoughtworks.com/cruise-continuous-integration/cruise-pricing-and-license">Cruise build server</a>. The UI certainly looks nice and it seems quite flexible. There is even a free version (which is limited to two computers), which is great.</p>

<p>What is not clear though is how this product is different from <a href="http://www.anthillpro.com/html/products/anthillpro/default.html">AntHill</a>, <a href="http://www.anthillpro.com/html/products/anthillpro/default.html">Buildforge</a>, <a href="http://www.atlassian.com/software/bamboo/">Bamboo</a>, <a href="http://www.jetbrains.com/teamcity/">TeamCity</a>, <a href="http://www.borland.com/us/products/silk/gauntlet/index.html">Gauntlet</a> and the likes. The field is certainly becoming crowded - and I haven't even mentioned numerous open-source contenders.  All these products seem to be doing the same thing - organizing your build scripts, interfacing with version control, running builds on a distributed "build server farm", collecting statistics, publishing reports and providing UI for all these functions.</p>

<p>All these features are important and useful. Ironically, however, what build servers don't do is automatically building or deploying your software. You still have to write Ant or Maven scripts, define and manage configuration parameters (using properties, XML, environment variables), deal with different environments (if I'm not mistaken, AntHill is the only product that has an explicit concept of an environment). For a complex project this could be a lot of work. Granted, every project is somewhat unique (if not, just use the default Maven configuration and you're done), so this could be a tough nut to crack. It should however be possible for a build server to have enough intelligence to infer how to build a project directly from the code base. </p>
]]></content:encoded>
			<wfw:commentRss>http://myarch.com/yet-another-build-server/feed</wfw:commentRss>
		</item>
		<item>
		<title>Going beyond Builds with Build Servers</title>
		<link>http://myarch.com/going-beyond-builds-with-build-servers</link>
		<comments>http://myarch.com/going-beyond-builds-with-build-servers#comments</comments>
		<pubDate>Sun, 27 Jul 2008 23:24:29 +0000</pubDate>
		<dc:creator>Alexander Ananiev</dc:creator>
		
		<category><![CDATA[Building software]]></category>

		<guid isPermaLink="false">http://myarch.com/going-beyond-builds-with-build-servers</guid>
		<description><![CDATA[A build server provides great benefits to a development team, including:


Convenient way of sharing build results and artifacts.
Ability to run builds without having to mess with command line parameters.
Tight integration with version control.
History and statistics.
Accountability and audit (e.g., who ran what build).


In most instances build servers, such as Hudson, Continuum or LuntBuild are used mostly [...]]]></description>
			<content:encoded><![CDATA[<p>A build server provides great benefits to a development team, including:</p>

<ul>
<li>Convenient way of sharing build results and artifacts.</li>
<li>Ability to run builds without having to mess with command line parameters.</li>
<li>Tight integration with version control.</li>
<li>History and statistics.</li>
<li>Accountability and audit (e.g., who ran what build).</li>
</ul>

<p>In most instances build servers, such as <a href="https://hudson.dev.java.net/">Hudson</a>, <a href="http://continuum.apache.org/">Continuum</a> or <a href="http://luntbuild.javaforge.com">LuntBuild</a> are used mostly for continuous integration and development builds. But they can be used for much more than that. A build server provides a generic framework for performing any kind of deployment or operations-related activity, including deployment of an application into acceptance and production environments, configuring of an app server (e.g., setting up data sources and JMS destinations) and even app server monitoring. </p>

<p>Several things make it possible. Build servers have flexible scheduling capabilities allowing to schedule any kind of repetitive activity, such as "pinging" a server every 15 minutes. Integration with version control makes it easier to manage the scripts. Very often, scripts for administration or configuration tasks are created in an ad-hoc fashion with multiple versions scattered around different servers and directories. A build server is able to check out a specific version of a script from a version control system and execute it. In other words, a build server helps treating admin scripts same way with business applications. Additionally, build servers can publish logs. This is powerful, since it lets anyone (who has permissions) see results of configuration activities or monitoring scripts. Finally, build servers do a great job of notifying all interested parties via e-mail, RSS, IM and other means of communication. </p>

<p>Security could be another important benefit of leveraging a build server outside of development builds. Usually, access to production environments is tightly controlled. In many organizations, developers have no access to production whatsoever. Build server can help enforce this policy yet give developers visibility into the details of production deployment. This can be done by creating a separate build configuration just for production deployments. </p>

<p>All the benefits that I mentioned in the beginning of this post also apply to non-build activities. For example, the ability to see history of all production deployments can be very valuable.</p>

<p>Not all build servers are created equal, especially open source ones. Security, for one, could be supported and implemented very differently in different products. Support for various version control features, such as labels and branches, also varies. In other words, careful evaluation is required before embarking on an effort of expanding the build server beyond development. But more importantly, this effort requires buy-in from operations and support organization and other groups that will become users of the build server.</p>

<p>As an example, on my current job we've been able to implement a number of interesting non-build functions using our build server (we use LuntBuild, which has worked great for us):</p>

<ul>
<li>Deployment of pre-built EAR/WAR files into test and production environments. </li>
<li>Configuration of application servers. In our case, most of the app server resources are shared, so we run the configuration script separately from application deployments. In fact, we treat configuration as a separate "unit of release" with its own lifecycle. </li>
<li>Monitoring of application servers. We have a script which tests health of application servers using JMX. </li>
<li>Log scanning. We've implemented a custom log scanning tool which "greps" logs for various patterns. The build server sends notification if a pattern is found in the logs. </li>
</ul>

<p>Of course, many of these functions can be accomplished using various commercial system management and monitoring products. These products however can get expensive and very often organizations simply don't have enough licenses to cover all environments. So a combination of custom scripts with a build server can provide a viable alternative.</p>
]]></content:encoded>
			<wfw:commentRss>http://myarch.com/going-beyond-builds-with-build-servers/feed</wfw:commentRss>
		</item>
	</channel>
</rss>
