<?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>Techtracer &#187; XML</title>
	<atom:link href="http://techtracer.com/category/xml/feed/" rel="self" type="application/rss+xml" />
	<link>http://techtracer.com</link>
	<description>Tracing the course of Web Technology</description>
	<lastBuildDate>Mon, 26 Sep 2011 12:30:35 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
<image>
  <link>http://techtracer.com</link>
  <url>http://techtracer.com/wp-includes/images/favicon.png</url>
  <title>Techtracer</title>
</image>
		<item>
		<title>Understanding XSD Namespaces With Concepts of Java</title>
		<link>http://techtracer.com/2007/09/19/understanding-xsd-namespaces-with-concepts-of-java/</link>
		<comments>http://techtracer.com/2007/09/19/understanding-xsd-namespaces-with-concepts-of-java/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 17:49:17 +0000</pubDate>
		<dc:creator>nitinpai</dc:creator>
				<category><![CDATA[Concepts]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://techtracer.com/2007/09/19/understanding-xsd-namespaces-with-concepts-of-java/</guid>
		<description><![CDATA[This article is aimed at developers who are good at programming languages like Java and want a quick jump on the XSD bandwagon by understanding some important concepts like namespaces. Hope that this article helps to make you understand namespaces quite easily. What is a namespace? A namespace is an identifier for elements. XML and [...]]]></description>
			<content:encoded><![CDATA[<p>This article is aimed at developers who are good at programming languages like <strong>Java</strong> and want a quick jump on the <strong>XSD</strong> bandwagon by understanding some important concepts like <strong>namespaces</strong>. Hope that this article helps to make you understand <strong>namespaces</strong> quite easily.</p>
<p><u><strong>What is a namespace?</strong></u></p>
<p>A namespace is an <strong>identifier</strong> for elements. <strong>XML</strong> and <strong>XSD</strong> use the concept of namespaces to define a<strong> relationship</strong> between the elements and their hierarchy. It means that when their are multiple elements to be defined then it might be possible that some of the elements may tend to have the same name. But having the same name often leads to collision just as the in the case of classes with same names although in different packages but referenced by name alone in a Java program. Hence the concept of <strong>namespaces</strong> is used in order to distinguish such elements.</p>
<p><u><strong>Why are namespaces used?</strong></u></p>
<p>XML and XSD are never meant for human reading. You have to remember that even though XML is a <strong>data representation</strong> markup language, it would be rare that you will actually be parsing through an XML file to use the data in your application through your own code.</p>
<p>Such parsing is often supplied through the use of API&#8217;s like <strong>SAX, DOM, JAXB</strong>, etc. You would have till now actually used these libraries while dealing with web services since it is field which uses XML, XSD to the maximum. The concept of namespace has no <strong>relevance</strong> until and unless an XML<strong> instance</strong> is associated with an <strong>XML Schema</strong> (XSD). This is because, XSD defines what do the elements in the XML instance actually mean. A standalone XML just makes the data easier to understand to you but to an XML parser it is nothing but a set of elements in some heirarchy.</p>
<p>For example if suppose you have the following XML format:</p>
<blockquote><p>&lt;employee&gt;<br />
&lt;name&gt;<strong>Alan</strong>&lt;/name&gt;<br />
&lt;/employee&gt;</p></blockquote>
<p>From this an XML parser can list out that the XML instance contains <strong>2 elements</strong> in which <em>employee</em> is the <strong>root </strong>and <em>name</em> is the <strong>child</strong> of employee. It cannot say anything more than that. For giving more meaning to the elements, XML Schema or XSD should be provided. If you want the parser to know what kind of element <em>employee</em> is then you would have to provide a namespace for the element to be in as follows:</p>
<blockquote><p>&lt;<strong>tt</strong>:employee <strong>xmlns:tt</strong>=&#8221;http://techtracer.com/schemas/employee&#8221;&gt;<br />
&lt;name&gt;Alan&lt;/name&gt;<br />
&lt;/<strong>tt</strong>:employee&gt;</p></blockquote>
<p><u><strong>How to interpret namespaces?</strong></u></p>
<p>In an object oriented language like Java, entities of the real world are mapped to <strong>Beans</strong>. Beans have <strong>properties</strong>. And in general every application uses the beans and their properties to provide values which are taken from either a system or an end user. Such values when needed to be transferred in the XML format need some kind of hierarchy to be structured with. For this API&#8217;s come to the rescue.</p>
<p>But before we can supply the API with the elements in any adhoc fashion it becomes necessary that we make the API aware of the structure by providing it with the Schema without which the API won&#8217;t be able to tell you if anything has gone wrong in the hierarchy or not. Such API are said to be <strong>namespace aware</strong> API&#8217;s.</p>
<p>For Example, if I have an bean inside a package which is to be included into any program then you would include it when required as:</p>
<blockquote><p><strong>import</strong> com.techtracer.*;</p>
<p>//and then make the bean as</p>
<p>MyBean bean = new MyBean();</p></blockquote>
<p>Now you can refer to the classes within the package successfully.</p>
<p>Comparing the above to namespaces consider the example.</p>
<blockquote><p>&lt;tt:employee xmlns:tt=&#8221;http://techtracer.com/schemas/employee&#8221;&gt;<br />
&lt;/tt:employee&gt;</p></blockquote>
<p>Here <strong>tt</strong> would be an <em>prefix</em> to the elements which has the value of the entire URL and it would correspond to the namespace just as a package in Java and <em>employee</em> would be an element just as the <em>MyBean</em> in Java. If you would not have provided the packages then the Java program would have given out an error. Similarly in a namespace aware XML parser if you don&#8217;t specify the namespace of the element then it would not run successfully.</p>
<p><u><strong>Default Namespaces</strong></u></p>
<p><strong>java.lang.*</strong> is the default package of core java. Comparing with a XSD the default namespace is:</p>
<blockquote><p>&lt;xsd <strong>xmlns</strong>=&#8221;http://www.w3c.org/2001/01/XMLSchema&#8221;&gt;<br />
&lt;/xsd&gt;</p></blockquote>
<p>Here <strong>xsd</strong> is in the default namespace i.e. the element xsd is an element of the XSD <strong>specification</strong>. So now we can say that as java.lang is the default package of java similarly the above namespace is the default namespace of XSD. And as <strong>Object</strong> is the parent of the Java classes the element xsd is the root of the XSD specification</p>
<p><u><strong>Custom and Target Namespaces</strong></u></p>
<p>There are libraries in Java, which may / may NOT be required. Library means something which you can refer to when required, else not. So including it unnecessarily as a inherent feature may be disturbing since they are present for specific reasons and not to be imposed as an implicit feature of the language. Consider this example:</p>
<blockquote><p>&lt;xsd xmlns=&#8221;http://www.w3c.org/2001/01/XMLSchema&#8221;&gt;<br />
&lt;<strong>employee</strong>&gt;Alan&lt;/<strong>employee</strong>&gt;<br />
&lt;/xsd&gt;</p></blockquote>
<p>Woops, now here is an error. The element <em>employee</em><strong> </strong>is <strong>NOT</strong> an element of the XSD specification. If you have an XSD<strong> validator</strong> it will blurt out with a big error message. This is because the XSD specification does not know a thing about your custom element <em>employee</em>. So what do you do? Somehow you should keep your<strong> </strong><em>employee</em> in a safe and secure place where it can be recognized as yours. So we can keep it under a <strong>custom namespace</strong> like &#8220;http://techtracer.com/schemas/employee&#8221;. So the change required in the above fragment would be as follows:</p>
<blockquote><p>&lt;xsd xmlns=&#8221;http://www.w3c.org/2001/01/XMLSchema&#8221; <strong>targetnamespace</strong>=&#8221;http://techtracer.com/schemas/employee&#8221;&gt;<br />
&lt;employee&gt;Alan&lt;/employee&gt;<br />
&lt;/xsd&gt;</p></blockquote>
<p>So now when the XSD validator comes across the element <strong>employee</strong>, it just checks if you have told it where it should belong (before starting the ritual of swearing at you!). Now it knows that you have mentioned a thing called <strong>targetnamespace.</strong> So it knows that your <em>employee</em> actually belongs to a separate specification which is nothing but your custom XML Schema. The new URL which is mentioned in the targetnamespace is your <strong>custom namespace</strong> itself.</p>
<p><u><strong>Conclusion</strong></u></p>
<p>Hope that this article helps to make you understand <em>namespaces</em> quite easily. Feel free to ask a question if you have any doubt about <em>namespaces</em>. Your query will be solved at the earliest.</p>
<h2>Related posts:</h2><ul><li><a href="http://techtracer.com/2007/04/04/java-5-generics-changing-for-good/" rel="bookmark" title="Permanent Link: Java 5 Generics &#8211; Changing for good">Java 5 Generics &#8211; Changing for good</a></li><li><a href="http://techtracer.com/2007/10/10/resolving-the-unsupported-majorminor-version-490-error/" rel="bookmark" title="Permanent Link: Resolving the &#8220;Unsupported major.minor version 49.0&#8243; Error">Resolving the &#8220;Unsupported major.minor version 49.0&#8243; Error</a></li><li><a href="http://techtracer.com/2007/08/01/j2ee-or-jee-java-5-or-java-15-is-sun-crazy/" rel="bookmark" title="Permanent Link: J2EE or JEE, Java 5 or Java 1.5 &#8211; Is SUN Crazy?">J2EE or JEE, Java 5 or Java 1.5 &#8211; Is SUN Crazy?</a></li><li><a href="http://techtracer.com/2007/08/13/java-ee-exhaustive-yet-enchanting/" rel="bookmark" title="Permanent Link: Java EE &#8211; Exhaustive yet Enchanting">Java EE &#8211; Exhaustive yet Enchanting</a></li><li><a href="http://techtracer.com/2007/09/03/and-i-thought-i-knew-how-java-worked/" rel="bookmark" title="Permanent Link: And I thought I Knew How Java Worked!">And I thought I Knew How Java Worked!</a></li></ul><br /><a href="http://techtracer.com/">Techtracer.com</a> Copyright &copy; 2008<br /> ]]></content:encoded>
			<wfw:commentRss>http://techtracer.com/2007/09/19/understanding-xsd-namespaces-with-concepts-of-java/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>The Great Ant Tutorial &#8211; a great jump start</title>
		<link>http://techtracer.com/2007/04/16/the-great-ant-tutorial-a-great-jump-start/</link>
		<comments>http://techtracer.com/2007/04/16/the-great-ant-tutorial-a-great-jump-start/#comments</comments>
		<pubDate>Mon, 16 Apr 2007 17:20:33 +0000</pubDate>
		<dc:creator>nitinpai</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Java EE]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://techtracer.com/2007/04/16/the-great-ant-tutorial-a-great-jump-start/</guid>
		<description><![CDATA[Apache Ant is a powerful way to convert your developmental structures to deployment structures. It is declarative and all the command line tasks used for deploying an application are represented by simple XML elements. Without much details, this tutorial would breeze you through the steps on how to build a web application using a single [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Apache Ant</strong> is a powerful way to convert your developmental structures to deployment structures. It is  declarative and all the command line tasks used for deploying an application are represented by simple <strong>XML</strong> elements. Without much details, this tutorial would breeze you through the steps on how to build a web application using a single <strong>XML build file</strong> and nothing else. If you have not yet understood what is the use of <strong>Ant,</strong> read my article on <a href="http://techtracer.com/2007/03/31/development-and-deployment-structures-the-perfect-way-to-build-a-web-application/">Development and Deployment Structures &#8211; the perfect way to build web applications</a>.</p>
<p>I would use the same analogy of my development structure as mentioned in the above linked article i.e. my development structure consists of the following directories:</p>
<ol>
<li><strong>web</strong> &#8211; place for all my JSP, HTML, JavaScripts and Stylesheets. You can provide subdirectories as required for each of the different set of files</li>
<li><strong>src</strong> &#8211; place for my java class files consisting of POJO&#8217;s or servlets.</li>
<li> <strong>etc</strong> &#8211; place for all config files like the most common <em>web.xml</em></li>
<li><strong>lib </strong>- place for all the necessary jar files to run my application. I even have included <strong>servlet-api.jar</strong> in this directory since you may have to deploy your web application in a remote server after compiling.</li>
<li> <strong>build</strong> &#8211; a temporary directory for keeping the compiled files</li>
<li><strong>dist</strong> &#8211; a place to put in the finally packaged <em>war file</em> (distribution)</li>
<li><strong>ant</strong>- place for my <em>build.xml</em> file and external <em>properties file</em></li>
</ol>
<p>All these directories are present in a parent directory called &#8220;<strong>WebApp</strong>&#8220;. The three things you have to keep in mind for making an Ant build file are -</p>
<ol>
<li> <strong>tasks </strong>- which correspond to your command line tasks like<em> javac</em>, <em>war</em> etc. A group of tasks can be executed in a sequence by specifying targets.</li>
<li><strong>target</strong> &#8211; It is like a function where you put reusable <strong>tasks</strong> so that it can be called later without duplicating them.</li>
<li><strong>property</strong> &#8211; this element is used to define variables in your build file which is useful when the value like <em>project_name</em> or <em>folder_name</em> keeps on changing.</li>
</ol>
<p>One of the most awesome features of Ant is that you can keep the properties file <strong>externally</strong> inside of defining all the variables within the build file. This properties file consists of all the required variables and their values in the form of <em>name-value</em> pairs and is simple text file. In this tutorial I would be using an external properties file.</p>
<p>For the tutorial I have used the following:</p>
<ol>
<li><a href="http://java.sun.com/javase/downloads/index.jsp">Java version 1.5</a></li>
<li><a href="http://tomcat.apache.org/download-55.cgi">Apache Tomcat 5.0</a></li>
<li><a href="http://ant.apache.org/">Apache Ant 1.6.5</a></li>
</ol>
<p>Okay we are now good to go with the great Ant tutorial. For this make a file with the name &#8220;<strong>build.properties</strong>&#8220;. This would be our external variables file.</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;">root.dir=..
lib.dir=lib
src.dir=com
conf.dir=etc
web.content=web
project.name=WebApp
build.dir=build</pre></div></div>

<p><u><strong>NOTE</strong></u><strong>:</strong> you must hit the ENTER key for starting a new line after the last line or Ant will give you an error &#8220;<em>BUILD FAILED for some unknown reason</em>&#8221;</p>
<p>It is not necessary to put in the name with the dot. You can have a name as &#8220;<em>projectName</em>&#8221; but there should be no quotes for the value. i.e it should NOT be <em>projectName=&#8221;WebApp&#8221;</em></p>
<p>To make a build file we have to remember what is to be done for the deployments. To make things simple just make the modules (<strong>targets</strong>) necessary for the complete web application deployment which are</p>
<ol>
<li><strong>clean</strong>  &#8211; remove all prior deployments of the same application if made</li>
<li> <strong>init</strong> &#8211; make the necessary structure for deployment as per the vendor&#8217;s</li>
<li><strong>compile</strong> &#8211; compile your servlets or <em>POJO</em>&#8216;s</li>
<li><strong>copy</strong> &#8211; put the compiled files and web content in the deployment structre as created during init</li>
<li><strong>war</strong> &#8211; make the war file and open the browser</li>
</ol>
<p>Start making the <strong>build.xml</strong> file in the ant folder as follows:</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;project</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;AppBuilder&quot;</span> <span style="color: #000066;">default</span>=<span style="color: #ff0000;">&quot;war&quot;</span> <span style="color: #000066;">basedir</span>=<span style="color: #ff0000;">&quot;..&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">file</span>=<span style="color: #ff0000;">&quot;ant/build.properties&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/project<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Now we have to set the <em>classpath</em> for the <em>servlet-api.jar</em> to compile our servlets so put the <strong>servlet-api.jar</strong> in the lib directory of your development structure. Check the property &#8220;<em>default</em>&#8221; in the <em>&lt;project&gt;</em> element. It states the LAST module (target) inside the build file. In our case it is &#8220;<em>war</em>&#8221;</p>
<p>All the following XML elements will now go inside the <strong>&lt;project&gt;&lt;/project&gt;</strong> element created above. So put the classpath setting element,</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;path</span> <span style="color: #000066;">id</span>=<span style="color: #ff0000;">&quot;classpath&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
 	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;fileset</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${lib.dir}&quot;</span> <span style="color: #000066;">includes</span>=<span style="color: #ff0000;">&quot;servlet-api.jar&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/path<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Here you need to set all the necessary jars to your classpath for successful compilation of the java source files. <em>${lib.dir}</em> is used to retrive the value of the &#8220;<em>lib.dir</em>&#8221; i.e <strong>lib</strong></p>
<p>Now we will start with out targets (modules) as mentioned in the list above :</p>
<p><strong>1. clean</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;clean&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>Cleaning the ${build.dir}<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;delete</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${build.dir}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Here I am removing my build dir in case it was present earlier with compiled files<br />
The <em>&lt;echo&gt;</em> element is only for displaying what you are doing in the command line.</p>
<p><strong>2. init</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;init&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;clean&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>Creating the build directory<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;mkdir</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INFclasses&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;mkdir</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INFlib&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Here I am creating the normal deployment structure required for tomcat namely <em>WebApp/WEB-INF/classes</em>, etc. It doesn&#8217;t matter if the folder WEB-INF existed before making the folder classes. Ant automatically creates all the necessary parent folders if they don&#8217;t exist.</p>
<p><strong>3. compile</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;compile&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;init&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>Compile the source files<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;javac</span> <span style="color: #000066;">srcdir</span>=<span style="color: #ff0000;">&quot;${src.dir}&quot;</span> <span style="color: #000066;">destdir</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INF/classes&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;classpath</span> <span style="color: #000066;">refid</span>=<span style="color: #ff0000;">&quot;classpath&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/javac<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Most important step and the most error giving step. Make sure that all the classpath have been set in the above <em>&lt;path&gt;</em> element. If all are proper then the all files in &#8220;<em>src.dir</em>&#8221; will be compiled successfully and moved to the <em>build\WebApp\WEB-INF\classes</em>. Just check the property &#8220;depends&#8221; of the <em>&lt;target&gt;</em> element here. This property is used to chain the modules (<strong>targets</strong>) in a sequential manner.</p>
<p><strong>4. copy</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;copy&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;compile&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;copy</span> <span style="color: #000066;">todir</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INF&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;fileset</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${conf.dir}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/copy<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;copy</span> <span style="color: #000066;">todir</span>=<span style="color: #ff0000;">&quot;${build.dir}&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;fileset</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${web.content}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/copy<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;copy</span> <span style="color: #000066;">todir</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INF/lib&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;fileset</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${lib.dir}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/copy<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Here I am just copying my complied classes and web content files inside the corresponding deployment structure.</p>
<p><strong>5. war</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;war&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;copy&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>Building the war file<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;war</span> <span style="color: #000066;">destfile</span>=<span style="color: #ff0000;">&quot;${dist.dir}/${project.name}.war&quot;</span> <span style="color: #000066;">webxml</span>=<span style="color: #ff0000;">&quot;${build.dir}/WEB-INF/web.xml&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;fileset</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${build.dir}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/war<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>This is the final module (target) in my <strong>build.xml</strong> file which makes the <em>WebApp.war</em> required for the deployment. &#8220;<strong>war</strong>&#8221; is an Ant task for which you provide the path of the <em>web.xml</em> file and the directory which contains the deployment structure i.e in our case &#8220;<em>build</em>&#8221; directory. The <em>destfile</em> is the final location and name of the war file which would become <em>dist\WebApp.war</em> after the script has run.</p>
<p><u><strong>Running the above script</strong></u><br />
Keep the <strong>build.properties</strong> and <strong>build.xml</strong> files in the <strong>ant</strong> folder. Make sure that the ANT_HOME environment variable is set to your <strong>ant</strong>&#8216;s installation <strong>bin</strong> directory. Now, all you have to do is run the <strong>ant</strong> command on the build file as,</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;">C:\&gt; cd WebAppant\ant
C:\WebAppant\ant&gt; ant</pre></div></div>

<p>That&#8217;s it. If successful your development will finally become a fully packaged <strong>WebApp.war</strong>.</p>
<p><u><strong>Final Words</strong></u><br />
Thus, we have made a complete packaged war file from our source with a single XML file and the wonderful <strong>Ant</strong> tool which is ready to be deployed in the <strong>tomcat manager</strong>. We can further dig deeper and make complex <strong>build.xml</strong> using the complete set of elements that Ant provides. But this tutorial was just to get you started with using <strong>Apache Ant</strong>. If you have any difficulty in understanding the individual elements please read their detailed explanation in the Apache Ant documentation.</p>
<p><u><strong>Resources</strong></u><br />
If you have any problem in making the build.xml or build.properties please download them from here. (<em>Right click and select &#8220;Save as &#8230;.&#8221;</em>)</p>
<ul>
<li><a href="http://techtracer.com/wp-content/uploads/ant/build.xml">build.xml</a></li>
<li><a href="http://techtracer.com/wp-content/uploads/ant/build.properties">build.properties</a></li>
</ul>
<h2>Related posts:</h2><ul><li><a href="http://techtracer.com/2008/01/09/impressive-google-chart-generator-scripts/" rel="bookmark" title="Permanent Link: Impressive Google Chart Generator Scripts">Impressive Google Chart Generator Scripts</a></li><li><a href="http://techtracer.com/2008/04/26/the-technique-of-virtual-deployment-in-tomcat/" rel="bookmark" title="Permanent Link: The Technique of Virtual Deployment in Tomcat">The Technique of Virtual Deployment in Tomcat</a></li><li><a href="http://techtracer.com/2008/12/30/the-great-hibernate-tutorial-a-great-jump-start-for-beginners/" rel="bookmark" title="Permanent Link: The Great Hibernate Tutorial &#8211; a great jump start for beginners">The Great Hibernate Tutorial &#8211; a great jump start for beginners</a></li><li><a href="http://techtracer.com/2007/10/06/mozillas-new-killer-app-the-webrunner/" rel="bookmark" title="Permanent Link: Mozilla&#8217;s New Killer App &#8211; The WebRunner">Mozilla&#8217;s New Killer App &#8211; The WebRunner</a></li><li><a href="http://techtracer.com/2007/08/19/working-with-jax-ws-in-jdk-16/" rel="bookmark" title="Permanent Link: Working With JAX-WS in JDK 1.6">Working With JAX-WS in JDK 1.6</a></li></ul><br /><a href="http://techtracer.com/">Techtracer.com</a> Copyright &copy; 2008<br /> ]]></content:encoded>
			<wfw:commentRss>http://techtracer.com/2007/04/16/the-great-ant-tutorial-a-great-jump-start/feed/</wfw:commentRss>
		<slash:comments>75</slash:comments>
		</item>
		<item>
		<title>Annotations in POJO &#8211; a boon or a curse?</title>
		<link>http://techtracer.com/2007/04/07/annotations-in-pojo-a-boon-or-a-curse/</link>
		<comments>http://techtracer.com/2007/04/07/annotations-in-pojo-a-boon-or-a-curse/#comments</comments>
		<pubDate>Sat, 07 Apr 2007 16:58:36 +0000</pubDate>
		<dc:creator>nitinpai</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Java EE]]></category>
		<category><![CDATA[Web Services]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://techtracer.com/2007/04/07/annotations-in-pojo-a-boon-or-a-curse/</guid>
		<description><![CDATA[The purpose of annotations have been well put forward with the recent upgradation of EJB to EJB 3.0 and also in the web services field by JAX-WS. Annotations help in reducing the learning curve associated with these specifications by avoiding the need to learn the deployment descriptors which are necessary to properly deploy an EJB [...]]]></description>
			<content:encoded><![CDATA[<p>The purpose of annotations have been well put forward with the recent upgradation of <strong>EJB</strong> to <strong>EJB 3.0</strong> and also in the web services field by <strong>JAX-WS</strong>. Annotations help in reducing the learning curve associated with these specifications by avoiding the need to learn the deployment descriptors which are necessary to properly deploy an <strong>EJB</strong> or a <strong>JAX-WS</strong> web service respectively.</p>
<p><u><em><strong>Annotations &#8211; a boon or a curse?</strong></em></u><br />
Due to the above situation, the influence on the usage of annotations is steadily rising. It is but natural that programmers would try to do their work quickly without having to waste the time in learning the XML Schema&#8217;s required for deployment. Annotations are purposely aimed at this programmer&#8217;s dilemma. In fact when I was working in <strong>JAX RPC,</strong> I used to think as to when I would get a tool to code those ugly descriptors in an easier fashion. With annotation based web services creation in <strong>JAX-WS</strong>, half of my work is done when I put them in the <em>POJO</em> itself.</p>
<p>All of this can be attributed as a boon to the presence of annotations. But the point of worry is, whether all those annotations which are pushed in the <em>POJO</em> to do work in an easier manner are really worthwhile? What has happened to the age old technique wherein a <em>POJO</em> by nature would remain a <em>POJO</em> such that it could be used wherever required without having to change the code in future.</p>
<p><u><em><strong>Degradation of POJO&#8217;s</strong></em></u><br />
You have to remember that the ugly deployment descriptors which we swear at are the actual components in an application which give us the power of code flexibility and code reuse. They are here to make changes and configurations during runtime without having to touch the class files. But with the presence of annotations I fear that people would become slaves to them and all of the configuration code would be pushed into the <em>POJO</em>&#8216;s.</p>
<p>According to the <em>POJO</em> definition, a <em>POJO</em> doesn&#8217;t remain a <em>POJO</em> anymore, once it relies on any kind of API or framework which makes it dependent on an environment other than the <strong>JVM</strong>. <a href="http://en.wikipedia.org/wiki/Plain_Old_Java_Object">According to</a><em><a href="http://en.wikipedia.org/wiki/Plain_Old_Java_Object"> Wikipedia</a>, a</em> <em>POJO</em> should not have to,</p>
<blockquote>
<ol>
<li>extend prespecified classes</li>
<li>implement prespecified interfaces</li>
<li>contain prespecified annotations</li>
</ol>
</blockquote>
<p>An annotation may not change a <em>POJO</em>&#8216;s behavior but it makes it dependent on the environment. If you try to compile a <em>POJO</em> in your <strong>JVM</strong> it won&#8217;t get compiled. This is because an annotation also requires an environment to get translated into its specific configuration file. So the question is how would you attribute a normal <em>POJO</em> behavior to the one with annotations. They are not the same.</p>
<p><u><em><strong> The problem in using Annotations</strong></em></u><br />
A framework which makes use of the normal <em>POJO</em> without changing them would be a truly flexible framework. If we try to compare <strong>EJB 3.0</strong> with the <strong>Spring</strong> framework we would immediately come to know the difference. In <strong>EJB 3.0</strong> you declare a bean with an annotation in a <em>POJO</em> whereas in  a <strong>Spring</strong> framework an <strong>XML</strong> file is used for weaving the <em>POJO</em>&#8216;s to make a flow control or give them special functionalities.</p>
<p><strong>Nathan</strong> has stated in his <a href="http://nate-tech.blogspot.com/2005/10/are-annotated-java-classes-still-pojos.html">tech blog</a>,</p>
<blockquote><p>In conclusion, annotated objects, for the simple reason that you can&#8217;t compile them without needing external resources, are <span style="font-style: italic">not</span> truly &#8220;Plain Ordinary Java Objects.&#8221;  They have been made<span style="font-style: italic"> un-plain</span> and <span style="font-style: italic">un-ordinary</span> by their annotations.</p></blockquote>
<p>This is the same point that I am trying to make through the above comparison that annotations might be great but they make a dependency in your <em>POJO</em> functionalities. The rule of thumb in the application development domain is to <strong>always</strong> keep the business functionality away from the technicalities of the framework or any of the 3rd party API&#8217;s. And <strong>annotations do the exact opposite</strong>. How can one guarantee that the annotated <em>POJO</em>&#8216;s would be useful in another container which does not have the annotation related classes?</p>
<p><u><em><strong>A cause for worry</strong></em></u><br />
Even though the above problem exists we cannot give away with annotations, because we don&#8217;t have time time enough to learn the humongous amount of XML schema&#8217;s to make our configurations. In this case we would either require a <strong>lightweight framework</strong> which does not heavily rely on XML descriptors  like <strong>Spring</strong> as compared with those in <strong>EJB 2.1</strong>. Or the round about manner is the use the annotation only in those classes where the special functionality is to be attributed to the <em>POJO</em>. This is a similar to following patterns such as the <strong>factory</strong> or the <strong>decorator pattern</strong>.</p>
<p>But who would guarantee that all the programmers would be following such methods? Not everyone understands the depth of technology. Normally people work with the things taught to them . But if they are only taught annotations as per the current trends, it wouldn&#8217;t be much late before our age old methods to keep <em>POJO</em>&#8216;s as <em>POJO</em> would fail because with annotations, they would become dependent and later we would need something which would once again make them flexible as earlier. Doesn&#8217;t it seem like we are reinventing the wheel?</p>
<h2>Related posts:</h2><ul><li><a href="http://techtracer.com/2007/08/13/java-ee-exhaustive-yet-enchanting/" rel="bookmark" title="Permanent Link: Java EE &#8211; Exhaustive yet Enchanting">Java EE &#8211; Exhaustive yet Enchanting</a></li><li><a href="http://techtracer.com/2007/08/26/eclipse-europa-has-ruined-my-day/" rel="bookmark" title="Permanent Link: Eclipse Europa Has Ruined My Day">Eclipse Europa Has Ruined My Day</a></li><li><a href="http://techtracer.com/2007/08/15/jax-ws-jaxp-tutorial-building-a-stockquote-web-service-client/" rel="bookmark" title="Permanent Link: JAX-WS + JAXP Tutorial &#8211; Building A StockQuote Web Service Client">JAX-WS + JAXP Tutorial &#8211; Building A StockQuote Web Service Client</a></li><li><a href="http://techtracer.com/2008/03/30/designing-enterprise-applications-approaches-and-patterns/" rel="bookmark" title="Permanent Link: Designing Enterprise Applications &#8211; Approaches and Patterns">Designing Enterprise Applications &#8211; Approaches and Patterns</a></li><li><a href="http://techtracer.com/2007/04/23/inversion-of-control-for-easy-integration/" rel="bookmark" title="Permanent Link: Inversion of Control &#8211; for easy integration">Inversion of Control &#8211; for easy integration</a></li></ul><br /><a href="http://techtracer.com/">Techtracer.com</a> Copyright &copy; 2008<br /> ]]></content:encoded>
			<wfw:commentRss>http://techtracer.com/2007/04/07/annotations-in-pojo-a-boon-or-a-curse/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>JSON Web Services &#8211; the XML JSON debate further ahead</title>
		<link>http://techtracer.com/2007/04/01/json-web-services-the-xml-json-debate-further-ahead/</link>
		<comments>http://techtracer.com/2007/04/01/json-web-services-the-xml-json-debate-further-ahead/#comments</comments>
		<pubDate>Sun, 01 Apr 2007 13:52:18 +0000</pubDate>
		<dc:creator>nitinpai</dc:creator>
				<category><![CDATA[Ajax]]></category>
		<category><![CDATA[Web Services]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://techtracer.com/2007/04/01/json-web-services-the-xml-json-debate-further-ahead/</guid>
		<description><![CDATA[I have been keeping a track of JSON (JavaScript Object Notation) versus XML for the past couple of months when AJAX came up as a big bang approach. Arun Gupta also recounts his similar experience with the XML JSON debate and concludes, XML is document-oriented and JSON is data-oriented. So if you want to deal [...]]]></description>
			<content:encoded><![CDATA[<p>I have been keeping a track of <a href="http://www.json.org/">JSON (JavaScript Object Notation)</a> versus <a href="http://en.wikipedia.org/wiki/XML">XML</a> for the past couple of months when <a href="http://techtracer.com/2007/03/12/the-birth-of-ajax-an-amazing-story/">AJAX</a> came up as a big bang approach.  <a href="http://blogs.sun.com/arungupta/entry/language_neutral_data_format_xml">Arun Gupta</a> also recounts his similar experience with the XML JSON debate and concludes,</p>
<blockquote><p>XML is document-oriented and JSON is data-oriented. So if you want to deal with highly structured documents that requires a complex structure, binary data, exact ordering of elements and be able to render itself then use XML. If you are focused on light-weight data exchange then JSON is the way to go.</p></blockquote>
<p>In my opinion too JSON is handy only for <strong>light weight data transfer</strong> and nothing more than that. But with more nesting of data JSON can get utterly complex than XML. With XML you can define <strong>Schemas</strong>, form standardized document structures , extend exisiting document structures or import them when needed. The <strong>namespaces</strong> concept of XML has been very well established and incorporated in today&#8217;s applications and libraries.</p>
<p><u><em><strong>XML Dominance</strong></em></u><br />
XML got more acceptance due to the already well established markup languages like HTML. Due to <a href="http://www.w3.org/XML/">standardization by W3C</a> it got quickly incorporated into the big vendors tools. Even a well documented JSP is purely XML. The main advantage of XML success is the XML Schema defintion language (XSD) which has given rise to numerous other standards like <a href="http://en.wikipedia.org/wiki/SOAP">SOAP</a>, <a href="http://en.wikipedia.org/wiki/Web_Services_Description_Language">WSDL</a> etc. It is a very <strong>flexible</strong> and <strong>extensible</strong> language.</p>
<p>If you look behind the scenes a bit, XML has been reigning from the past and its usage in the industry has become massive. You might not be aware but all the big applications use XML either for storage, transfer, presentation or configuration of data and also meta data. MS SQL uses XML to transfer data from one database to other. MS WORD uses XML to provide formatting of user input content in the documents.</p>
<p><u><em><strong>JSON- Some Facts</strong></em></u><br />
Coming back to JSON, the main fact which goes against JSON is<strong> it is not standardized</strong>. But now if JSON wants to establish its presence then the only field in my opinion would be <strong>SOA web services and AJAX</strong> where, it has received a lot of attention. Lately the debate on using web services with JSON has started. XML being heavy puts somewhat a hindrance on the acceptance of web services since the network infrastructure needs to get upgraded to get quicker adoption of XML RPC web services. With JSON, if web services give a higher throughput then it might be time to cash upon its acceptance for data transfer. Alexander writes about <a href="http://myarch.com/json-pros-and-cons">JSON pros and cons</a> in his blog <em>MyArch</em>,</p>
<blockquote><p>One of the keys to SOA success is that it should be easy to consume a service, i.e., the entry barrier for service consumers must be low to support &#8220;grass root&#8221; SOA adoption. While a top-down SOA effort may succeed, it will certainly take longer than bottom-up (&#8220;grass-root&#8221;) approach when developers are able to consume services as they see fit. AJAX/JSON fits this bill perfectly &#8211; it is easily understood by developers and it does not require any Web services -specific tools or infrastructure.So overall I&#8217;m pretty enthusiastic about JSON.</p></blockquote>
<p><u><em><strong>Advantages of JSON </strong></em></u><br />
The advantage of using JSON instead of XML is in the inheritent quality of data structuring in JSON. JSON is more closer to being a <span class="tooltip" title="header=[HashMap] body=[An object which consists of name-value pair of data]">HashMap</span> as in java or an <span class="tooltip" title="header=[Associative Array] body=[An array which uses string values instead of numbers as index]">associative array</span> in some other languages like <a href="http://www.php.net">PHP</a>. Hence it does not require parsing libraries in an application as XML does. The time spent however, on parsing XML into the native language, is not so much significant considering the fast processing power of machines today.</p>
<p>The comparison of XML and JSON lies more on the <strong>network bandwidth</strong> aspect. JSON can take almost <strong>half of the bandwidth</strong> as XML for transferring the same data. It can achieve the same throughput as passing simple objects in the network in a distributed computing environment.</p>
<blockquote></blockquote>
<p><u><em><strong>JSON Web Services?</strong></em></u><br />
It would be interesting to see how would a SOAP message with JSON look like. You have to remember that WSDL is an extensible language and till date only <strong>HTTP Bindings</strong> and <strong>SOAP Bindings</strong> have been defined for it. It wont be long before we see <strong>JSON Bindings</strong> coming into the WSDL documents.  Who would not want a quick data transfer while using web services into the application?</p>
<p>AJAX with JSON has got accepted well since JavaScript has the inbuilt capability to handle JSON data and if JSON web services start getting acceptance it might get well flourished to reach the popularity charts as XML did. Is the web service industry looking for a paradigm shift or are we just building a castle in the air?</p>
<h2>Related posts:</h2><ul><li><a href="http://techtracer.com/2006/10/16/bea-aqualogic-data-services-platform-first-glimpse/" rel="bookmark" title="Permanent Link: BEA Aqualogic Data Services Platform &#8211; First Glimpse">BEA Aqualogic Data Services Platform &#8211; First Glimpse</a></li><li><a href="http://techtracer.com/2007/04/09/web-and-desktop-apps-the-3rd-world-war/" rel="bookmark" title="Permanent Link: Web and Desktop Apps &#8211; the 3rd World War!">Web and Desktop Apps &#8211; the 3rd World War!</a></li><li><a href="http://techtracer.com/2007/03/15/scdjws-preparation-a-kick-start-guide/" rel="bookmark" title="Permanent Link: SCDJWS preparation &#8211; a kick start guide">SCDJWS preparation &#8211; a kick start guide</a></li><li><a href="http://techtracer.com/2007/03/17/scdjws-study-material-and-resources-the-most-searched-thing/" rel="bookmark" title="Permanent Link: SCDJWS study material and resources &#8211; The most searched thing">SCDJWS study material and resources &#8211; The most searched thing</a></li><li><a href="http://techtracer.com/2007/08/19/working-with-jax-ws-in-jdk-16/" rel="bookmark" title="Permanent Link: Working With JAX-WS in JDK 1.6">Working With JAX-WS in JDK 1.6</a></li></ul><br /><a href="http://techtracer.com/">Techtracer.com</a> Copyright &copy; 2008<br /> ]]></content:encoded>
			<wfw:commentRss>http://techtracer.com/2007/04/01/json-web-services-the-xml-json-debate-further-ahead/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>BEA Aqualogic Data Services Platform &#8211; First Glimpse</title>
		<link>http://techtracer.com/2006/10/16/bea-aqualogic-data-services-platform-first-glimpse/</link>
		<comments>http://techtracer.com/2006/10/16/bea-aqualogic-data-services-platform-first-glimpse/#comments</comments>
		<pubDate>Mon, 16 Oct 2006 04:52:23 +0000</pubDate>
		<dc:creator>nitinpai</dc:creator>
				<category><![CDATA[Web Services]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://techtracer.com/?p=270</guid>
		<description><![CDATA[Working on the BEA Aqualogic Data Services Platform 2.5 (AL-DSP) over the BEA Weblogic 8.1 has widened my imagination of web technology to even more higher levels. It has given me a confidence that I can now say the future of the newly emerging technologies is simply unimaginable. In the earlier few months of this [...]]]></description>
			<content:encoded><![CDATA[<p align="justify">Working on the <a href="http://www.bea.com/framework.jsp?CNT=index.htm&amp;FP=/content/products/aqualogic/data_services/">BEA Aqualogic Data Services Platform 2.5</a> (AL-DSP) over the <a href="http://dev2dev.bea.com/devoffering/index.jsp">BEA Weblogic 8.1</a> has widened my imagination of web technology to even more higher levels. It has given me a confidence that I can now say the future of the newly emerging technologies is simply unimaginable. In the earlier few months of this year I was working on <a href="http://java.sun.com/webservices/jaxb/">JAXB</a> which was a one of a kind object oriented XML parser provided in the <a href="http://java.sun.com/webservices/downloads/webservicespack.html">JWSDP 2.0</a> J2EE web services packages by Sun Microsystems. It made me aware how to go about working with <strong>XML</strong>, <strong>XSD</strong> and some amount of <strong>XPATH</strong>.</p>
<p align="justify">BEA AL-DSP 2.5 takes it more further ahead by leaps and bounds utilising all the power of XML communication and combines the usage of <a href="http://en.wikipedia.org/wiki/Xml">XML</a>, <a href="http://en.wikipedia.org/wiki/xsd">XSD</a>, <a href="http://en.wikipedia.org/wiki/Xpath">XPATH</a> and <a href="http://en.wikipedia.org/wiki/Xquery">XQUERY</a> to give a complete package which can be used as a whole new kind of abstraction layer which can amalgamate data from different kind of data sources. The data sources which can be used to collect data in DSP is currently from <strong>JDBC sources</strong>, <strong>Web services</strong>, <strong>JAVA functions</strong>, <strong>XML data</strong> and <strong>Delimited (<a href="http://en.wikipedia.org/wiki/Comma-separated_values">CSV</a>) formatted data</strong>.</p>
<p>A layer of DSP site above the underlying different physical sources and all the developer needs to do is to configure all the different sources into the DSP Workshop IDE and then define the unified data which he wants to retrive and then create functions by which the required elements have to be mapped to the underlying elements. DSP does the complex job of validation, authentication upto the element level and gives a collective unified data which further can provide in the form of plain XML or in the form of web service. The knowledge of XQuery is required in case you want to customize the data returned. Although I have not been able to get the submit function of web service created from the data services working making a read only web service is the game of a single right click !!!</p>
<p>DSP even provides some <strong>remarkable features of modelling</strong> of the data coming from different sources, generating <strong>crystal reports </strong>with graphical representation and even direct transfer of data to the <a href="http://www.bea.com/framework.jsp?CNT=index.htm&amp;FP=/content/products/aqualogic/service_bus/">BEA Aqualogic Service Bus 2.5</a> which is an ESB for routing mechanisms. Working with DSP has opened my eyes to a whole new world of information transfer. Gone are the days when I needed to create a JDBC connection and code for the data retrieval process. This is surely fun and extremely fruitfull for a large application having distributed and different data resources.</p>
<h2>Related posts:</h2><ul><li><a href="http://techtracer.com/2008/05/11/bea-dev2dev-techdays-an-experience/" rel="bookmark" title="Permanent Link: BEA Dev2Dev TechDays &#8211; An Experience">BEA Dev2Dev TechDays &#8211; An Experience</a></li><li><a href="http://techtracer.com/2008/01/23/effects-of-oracle-bea-acquisition/" rel="bookmark" title="Permanent Link: Effects of Oracle BEA Acquisition">Effects of Oracle BEA Acquisition</a></li><li><a href="http://techtracer.com/author/" rel="bookmark" title="Permanent Link: Author">Author</a></li><li><a href="http://techtracer.com/2007/04/01/json-web-services-the-xml-json-debate-further-ahead/" rel="bookmark" title="Permanent Link: JSON Web Services &#8211; the XML JSON debate further ahead">JSON Web Services &#8211; the XML JSON debate further ahead</a></li><li><a href="http://techtracer.com/2007/03/15/scdjws-preparation-a-kick-start-guide/" rel="bookmark" title="Permanent Link: SCDJWS preparation &#8211; a kick start guide">SCDJWS preparation &#8211; a kick start guide</a></li></ul><br /><a href="http://techtracer.com/">Techtracer.com</a> Copyright &copy; 2008<br /> ]]></content:encoded>
			<wfw:commentRss>http://techtracer.com/2006/10/16/bea-aqualogic-data-services-platform-first-glimpse/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

