<?xml version="1.0" encoding="utf-8"?>
<feed version="0.3" xmlns="http://purl.org/atom/ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xml:lang="en">
<title>Rama Pulavarthi&apos;s Blog</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/" />
<modified>2008-05-15T22:27:12Z</modified>
<tagline></tagline>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325</id>
<generator url="http://www.movabletype.org/" version="3.01D">Movable Type</generator>
<copyright>Copyright (c) 2008, ramapulavarthi</copyright>
<entry>
<title>Hudson@JavaOne</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/05/hudsonjavaone_1.html" />
<modified>2008-05-15T22:27:12Z</modified>
<issued>2008-05-15T22:24:54Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9817</id>
<created>2008-05-15T22:24:54Z</created>
<summary type="text/plain">Kohsuke and I talked about &quot;Improving the Engineering Process Through Automation by Hudson&quot; at JavaOne last week. </summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>

<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>Kohsuke and I talked about "<a href="http://www28.cplan.com/sb191/session_details.jsp?isid=296547&ilocation_id=191-1&ilanguage=english">Improving the Engineering Process Through Automation by Hudson</a>" at JavaOne last week. Kohsuke talked about Continous Integration, best practices with larger deployments of Hudson and extensibility features in Hudson. I showed the demo of some of the features of Hudson.
</p><p>
The demo has two parts. In the first part, the focus was on the ease of installation and using Hudson.
We showed that Hudson can be installed by doing "java -jar hudson.war" and it needs no container setup 
or database configuration to get started. Later showed the WEB UI for manging hudson and creating new jobs.
The configuration in Hudson is very intuitive with inline help for all the configuration parameters and on the fly error checking.
This is very handy where we don't have to wait until the build fails to realize its because of a silly typo.
</p><p>
First, I created a "<a href="http://hudson.gotdns.com/wiki/display/HUDSON/Building+a+software+project">FreeStyle Job</a>" which checks out sources from a subversion repository and runs ant to build the project and run some tests.
Later configured the job to archive the artifacts generated by that project and report Javadoc and Junit results. The Junit reporting feature in Hudson is very nice that it gives additinal information than it is there in your Junit reports. It offers easier navigation to reports of tests across different builds and keeps track of the age of test failures and plots trends with various builds etc.
</p><p>
Configuring the build to run periodically is very easy with hudson. It uses Cron-like syntax to set it to run whenever you want it. It can also monitor the SCM changes so that it can run automatically when ever somebody makes change to the sources instead of running periodically. This was shown in the demo by configuring to poll the subversion every minute for changes. I set up a mail server on my macbook to show that Hudson can send email notifications of the build status. 
</p><p>
Later, I showed the newly introduced <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Building+a+maven2+project">Maven2 project</a>. Hudson has nice integration with Maven2 where it parses the POMs in your project and monitors the goals you run to execute some routine housekeeping you do with normal hudson job. For example, when you run "test" phase , it automatically records the Junit Reports and archives the artifacts. With this Maven2 Project feature, you need to do very little configuration to setup the job like hooking up the sources and invoking Maven to execute some goals.
</p><p>
In the second part, We showed the <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Distributed+builds">distributed build setup</a> and <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Building+a+matrix+project">Multi-Configuration</a> Job(Matrix job). Adding slaves to the Master Hudson requires running hudson slave agent on the slave computer. It is as easy as clicking a Java Web Start link from the slave computer thats being hooked up. 
Of course, you can use other mechanisms like SSH to run the slave agent on the slave computer. Later we showed creating Multi- Configuration Job where the project tests are run in different configurations. The Multi Configuration job can be very handy when you need to build something for different platforms or run tests with different configurations (like different containers, different JDKs, different databases etc.). You don't need to create a separate job for each configuration. Just create a Multiconfiguration job to instruct hudson to run in all the combinations of the parameters in parallel. Hudson not only runs the jobs in all the configurations in parallel but also aggregates the artifacts and reports from all the builds and shows in a nice matrix for easier comprehension. We did n't get enough time to show this feature completely in the session.
</p><p>
 
The response from the audience was great and they liked the features of Hudson and the value it brings in. I am planning to create some screencasts of these demos and some other useful features like build promotion and put it on Hudson wiki. 

Go get <a href="https://hudson.dev.java.net/">Hudson</a> and give it a try. Another important thing is that when you try Hudson, also look at the growing list of <a href="http://hudson.gotdns.com/wiki/display/HUDSON/Plugins">Hudson Plugins</a> to work with various build systems, SCMs, notification mechanisms etc that complement the common core features in Hudson.
</p>]]>

</content>
</entry>
<entry>
<title>JDK 6 Update 6 is out</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/04/jdk_6_update_6.html" />
<modified>2008-04-16T22:41:40Z</modified>
<issued>2008-04-16T22:41:26Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9552</id>
<created>2008-04-16T22:41:26Z</created>
<summary type="text/plain">JDK 6 Update 6 is available on java.sun.com and the news of JAX-WS users is that it has the fix for javac where there was an issue using classes in javax.xml.ws.wsaddressing package.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[You can find javac compilation issue with classes in javax.xml.ws.wsaddressing package in my previous blog "<a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/03/a_little_update.html">A little update for JAX-WS 2.1 users with JDK 6 Update 4 and Update 5</a>"

The corresponding bug <a href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6672868">6672868</a> is fixed in <a href="http://java.sun.com/javase/6/webnotes/ReleaseNotes.html">JDK 6 update 6</a>.
The fix should be available in Open JDK 6 as well.
So, you don't have to use the compiler switches or workarounds as mentioned in my previous blog to make it work :)
 ]]>

</content>
</entry>
<entry>
<title>Status of WS-Addressing and MTOM Interop scenarios at Plugfest</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/03/status_of_wsadd.html" />
<modified>2008-03-25T19:28:22Z</modified>
<issued>2008-03-25T19:28:15Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9420</id>
<created>2008-03-25T19:28:15Z</created>
<summary type="text/plain">I attended the Interop Plugfest at Microsoft campus from March 18th - 20th and tested the WS-Addressing, MTOM Interop scenarios. Overall, we got most of the interop issues resolved compared to the last plugfest. Read on for more  details.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>I attended the Interop Plugfest @Microsoft from March 18th - 20th. This was my first time at Plugfest and to Microsoft campus. You can find more about the Interop Plugfest <a href="http://mssoapinterop.org/ilab/">here</a>, where all the test scenarios and wsdls are published. It was good meeting people face to face and interact with people working on the same technologies. I was mostly testing the WS-Addressing and MTOM scenarios between Metro and .NET 3.5. 
</p>
<p>
You can find the last report from the Plugfest held in November 2007 from <a href="http://weblogs.java.net/blog/haroldcarr/archive/2007/11/metro_web_servi.html">Harold's blog</a>. Here is the status on WS-Addressing and MTOM scenarios.
</p>
<p>
<pre>
WS-Addressing
--------------------------------------------------------------
Metro -> Metro:
WS-Addressing CR SOAP 1.1:                24/24
WS-Addressing CR SOAP 1.2:                29/29
WS-Addressing Member Submission SOAP 1.1: 18/18
WS-Addressing Member Submission SOAP 1.2: 19/19

Metro -> .NET 3.5:
WS-Addressing CR SOAP 1.1:                22/23 (1143 failed)
WS-Addressing CR SOAP 1.2:                24/25 (1243 failed)
WS-Addressing Member Submission SOAP 1.1: 10/10
WS-Addressing Member Submission SOAP 1.2: 11/11

*** Test 1143 and Test1243 have been rerun with updated enpoints made 
available on separate ports have been tried and verified to work 
and the fix might be available in upcoming major release of WCF. 

.NET 3.5 -> Metro:
WS-Addressing CR SOAP 1.1:                24/25 (1152 failed)
WS-Addressing CR SOAP 1.2:                26/26 (1152 failed)
WS-Addressing Member Submission SOAP 1.1: 10/11 (1152 failed)
WS-Addressing Member Submission SOAP 1.2: 11/12 (1152 failed) 

*** Test 1152 is being investigated by Microsoft.

*** Test 1299 has been added to SOAP 1.2 endpoints and has been tested separately. 
This test is added to test wsa:Action based Dispatching.
This has been tested to work in all the scenarios. 
</pre>
<p>
<p><pre>
MTOM:
--------------------------------------------------------------
Scenarios:
Soap11MtomSignEncrypt        4  
Soap11MtomSignOnly           5 
Soap11MtomUtf16              5 
Soap11MtomUtf8               5  
Soap12MtomUtf8               5  
Soap12MtomUtf8Aug04          5  
Soap12MtomUtf8Security       5   
Soap12MtomUtf8SecurityAug04  4 

As you can see a decrease in number of tests, testEchoBinaryHeaderasString 
in Soap11MtomSignEncrypt and  Soap12MtomUtf8SecurityAug04 has been removed from the test suite
(as there is no standard way for encrypting a SOAP Header in WSS 1.0 unlike in WSS 1.1)

Metro -> Metro: 38/38
Metro -> .NET 3.5: 38/38
.NET 3.5 -> Metro: 38/38 

***There are some random failures when I run the tests 
repeatedly in WCF -> Metro scenario. Metro service throws an exception and is being investigated.
</pre>
</p>

<p>
As you can clearly see, there are very few failures in WS-Addressing and MTOM compared to the last Plugfest in November 2007 as we fixed some testcase issues and got some issues resolved by Microsoft. Its a good progress !!! 

Currently, There are no direct WS-Addressing 1.0 tests that use WS-Addressing 1.0 Metadata. WS-Addressing Metadata is being tested indirectly in some Security scenrios. Hopefully, some of these tests will be updated to use Metadata and that gives a way to test interoperability when we implement the Metadata specification.

</p>
<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS</a> &nbsp;
<a href="http://technorati.com/tag/projectmetro">Metro</a> &nbsp;
<a href="http://technorati.com/tag/wcf">WCF</a> &nbsp;
</p>]]>

</content>
</entry>
<entry>
<title>A little update for JAX-WS 2.1 users with JDK 6 Update 4 and Update 5.</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/03/a_little_update.html" />
<modified>2008-03-08T01:00:31Z</modified>
<issued>2008-03-08T01:00:26Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9333</id>
<created>2008-03-08T01:00:26Z</created>
<summary type="text/plain">If you see a compilation error that package javax.xml.ws.wsaddressing does not exist with JDK 6 U4 and U5, see this entry for workaround</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>Some issues on compiling using classes in javax.xml.ws.wsaddressing package have come to our attention (You can follow the <a href="http://forums.java.net/jive/thread.jspa?messageID=262951&#262951">thread</a> in the Metro User forum).
As you can see, javax.xml.ws.wsaddressing package along with the classes W3CEndpointReference and W3CEndpointReferenceBuilder are infact there in rt.jar. But javac complains package javax.xml.ws.wsaddressing does not exist. 
</p>
<p>
This is due to the fact that JAVA_HOME/lib/ct.sym was not updated with these new api. This problem is in the JDK 6 Update 4 and Update 5, should not effect you unless you are using W3CEndpointReference and W3CEndpointReferenceBuilder in your applications. We are actively 
working on providing a fix in future update release. In the mean while, you could use one of these following workarounds.
</p>
<p>
<ul>
<li>
 Use the compiler switch -XDignore.symbol.file=true (Note that this is undocumented option).
</li><li>
Put rt.jar explicitly in your claspath for javac
</li><li>
Remove ct.sym from JAVA_HOME/lib ( not recommended as it requires changes to your JDK installation)
</li></ul>
</p><p>
We will be very soon fixing this glitch. Thanks for your cooperation.
</p>]]>

</content>
</entry>
<entry>
<title>OpenJDK 6 now has JAX-WS 2.1 and JAXB 2.1</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/02/openjdk_6_now_h.html" />
<modified>2008-02-29T20:36:06Z</modified>
<issued>2008-02-29T20:35:46Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9295</id>
<created>2008-02-29T20:35:46Z</created>
<summary type="text/plain">OpenJDK 6 b06 is live now. The important update from b05 is that JAX-WS 2.1.1 with JAXB 2.1.6 is integrated in to OpenJDK 6 b06. So, All the JAX-WS 2.1 features and bug fixes that are in JDK 6 Update 4 Release are available in OpenJDK 6 b06. Read more ...</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>

<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>As you know, Earlier we updated JAX-WS implementation in JDK 6U4 with JAX-WS 2.1 along with JAXB 2.1, you can find more details about that <a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/01/jaxws_21_and_ja.html">here</a>. As blogged earlier, We were also working on updating the JAX-WS in OpenJDK 6. Finally, its done.
</p><p>
JAX-WS 2.1.1 with JAXB 2.1.6 is integrated in to OpenJDK 6 b06. So, All the JAX-WS 2.1 features and bug fixes that are in JDK 6 Update 4 Release are available in b06. All the JAX-WS and JAXB components reside in jax-ws repository of the <a href="http://blogs.sun.com/kto/entry/openjdk_mercurial_forest">OpenJDK Mercurial forest</a>. All the JAX-WS sources are released under the <a href="http://openjdk.java.net/legal/gplv2+ce.html">GNU General Public License Version 2 (GPLv2)</a>. You can download the OpenJDK 6 <a href="http://download.java.net/openjdk/jdk6/">source bundle</a> and build it yourself. For that you need to first download the binary plug (components that are not available under open source license are avaiable under the  <a href="http://openjdk.java.net/legal/binary-license-2007-08-02.html">Binary License</a>) as described <a href="http://download.java.net/openjdk/jdk6/">here</a>. Subscribe to jdk6-dev@openjdk.java.net for technical discussions related to Open JDK 6.
</p><p>
Once OpenJDK 7 starts accepting checkins, we plan to update JAX-WS in OpenJDK 7 as well. Stay tuned. 
</p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS</a> &nbsp;
<a href="http://technorati.com/tag/projectmetro">Metro</a> &nbsp;
<a href="http://technorati.com/tag/openjdk">openjdk</a> &nbsp;
<a href="http://technorati.com/tag/jdk">JDK</a>
</p>]]>

</content>
</entry>
<entry>
<title>A Tip on Using JAX-WS with Maven</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/01/using_jaxws_wit.html" />
<modified>2008-01-18T23:08:43Z</modified>
<issued>2008-01-18T23:08:30Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.9022</id>
<created>2008-01-18T23:08:30Z</created>
<summary type="text/plain">A tip on using Maven with JAX-WS is available as part of this month&apos;s Enterprise Java Technologies Tech Tips. In this tip, I talk about using JAX-WS Maven plugin to build Web Services and deploy on to GlassFish with NetBeans 6.0.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>A tip on <a href="http://java.sun.com/mailers/techtips/enterprise/2008/TechTips_Jan08.html#1">Using Maven with JAX-WS</a> is available as Enterprise Java Technologies Tech Tips. You can find more Enterprise Java Technical Tips that are posted every month <a href="http://java.sun.com/developer/EJTechTips/index.html">here</a>. In this tip, I talk about using JAX-WS Maven plugin to build Web Services.
</p>
<p>
The JAX-WS Maven Plugin is developed as part of the <a href="https://jax-ws-commons.dev.java.net/">jax-ws-commons</a> project, where useful plugins and extensions around the JAX-WS RI are collected. This tip explores the JAX-WS maven plugin's two goals <a href="https://jax-ws-commons.dev.java.net/jaxws-maven-plugin/wsimport-mojo.html">wsimport</a> and <a href="https://jax-ws-commons.dev.java.net/jaxws-maven-plugin/wsgen-mojo.html">wsgen</a> and shows it with a simple sample. In this tip, I used NetBeans 6.0 to walk through the programming model for Web Services development using Maven. Netbean 6.0 has good support for Maven making it easy for developing web applications and deploying on to GlassFish server with a few mouse clicks.</p>
<p> 
Though NetBeans 6.0 has good support for Maven, it does n't support Web Services development using Maven directly. I heard NetBeans guys are working on improving the support in this area so that you can get Maven based Web Services project instead of ant based Web Services project. Then some of the configuration steps explained in the tip will not be necessary. I am eagerly waiting for it. 
</p>
<p>
If you are a command-line person, I plan to post a similar tip on using Maven CLI to build Web Services using JAX-WS maven plugin and deploy on to a container using Cargo Plugin. If you have any questions on using the plugin, please post them to users@metro.dev.java.net
</p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS</a> &nbsp;
<a href="http://technorati.com/tag/projectmetro">Metro</a> &nbsp;
<a href="http://technorati.com/tag/maven">Maven</a> &nbsp;
<a href="http://technorati.com/tag/glassfish">GlassFish</a> &nbsp;
<a href="http://technorati.com/tag/netbeans">NetBeans</a> &nbsp;]]>

</content>
</entry>
<entry>
<title>JAX-WS 2.1 and JAXB 2.1 is available in JDK 6 Update 4 release</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2008/01/jaxws_21_and_ja.html" />
<modified>2008-01-12T01:02:23Z</modified>
<issued>2008-01-12T01:02:09Z</issued>
<id>tag:weblogs.java.net,2008:/blog/ramapulavarthi/325.8975</id>
<created>2008-01-12T01:02:09Z</created>
<summary type="text/plain">Good News for all the JAX-WS users !!!
The long awaited inclusion of JAX-WS 2.1 and JAXB 2.1 implementations in JDK 6 has happened and is available in JDK 6 Update 4 release. This blog covers the state of JAX-WS/JAXB in JDK 6 and what it means to you as JAX-WS user.
</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>Finally, JDK6 Update 4 release, which has JAX-WS 2.1 and JAXB 2.1 implementation is out and available here.
</p><p>
<strong>What it means to you as a user:</strong><br>

You can use JAX-WS 2.1 (Metro 1.1) very smoothly on JDK 6 U4 and later.<br><br>

Earlier releases of JDK 6 have JAX-WS 2.0 and JAXB 2.0 implementations. After the release of JDK 6 FCS, JAX-WS RI has been re-architected to perform better (infact <a href="http://weblogs.java.net/blog/vivekp/archive/2007/02/jaxws_21_fcs_fa_1.html">a lot better</a>  ) and make it extensible for other technologies to be implemented using the core framework. Since the re-architecture and release of JAX-WS 2.1, JAX-WS user and developer community have been asking for the update of JAX-WS in JDK 6. Currently to use JAX-WS 2.1 on earlier JDK 6 releases, one has to use endorsed overide mechanism  as explained <a href="https://jax-ws.dev.java.net/nonav/2.1.3/docs/ReleaseNotes.html#Running_on_top_of_JDK_6">here</a> in detail. Using the endorsed mechanism, it has been little painful to use latest JAX-WS in applets and other scenarios. This has been the case for any evolving technology.   
</p><p>
  Since then, We have been planning to update JAX-WS in JDK 6 in Update release.  It is little unusual for a major component such as JAX-WS to update its version without revving up the Java Major version. After discussions and the approval process, JAX-WS 2.1 has been integrated and tested thoroughly. This has took longer than we expected for it to come out due to unforeseen circumustances. Finally, JAX-WS 2.1 along with JAXB 2.1 is integrated in JDK 6 Update 4 release and is available for <a href="http://java.sun.com/javase/downloads/index.jsp">download</a>. Rest assured, All your old web-services applications should work fine and may even perform better. JDK 6 U4 has bits based on JAX-WS 2.1.1 FCS and JAXB 2.1.1 FCS. The main change in JAX-WS API is the addition of API to support WS-Addressing 1.0. You can find the JAX-WS/JAXB changes and bug fixes that got into JDK 6 U4 here at <a href="https://jax-ws.dev.java.net/nonav/2.1.1/docs/changelog.html">JAX-WS change log</a> and <a href="https://jaxb.dev.java.net/nonav/2.1.1/docs/changelog2.html">JAXB change log</a>
</p>

<p>
  
You might also notice that OpenJDK6 still has JAX-WS 2.0. We are actively working on updating the bits in Open JDK as tracked on this <a href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6598886">bug report</a>.
</p><p>
If you want to use the latest releases of JAX-WS/JAXB for other bug fixes, you can use the latest releases of JAX-WS and JAXB by putting the JAX-WS/JAXB jars in the classpath like any other Java library. So with JDK6 U4, you don't need to use the endorsed mechanism. The latest release of JAX-WS 2.1.3 has these <a href="https://jax-ws.dev.java.net/nonav/2.1.3/docs/changelog.html">changes</a>  and JAXB 2.1.6 has these <a href="https://jaxb.dev.java.net/nonav/2.1.6/docs/changelog2.html">changes </a></p><p>
Also you might want to download <a href="https://metro.dev.java.net/1.1/">Metro 1.1</a>, which has JAX-WS 2.1.3 and Web Services Interoperability Technologies (WSIT) 1.1  that implements the WS-* specs and provides advanced Web Services support in terms of Quality of Service and Security. To use Metro 1.1 on JDK6 U4, you just have to put the Metro jars in the classpath. 
</p><p>
Life is getting better. Isn't it?
</p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS</a> &nbsp;
<a href="http://technorati.com/tag/projectmetro">Metro</a> &nbsp;
<a href="http://technorati.com/tag/glassfish">GlassFish</a> &nbsp;
<a href="http://technorati.com/tag/jdk">JDK</a>

]]>

</content>
</entry>
<entry>
<title>Installation problems with NetBeans 6.0 on Mac? Sharing the tip I learnt.</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/12/installation_pr.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-12-17T23:21:12Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.8853</id>
<created>2007-12-17T23:21:12Z</created>
<summary type="text/plain">If you have problem with installing NetBeans 6.0 on Mac, you might find this useful.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: NetBeans</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>
I have installed NetBean 6.0 RC2 earlier and wanted to update with NetBeans 6.0 lately.
My installation experience was not good and I had to open a thread on NetBeans User mailing list to know what is happening and get it finally working.
You can find the thread <a href="http://www.netbeans.org/servlets/ReadMsg?list=nbusers&msgNo=106185">here</a> 
</p>
<p>
I use mutiple versions of JDK as part of testing and I might have mistakenly removed some things that Netbeans instalaltion expects, that was causing the installation problems.
But the lack of proper error reporting made it really difficult to nail down the problem. All it says is something like "There is an error during installation, Please try installing again".
It needs lot of improvements in that aspect. But the good thing is the user forum is very responsive and gave me these tips to find out the issue.
</p> 
<p>
Incase you run into something like that. These steps will be helpful for uninstalling Netbeans on Mac as well.
<strong><ul>
<li>
Uninstall the partially installed NetBeans or Previous installation.
<ul>
<li>
 To unistall,. just right-click on /Applications/NetBeans in Finder and select  "Move to Trash".
</li>
<li> 
 Become super user and go to  /Library/Receipts and remove NetBeans*.pkg if there is any. (Also, remove openesb*.pkg, glassfish*.pkg and apache-tomcat*.pkg if available).
</li>
<li>
 Remove ~/.netbeans, (needed when Netbeans says the user directory is corrupted)</li>
</ul>
</li>
<li>
Check the installation log at  /var/log/install.log (/private/var/log/install.log) for any information.<br>
</li>
</ul></strong>
</p>
<p>
In mycase I had to problems, It could n't find /System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home/bin/unpack200 . I might have removed the sym link /System/Library/Frameworks/JavaVM.framework/Versions/1.5 pointing to /System/Library/Frameworks/JavaVM.framework/Versions/1.5.0. and hence the problem. After creating the sym link, I got it working. Without this, I also had to change netbeans.conf to point Netbeans to the right JDK.
I am not sure where Netbeans is picking /System/Library/Frameworks/JavaVM.framework/Versions/1.5/ up from.
</p>
<p>
But, Can't NetBeans use the /System/Library/Frameworks/JavaVM.framework/Versions/Current or /System/Library/Frameworks/JavaVM.framework/Versions/CurrentJDK as default JDK?
BTW, If you want to use a different version of JDK, you can modify<br> <strong>/Applications/NetBeans/NetBeans 6.0.app/Contents/Resources/NetBeans/etc/netbeans.conf </strong>and set the property <strong>"netbeans_jdkhome" </strong>to the JDK you want  or use <strong>--jdkhome </strong>at the start. NetBeans installation should prompt the User for the JDK to be used by NetBeans.  Also, at the minimal it should show the errors or point to the installation log incase of installation errors.
</p>
<p>
Thanks for all the guys who helped me resolve the problem.
</p>]]>

</content>
</entry>
<entry>
<title>Extend your Web Service applications with the new efficient Handlers in JAX-WS RI</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/12/extend_your_web.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-12-14T02:28:07Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.8830</id>
<created>2007-12-14T02:28:07Z</created>
<summary type="text/plain">Handlers provide a nice pluggable way to extend the Web Service Applications. But, standard handlers have some limitations. Since SOAPHandlers are DOM based, they can be performance overhead to your application. We introduced a new Handler called MessageHandler in JAX-WS RI, that fits in to the existing handler framework and provides efficient ways to access/process messages. Read on to know more ...</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[Ealier in my blog<big> "</big><a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2006/05/making_use_of_h.html">Understanding
Handlers in JAX-WS</a>", I talked about Handler
Framework in JAX-WS and showed some <a
 href="https://jax-ws.dev.java.net/articles/handlers_introduction.html">examples</a>
of using handlers to intercept the messages for additional processing
on the server and client. Overall, JAX-WS handlers provide good API to
abstract your application logic as a handler and plug it in easily with
any service. But the standard handlers have some limitations.
<a href="https://jax-ws.dev.java.net/nonav/2.1.1/docs/api/javax/xml/ws/handler/LogicalHandler.html">LogicalHandler</a> provides access to payload only and does n't provide
access to SOAP headers and binary data carried as attachments in the
SOAP Message and is more suited for XML/HTTP binding. Though
<a href="https://jax-ws.dev.java.net/nonav/2.1.1/docs/api/javax/xml/ws/handler/soap/SOAPHandler.html">SOAPHandler</a>s provide access to whole SOAP Message, it has performance
implications as SOAPMessage is based on DOM and tries to load the whole
message in memory. JAX-WS RI reads the message in Streaming fashion and
tries to read the information lazily to provide better performance. But
each time a SOAPHandler acceses the message, it is converted to DOM
based SOAP Message. This can hurt your application performance. Though
the SOAPHandlers have the performance limitation due to the above
mentioned reasons, The <a href="http://jcp.org/en/jsr/detail?id=224">JAX-WS
Specification</a> defined a pretty extensible framework, so that
other types of&nbsp;protocol handlers can be plugged-in easily.<br>
<br>
JAX-WS&nbsp;RI has been fine tuned to perform better and better.
JAX-WS RI defines Message abstraction thats hides the actual data
representation either the message be constructed from a JAXB object or
InputStream of a HttpConnection. The <a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/com/sun/xml/ws/api/message/Message.html">Message</a>  API provides various ways to access the payload and
implementations can implement those methods in the best possible way.
JAX-WS Runtime chooses the right Message representation when it is
constructing a new message. It also provides some commonly used
implementations of Message (like JAXBMessage, DOMMessage, SAAJ Message,
ProtocolSourceMessage etc). Each kind of Message has particular
characteristic and is more useful or suited depending on the situation.
Along with it, RI also provides some static factory methods to easily
create messages with the <a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/com/sun/xml/ws/api/message/Messages.html">Messages</a> API. Using these one can easily access/create messages
irrespective of the actual data representation. More about the API can
be found in the <a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/?jaxws/package-summary.html">JAX-WS
architecture document</a>.<br>
<br>
<span style="font-weight: bold;">MessageHandler:</span><br>
Utilizing the extensible Handler framework provided by JAX-WS
Specification and the better Message abstraction in RI, We introduced a
new handler&nbsp;called <a
 href="http://fisheye5.cenqua.com/browse/jax-ws-sources/jaxws-ri/rt/src/com/sun/xml/ws/api/handler/MessageHandlerContext.java">MessageHandler</a>
to extend your Web Service
applications. MessageHandler is similar to SOAPHandler, except that
implementations of it gets access to <a
 href="http://fisheye5.cenqua.com/browse/jax-ws-sources/jaxws-ri/rt/src/com/sun/xml/ws/api/handler/MessageHandlerContext.java">MessageHandlerContext</a>
(an
extension of MessageContext).&nbsp; Through MessageHandlerContext
one can
access the Message and process it using the Message API. As I put in
the title of the blog, this handler lets you work on Message, which
provides efficient ways to access/process the message not just a DOM
based message. The
programming model of the handlers is same and the Message handlers can
be mixed with standard Logical and SOAP handlers. I have added a <a href="http://fisheye5.cenqua.com/browse/jax-ws-sources/jaxws-ri/samples/efficient_handler">sample</a>
in JAX-WS RI 2.1.3 showing the use of MessageHandler to log messages
and here is a snippet from the sample.<br>
<pre>
public class LoggingHandler implements MessageHandler&lt;MessageHandlerContext> {
    public boolean handleMessage(MessageHandlerContext mhc) {
        Message m = mhc.getMessage().copy();
        XMLStreamWriter writer = XMLStreamWriterFactory.create(System.out);
        try {
            m.writeTo(writer);
        } catch (XMLStreamException e) {
            e.printStackTrace();
            return false;
        }
        return true;
    }

    public boolean handleFault(MessageHandlerContext mhc) {
        ..... 
        return true;
    }
    
    public void close(MessageContext messageContext) {    }
   
    public Set<QName> getHeaders() {
        return null;
    }
}
</pre>
<br>
<span style="font-weight: bold;">MessageHandler
as&nbsp;light weight Tube:<br>
</span>JAX-WS&nbsp;RI also provides pugglable framework for
JAX-WS extensions to process the messages represented as <a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/com/sun/xml/ws/api/message/Packet.html">Packet</a>s
through <a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/com/sun/xml/ws/api/pipe/Tube.html">Tube</a>s.
Packets are just a containers for Message and hold
additional Metadata properties relating to the message. Tubes are like
filters that work on the packet. Most of the WS-* spec imlementations
are done as Tube/Pipe implementation&nbsp;in WSIT. Tubes are very
convenient and targeted for developers where in the extensions
providing Tube implementation adhere to the Tube API to dotheir part of
processing in a bigger chain. But for your Tube to be recognized by the
JAX-WS Runtime, you need to plugin your Tube in a TubelineAssembler and
make it available to the RI runtime. I talked more about extending
JAX-WS through annotations and Tubes <a
 href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/01/extending_jaxws.html">here</a>.<br>
<br>
Most of the work that can be done in Tubes can be done in a
MessageHandler, there by providing light-weight framework for the users
to take advantage of the Message abstraction and easy pluggability
without change to the already familiar in programming model. You don't
have to implement your TubelineAssembler to plug in your logic. Along
with the standard properties exposed by the Messagecontext,
MessageHandlerContext provides access to SEI Model, WSDL Model and
other information to the handler, so that the handler can almost do
what a tube can do. Infact you can implement the functionalioty
of&nbsp; MUHeaderTube ( a Tube that does SOAP MustUnderstand Header
processing) in a handler efficiently. One downside of implementing it
as a handler is that if you implement it as a Tube and extend
<a
 href="https://jax-ws-architecture-document.dev.java.net/nonav/doc21/com/sun/xml/ws/api/pipe/TubelineAssembler.html">TublineAssembler</a>,
you can make it available to all
applications&nbsp; and even to the existing applications with out
touching the code. But with handlers approach, you need to modify the
application a bit to configure handlers. <br>
<br>
I see advantanges to both ways of extensions to JAX-WS. Extending
JAX-WS as a Tube is mostly for developers enhancing the JAX-WS Runtime
to provide some extra functionality. MessageHandlers are easier to
develop handlers by the end users and are natural choice if your
applications are already using JAX-WS handler framework. <br>
<br>
Get the latest Metro 1.1 bits and give it a try.<br>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS</a> &nbsp;
<a href="http://technorati.com/tag/projectmetro">Metro</a> &nbsp;
<a href="http://technorati.com/tag/glassfish">GlassFish</a> &nbsp;]]>

</content>
</entry>
<entry>
<title>Metro @ SiliconValley CodeCamp 2007</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/10/metro_siliconva.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-10-31T08:41:30Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.8527</id>
<created>2007-10-31T08:41:30Z</created>
<summary type="text/plain">Arun and I presented on Metro at SiliconValley CodeCamp this weekend held at FootHills College. Here are are the links to the slides, demo and some photos I have taken.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>I attended the <a href="http://siliconvalley-codecamp.com/">SiliconValley CodeCamp</a> at FootHill College, Los Altos this weekend. This is a free conference by developers for developers in a beautiful location.
Overall, good number of people attended the conference. I liked the conference as it is light weight and free. Another interesting thing is that there were sessions covering topics on .NET,  Java and Web 2.0 technologies. My wife is a .NET developer and me being a Java developer, It was good that we both could attend and participate in our areas of interest. 
</p><p>
I and <a href="http://blogs.sun.com/arungupta">Arun</a> presented about Metro in Glassfish at SiliconValey CodeCamp this saturday on Metro.  We had some glitches with the projector during our presentation, but the spirit of the audience helped us continue with the presentation and it went well later on. Some of the audience are very familiar with JAX-WS and are trying JAX-WS 2.1.3 as well :). </p>
<table>
<tr>
<td>
<img alt="Rama_SiliconValleyCodeCamp2007.jpg" src="http://weblogs.java.net/blog/ramapulavarthi/archive/svcc2007/Rama_SiliconValleyCodeCamp2007.jpg" width="448" height="328" />
</td>
<td><p>
Here is a photo showing me in action at SiliconValley CodeCamp(Thanks Arun for taking the photo).</p>
</td>
</tr>
<table>
<p>
The slides are available <a href="http://weblogs.java.net/blog/arungupta/archive/metro-svcc07.pdf">here</a> . The demos <a href="http://blogs.sun.com/arungupta/entry/excel_using_wsit_javaone_2007">Using EXCEL with WSIT</a>, <a href="http://blogs.sun.com/arungupta/entry/screencast_ws1_web_services_development">Web services development using NetBeans IDE and GlassFish</a> and other screencasts are available <a href="https://metro.dev.java.net/discover/screencasts.html">here</a>.
</p>
<p>
<table>
<tr>
<td>
<p>Here is a photo with the  Silicon Valley JUG leaders Aaron Houston , Van Riper, Kevin Nelson chatting about the sessions and JUGs. 
</p></td>
<td>
<img alt="Rama_JUG.JPG" src="http://weblogs.java.net/blog/ramapulavarthi/archive/svcc2007/Rama_JUG.JPG" width="448" height="293" />
</td>
<tr>
<table>
</p>
<p>
<a href="http://javaposse.com/">
Java Posse</a> had a live recording of their podcast covering the weekly happenings and issues centered on Java. It was nice to watch the four guys expressing their views on various topics and Listening to their podcast is like a quick recap of the news around Java. This week it was mainly on Apple not including Java SE 6 in Mac OS 10.5 Leopard, Mozilla's Prism to run Web Applications outside of browser, the rumor that Java ME is dead, and Google Collection API and others. </p>
<table><tr>
<td>
<img alt="Rama_JavaPosse.JPG" src="http://weblogs.java.net/blog/ramapulavarthi/archive/svcc2007/Rama_JavaPosse.JPG" width="448" height="295" />
</td>
<td>
<p>Here is a photo of me with Java Posse guys [Tor Norbye (Sun Microsystems), Carl Quinn (Google), Dick Wall (Google) and Joe Nuxoll (Apple)]. I liked the session and seeing them in live with their funny hats on.</p> 
</td>
</tr>
</table>
</p>
<p>
I will be waiting for the next SiliconValley CodeCamp.
</p>

<p>
Technorati:
<a href="http://technorati.com/tag/siliconvalleycodecamp">siliconvalleycodecamp</a>
<a href="http://technorati.com/tag/projectmetro">metro</a>
<a href="http://technorati.com/tag/glassfish">glassfish</a>
<a href="http://technorati.com/tag/webservices">webservices</a>
<a href="http://technorati.com/tag/netbeans">netbeans</a>
<p>]]>

</content>
</entry>
<entry>
<title>JAX-WS 2.1 in Java SE 6 Update N</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/10/jaxws_21_in_jav.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-10-04T05:25:02Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.8369</id>
<created>2007-10-04T05:25:02Z</created>
<summary type="text/plain">Along with new features and enhancements, Java SE 6 Update N (formerly known as the &quot;Consumer JRE&quot;) has high performance Web Services support with JAX-WS 2.1. </summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>Java SE 6 Update N (formerly know as the "Consumer JRE" project) is an update release that introduces new features and enhancements aimed at providing an optimized consumer end user experience.
Along with the features and enhancements listed <a href="https://jdk6.dev.java.net/6uNea.html#Overview">here</a>, it also brings in JAX-WS 2.1. This is just an early access release and some other enhancements may trickle in as it goes final.
</p>

<p>
As you all know JAX-WS 2.1 is re-architected implementation of JAX-WS 2.0 RI that has lot of performance improvements.
Currently to reap the benefits of the JAX-WS improvements, using it on JDK 6 is little tricky. To use JAX-WS 2.1, You need use the endorsed override mechanism by placing jaxws-api.jar and jaxb-api.jar in JAVA_HOME/jre/lib/endorsed.
More about using JAX-WS 2.1 on JDK 6 has been described <a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/01/problems_using.html">here</a> earlier. JAX-WS 2.0 is part of JDK 6 and I can say that recently released <a href="http://java.sun.com/javase/6/">JDK 6 Update 3 </a>will be the last Java SE 6 release using JAX-WS 2.0.
</p><p>
A good news for you all, JAX-WS 2.1.1 RI FCS is being integrated to the future Update Releases. Yay, no more endorsed mechanism to use JAX-WS 2.1.
An early access build of <a href="http://download.java.net/jdk6/"> Java SE 6 Update 5 Release </a> is available for you to try.</p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS </a><br>
<a href="http://technorati.com/tag/JDK">JDK</a><br>]]>

</content>
</entry>
<entry>
<title>Web Services Addressing 1.0 - Metadata is now a W3C Recommendation.</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/09/web_services_ad.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-09-06T17:53:35Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.8189</id>
<created>2007-09-06T17:53:35Z</created>
<summary type="text/plain">Web Services Addressing 1.0 - Metadata specification is now a W3C Recommendation. It defines how to express abstract properties defined in the Addressing 1.0 core specification and uses WS-Policy 1.5 to express conformance to Web Services Addressing 1.0 specification. </summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>Good News Everyone !!! 
<p>
<a href="http://www.w3.org/TR/2007/REC-ws-addr-metadata-20070904/">Web Services Addressing 1.0 Metadata</a> specification produced by Web Services Addressing Working Group is now a W3C recommendation. This Metadata specification defines standard way to express the abstract properties of Web Services Addressing 1.0 core in WSDL and to express support and conformance  to Web Services Addressing 1.0 in the wsdl. It also defines how WSDL Metadata is included in an Endpoint Reference (EPR).
<p>
This WS-Addressing Metadata specification replaces the previous <a href="http://www.w3.org/TR/2006/CR-ws-addr-wsdl-20060529/">Web Services Addressing 1.0 - WSDL Binding</a> specification in candidate recommendation earlier. The main difference is in the way support for Addressing is expressed in wsdl and of course the namespace (change from wsaw:http://www.w3.org/2006/02/addressing/wsdl to wsam:http://www.w3.org/2007/05/addressing/metadata). In WSDL Binding specification, an WSDL extensibility element &lt;wsaw:UsingAddressing> was used. This Metadata specification uses Web Services Policy Framework (<a href="http://www.w3.org/TR/2007/REC-ws-policy-20070904">WS Policy 1.5</a>) and Web Services Policy - Attachment [<a href="http://www.w3.org/TR/2007/REC-ws-policy-attach-20070904">WS Policy 1.5 - Attachment</a>] specifications to express the support of Web Services Addressing 1.0. A new policy assertion &lt;wsam:Addressing> is defined to express it.
<p>
<strong>New policy Assertions:</strong>
<p>
When <strong>&lt;wsam:Addressing></strong> is present in a Policy alternative, one is required to use WS-Addressing to communicate with the subject.
</p><p>
<strong>&lt;wsam:Addressing wsp:Optional="true"></strong> can be used to indicate support for WS-Addressing but does not require the use of it.
In these cases, there are no restrictions about the use of WS-Adressing.
</p><p>
Nested asertions can be used to restrict the use of WS-Addressing inside the &lt;wsam:Addressing> assertion.
<pre>For example,
&lt;wsam:Addressing>
    &lt;wsp:Policy>
        <strong>&lt;wsam:NonAnonymousResponses/></strong>
    &lt;/wsp:Policy>
&lt;/wsam:Addressing></pre><p>
can be used to indicate that the subject requires WS-Addressing and requires the use of non-anonymous response EPRs   
</p>
<p><pre>
&lt;wsam:Addressing>
    &lt;wsp:Policy>
        <strong>&lt;wsam:AnonymousResponses/></strong>
    &lt;/wsp:Policy>
&lt;/wsam:Addressing> </pre><p>
can be used to indicate that the subject requires WS-Addressing and requires the use of anonymous responses.
</p>
<p>
I discussed briefly in my earlier blog about including WSDL Metadata in EPR. In a future blog, I will write about how abstract Addressing properties like action and reference parameters are descibed in WSDL.
<p>
As you know, JAX-WS 2.1 did not define WSDL binding for WS-Addressing as things were in flux during the release of 2.1 specification. Now that Metadata specification is final, JAX-WS can use these standard policy assertions and description of abstract addressing properties in wsdl.
<p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS </a><br>
<a href="http://technorati.com/tag/WSAddressing">WS-Addressing</a><br>]]>

</content>
</entry>
<entry>
<title>Running JAX-WS Samples with Tomcat 6.x</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/07/running_jaxws_s.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-07-21T00:48:46Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.7898</id>
<created>2007-07-21T00:48:46Z</created>
<summary type="text/plain">Tip for running JAX-WS RI Samples with Tomcat 6.0</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>I tried to run JAX-WS samples with Tomcat 6.0 and stumbled with the classloading problem. After reading the docs, I figured it out and thought of sharing this to all.
</p>
<p>
The <a href="https://jax-ws.dev.java.net/nonav/2.1.2m1/docs/samples.html">JAX-WS Samples documentation</a> describes steps for running samples with Glassfish and Tomcat 5.x. 
It suggests you to copy all web services jars to $CATALINA_HOME/shared/lib when running with Tomcat, so that these libraries can be available to all Web applications.
</p>
<p>
When you are running with Tomcat 6.x, the classloading mechanism has changed a bit from earlier versions of Tomcat.
You can notice there is no common, server, shared directories in the Tomcat installation. All you see is the lib directory.
It seems this is done to avoid confusion for the users. You can find more details about the Tomcat 6.0 classloading <a href="http://tomcat.apache.org/tomcat-6.0-doc/class-loader-howto.html">here</a> 
</p>
<p>
To run the samples with Tomcat 6 follow these steps.
Edit $CATALINA_HOME/conf/catalina.properties and set shared.loader={RI Installation Directory}/lib/*.jar
If you are running multiple instances of Tomcat, then edit CATALINA_BASE/conf/catalina.properties for that particular instance.
The same technique can be used with Tomcat 5.x if you don't like to copy all the jars to $CATALINA_HOME/shared/lib
</p>
<p>
For the complete steps for running the samples, follow as instructions listed in the <a href="https://jax-ws.dev.java.net/nonav/2.1.2m1/docs/samples.html">samples document</a>. 
</p>

<p>Technorati: <br>
<a href="http://technorati.com/tag/jaxws">JAX-WS Samples</a><br>
<a href="http://technorati.com/tag/jaxws">Tomcat</a><br>]]>

</content>
</entry>
<entry>
<title>Sun&apos;s participation in Web Services Addressing 1.0 - Metadata Interop Testing</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/06/suns_participat_1.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-06-29T20:38:54Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.7770</id>
<created>2007-06-29T20:38:54Z</created>
<summary type="text/plain">Sun has participated with IBM in interop testing of section 2.1 of Web Services Addressing 1.0 - Metadata specification which has recently been requested for transition to Candidate Recommendation. Section 2.1 deals with Referencing WSDL Metadata from an EPR and Sun has passed all the tests related to this feature. </summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>The Web Services Addressing Working Group has <a href="http://lists.w3.org/Archives/Public/public-ws-addressing/2007Jun/0019.html">requested to transition</a> the second <a href="http://www.w3.org/TR/2007/WD-ws-addr-metadata-20070516/">Last Call Working Draft</a> of Web Services Addressing 1.0 - Metadata ( which addressed the issues received during the previous Last Call phase relating WS-Policy assertions from WS-Policy wokring group). Section 2.1 Referencing WSDL Metadata from an EPR and section 2.2 Embedding WSDL Metadata in an EPR are marked as risk requiring two interoperable implementations for those features. All the features in the specification except the sections marked at risk were tested for interoperability previuosly.</p>

<p>I am pleased to participate in the interop testing of <a href="http://www.w3.org/TR/2007/WD-ws-addr-metadata-20070516/#refmetadatfromepr">section 2.1</a> in Metadata Specification with IBM. The <a href="http://lists.w3.org/Archives/Public/public-ws-addressing/2007Jun/0011.html">test plan</a> for this feature has been approved by the WG in the last call. Though Sun's implementation of WS Addressing does n't support complete Metadata specification now, it has partial implementation to support EPR's conforming to Metadata specification. Sun has <a href="http://lists.w3.org/Archives/Public/public-ws-addressing/2007Jun/0021.html">passed</a> all the mandatory as well as optional tests related to this feature. I was pleased to work with David Illsley from IBM in the interop testing from Sun's side. Hopefuly these results will be approved by the WG and then section 2.1 will stay during the transtion from CR to PR phase. </p>

<p>A brief look at how this feature can be helpful when using EPRs to reference Web Services. In JAX-WS you can create proxy from an EPR if the runtime can get all the binding related information from the EPR. This enables the EndpointReference.getPort(SEI) API in JAX-WS to work, as it can get the wsdl metadata from EPR, which can be really useful when dealing with Stateful Web Services feature utilizing addressing headers and EPRS in the background.</p>

<p>If these results are approved by the WSA WG, Section 2.1 is going to stay in PR. Though the plans for full support for WS Addressing Metadata in JAX-WS RI are not concrete yet, this will be available in the near future. I will explain how to reference wsdl metadata in an EPR in a follow up blog.</p>

<p>Technorati: <br />
<a href="http://technorati.com/tag/jaxws">JAX-WS</a><br />
<a href="http://technorati.com/tag/WSAddressing" rel="tag">WSAddressing</a> </p>]]>

</content>
</entry>
<entry>
<title>Useful Goodies for Web Service Developers in JAX-WS 2.1 RI</title>
<link rel="alternate" type="text/html" href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/02/useful_goodies.html" />
<modified>2008-06-24T19:17:03Z</modified>
<issued>2007-02-02T19:24:38Z</issued>
<id>tag:weblogs.java.net,2007:/blog/ramapulavarthi/325.6458</id>
<created>2007-02-02T19:24:38Z</created>
<summary type="text/plain">This blog talks about various features in JAXWS 2.1 RI that will be helpful in developing/debugging Web Services.</summary>
<author>
<name>ramapulavarthi</name>

<email>Rama.Pulavarthi@Sun.COM</email>
</author>
<dc:subject>Community: Java Web Services and XML</dc:subject>
<content type="text/html" mode="escaped" xml:lang="en" xml:base="http://weblogs.java.net/blog/ramapulavarthi/">
<![CDATA[<p>JAXWS 2.1 RI comes with bunch of goodies for the ease of use/development of Web Services. Some of these are configurable through system-wide properties, features and annotations in the com.sun.xml.ws.developer package, which means they are proprietary and will not work with other implementations. Who knows, some of these might end up in future versions of the Spec, if you find them useful as we think. 
</p>
<p>
<strong>Accessing Inbound SOAP Headers:</strong>
To access all the headers (including headers that are not bound to parameters) in the endpoint implementation, one has to write a handler to access those from the SOAPMessage. Instead on can use the read-only property JAXWSProperties.INBOUND_HEADER_LIST_PROPERTY from WebServiceContext directly.
</p><p>
<strong>Adding Outbound SOAP Headers:</strong>
Sometimes, one may need to send some additional headers that are not defined in the wsdl or bound to parameters. Instead of writing a SOAP Handler and doing the dirty work one can easily do this by downcasting the proxy to WSBindingProvider and set the Outbound headers.
</p><pre>
HelloPort port = helloService.getHelloPort();
WSBindingProvider bp = (WSBindingProvider)port;
bp.setOutboundHeaders(
  // simple string value as a header, like <simpleHeader>stringValue</simpleHeader>
  Headers.create(new QName("simpleHeader"),"stringValue"),
  // create a header from JAXB object
  Headers.create(jaxbContext,myJaxbObject)
);</pre>
<p>
As you see Headers are created using com.sun.xml.ws.api.message.Headers class, which provides factory methods to create headers in different wasy easily. More information on using this feature can found in Kohsuke's blog <a href="http://weblogs.java.net/blog/kohsuke/archive/2006/11/adding_soap_hea.html">Adding SOAP headers</a>
</p>
<p>
<strong>Creating Stateful Web Services:</strong>
<br><br><strong>Using @HttpSessionScope:</strong>
One way to bring state to Web Services is to use Http Session cookies. Storing the state and accessing it from the HttpSession (from WebServiceContext) for each request takes multiple steps and does n't fit well with the OO way of accessing/storing it with instance fields. 
One can use @com.sun.xml.ws.developer.servlet.HttpSessionScope annotation tells the JAX-WS RI to create one instance of Hello per each HTTP session. As you see this approach still relies on Http cookies but makes it easier to access state from the context just like normal instance variables.
</p><p>
<strong>Using @Stateful: </strong>
JAX-WS also provides a transport neutral mechanism to do this and makes use of the WS-Addressing standard. It introduces @com.sun.xml.ws.developer.Stateful to take care of maintaining all the state and the user can access it using instance variables. All the user needs to do is to add @Stateful and @Addressing to Web Service implementation. As you see, this is  requires support for Addressing.
<br>
More information about using this feature can be found from stateful sample in the JAX-WS 2.1 bundle and in Kohsuke blogs <a href="http://weblogs.java.net/blog/kohsuke/archive/2006/10/stateful_web_se.html">Stateful web services with JAX-WS RI</a>
 and <a href="http://weblogs.java.net/blog/kohsuke/archive/2006/10/bringing_state.html">HttpSessionscope</a>.
</p><p>
<strong>Logging of SOAP Messages:</strong>
Web Services developers generally need to see SOAP Messages that are transferred between client and service for debugging.  There are couple of SOAP Monitors for this job, but you need modify the client or server code to use those tools. JAX-WS provides logging of SOAP messages by using a System property com.sun.xml.ws.transport.http.client.HttpTransportPipe.dump=true on client-side. My blog  about <a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2006/08/monitoring_soap.html">Monitoring SOAP Messages </a> talks more about it. If you are using Glassfish, it provides nice GUI tools to montior SOAP messages for Web Service. Unfortunately this works only with 109 based Web Services. For Servlet based WebServices, you can use com.sun.xml.ws.transport.http.HttpAdapter.dump system property to dump the SOAP traffic.
</p><p>
<strong>Propagation of Server-side Stacktrace:</strong>
This is a very useful feature while developing Web Services. Often the soap fault messages does n't convey enough information about the problem. JAX-WS relieves you from digging out the server logs to find out the stacktrace. Now the whole stacktrace (including nested exceptions) is propagated in the SOAP Fault and the complete exception stacktrace is visible to the client. Propation of Stacktrace is on by default, If you think its not safe for your Web Service Application to send the complete stacktrace, you can turn off this functionality by setting the System property  com.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace.
</p><p>
<strong>Support for MemberSubmission Addressing:</strong>
One can use @com.sun.xml.ws.developer.MemberSubmissionAddressing or com.sun.xml.ws.developer.MemberSubmissionAddressingFeature to use member submission version of Addressing. You can follow the fromjava-wsaddressing sample in JAX-WS 2.1 bundle except that @MemberSubmissionAddressing and MemberSubmissionAddressingFeature is used instead if @Addressing and AddressingFeature.
</p>
<p>
Most interesting part, all of these features are done using extensions points provided by the JAXWS RI. You can develop similar features using JAXWS pluggability architecture and more on this can be found in my blog <a href="http://weblogs.java.net/blog/ramapulavarthi/archive/2007/01/extending_jaxws.html">Extending JAX-WS With Annotations</a>. </p><p>We hope these developer properties and features are useful and make using Web Services a bit easier. Do provide your valuable feedback to dev@jax-ws.dev.java.net</p>]]>

</content>
</entry>

</feed>