Arun Gupta, Miles to go ...

Arun Gupta is a technology enthusiast, a passionate runner, and a community guy who works for Sun Microsystems.
« Previous page | Main | Next page »

http://blogs.sun.com/arungupta/date/20060817 Thursday August 17, 2006

WSIT Milestone 1

WSIT Milestone 1 release has been available for few days now.

Follow 4 simple steps to download the binary release or build from the source and build a secure, reliable and interoperable Web service using the comprehensive tutorial. The samples range from simply adding the two numbers to a price quote service using secure, reliable and brokered trust pattern. All the samples can be installed on GlassFish or Tomcat.

Although the milestone binary does not interoperate with a publicly-available Windows Communication Foundation the current version of the sources does interoperate with the July CTP (runtime and SDK). A WSIT binary release that does interoperate with WCF will be available soon.

Your feedback is very appreciated.

Technorati: WSIT Web-services WCF Indigo GlassFish

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060807 Monday August 07, 2006

JavaOne 2006 Keynote WSIT Demo

A new sample is added to WSIT samples that shows an enterprise Web service enabling integration both within and across boundaries. This sample demonstrates a price quotation service that provides list price to clients based on the product identifiers. The client makes a request to a Retail Quote Service (RQS)  which then communicates with multiple Wholesale Quote Service (WQS) to get the best price and returns that to the client. In the first version of this sample, the client and all the service endpoints (RQS + 2 WQS) are built and deployed using WSIT. A later version of the sample will replace one of the WQS to be built and deployed using Windows Communication Foundation (WCF) and also have a WCF client, in addition to WSIT client, invoking the RQS.

The sample demonstrates secure reliable communication between RQS and two WQS. It also demonstrates secure MTOM between the client and RQS. A picture is worth a thousand pictures and so this graphical representation should help visualize.

This sample was demonstrated in JavaOne 2006 keynote and used as the basis of my JavaOne 2006 technical session (TS-5540). In case, you need more technical details, the StarOffice version of slide has speaker notes and animation.

Instructions to check out the sample

This sample can be checked out using the instructions given here. These instructions will retrieve WSIT sources along with the sample sources as both are required to build, run and deploy the sample. The sample exists in wsit/wsit/samples/pricequote directory. Once checked out, follow the instructions in readme.html in the pricequote directory to build and deploy the sample on GlassFish.

Technorati: Javaone Indigo WCF Web-services Interoperability presos

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060804 Friday August 04, 2006

WCF Interop: Workaround for Incorrect Action values from WCF client

In my last blog entry, I described how WS-Addressing Action header value is calculated. A WSIT-enabled client/endpoint generates/expects the correct values per W3C Candidate Recommendation.  However Microsoft's WCF (Windows Communication Foundation) client does not generate the correct value of Action header in all cases. This blog describes the issue and workaround. 

As described in the previous blog, in the first case, where wsaw:Action is explicitly associated with wsdl:input message, WCF client generates the correct Action header value. In the second case where a non-empty soapAction is specified on wsdl:binding/wsdl:operation, WCF client generates the correct Action header value. In the third case where either soapAction is not specified or defined with an empty string as it's value, WCF client generates empty string as Action header instead of the default action. This causes an interoperability issue between WSIT and WCF starting Jun CTP. Lets understand this issue and see how it can be worked around.

If the WSDL has either of the following binding sections:  

<binding name="..." type="tns:wsaTestPortType">
  ...
  <operation name="echo">
    <soap:operation soapAction="">
    ...
  </operation>
</binding>

where soapAction's value is an empty string, or

<binding name="..." type="tns:wsaTestPortType">
    ...
  <operation name="echo">
    <soap:operation>
    ...
  </operation>
</binding>

where soapAction is not specified, then WCF client sends empty string as Action header value.

This is incorrect as W3C WS-Addressing WSDL Binding requires a default action to be generated/expected in this case. But because WSIT-based endpoint expects the correct value according to W3C Candidate Recommendation, there is a conflict and thus WSIT and WCF do not interoperate. Without getting into why there are different interpretations of the spec (probably another blog later), lets see how we can work around this.

WSIT Java-first endpoint, WCF client

If you build your Web service endpoint starting from Java (as opposed to starting from WSDL), then wsimport tool will generate a WSDL with soapAction="" in the SOAP binding. The reason it does that is because JSR 181 (Web Services Metadata for the JavaTM Platform) says all methods in a SEI (service endpoint interface) are mapped to WSDL operations. A @WebMethod annotation may be used to customize the mapping, but in it's absence a default @WebMethod is assumed on each method. The @WebMethod annotation has a member with name "action" that determines the value of soapAction for SOAP bindings. This member has a default value of "" (empty string). And thus, in this case, any WSDL generated by WSIT, either at runtime or using wsimport tool, where SEI does not have @WebMethod.action set to any non-empty-string value, has soapAction="" in the SOAP binding section.

So if your SEI looks like:

@WebService
public class AddNumbersImpl {

  public int addNumbers(int number1, int number2) {
    ...
  }
}

The generated SOAP binding will look like:

<operation name="addNumbers">
  <soap:operation soapAction="" />
  ...
</operation>

As explained above, WSIT and WCF do not interoperate for such a WSDL. The default value (empty string) of soapAction can easily be overridden by adding a @WebMethod annotation on your method as shown below. So if your SEI looks like:

@WebService
public class AddNumbersImpl {

  @WebMethod(action="addNumbers";)
  public int addNumbers(int number1, int number2) {
    ...
  }
}

The generated SOAP binding in this case looks like:

<operation name="addNumbers">
  <soap:operation soapAction="addNumbers" />
  ...
</operation>

WCF client will generate "addNumbers" as the Action header and WSIT endpoint will accept it as a valid value.

WSIT WSDL-first endpoint, WCF client

If you are starting from WSDL, then you can either explicitly specify wsaw:Action attribute on the input message, as shown below:

<portType name="AddNumbersImpl">
  <operation name="addNumbers">
    <input message="tns:addNumbers" wsaw:Action="http://example.org/action/echoIn"/>
    <output message="tns:addNumbersResponse"/>
  </operation>
</portType>

Note, this is only required to be changed for input messages as WSIT endpoint generates the correct action on fault and output messages going back to WCF client.

Alternatively you can change, or add if missing, soapAction in the binding section, as shown below:

<operation name="addNumbers">
  <soap:operation soapAction="addNumbers" />
  ...
</operation>

As a convenience, you can use the operation name as the value of either wsaw:Action or soapAction since that is guaranteed to be unique.

WCF Endpoint, WSIT client

A WCF endpoint always generates explicit wsaw:Action for each message in the portType and exactly same value of soapAction. WSIT client is interoperable with WCF endpoints out of the box in this case.

Hopefully WCF will be fixed in the upcoming CTP and behave as per W3C standards. Then this workaround will not be required and life will be simpler again :)

Technorati:   WSIT WCF Indigo Web-services Interoperability

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060714 Friday July 14, 2006

RESOLVED: WSIT and WCF Jun CTP Interop Bug

Taking on from previous post ...

Even though the list of breaking changes from Feb CTP to Vista Beta 2 and Vista Beta 2 to Jun CTP are documented. The list is missing a "minor" detail of changing the WS-Addressing 1.0 WSDL Binding namespace from http://www.w3.org/2005/08/addressing (same as SOAP Binding namespace) to http://www.w3.org/2006/05/addressing/wsdl (WSDL Binding CR namespace). As a result a user reported interop problems between Jun CTP and WSIT.

I updated the namespace for WS-Addressing WSDL Binding in WSIT this morning. After deploying one of the JAX-WSA unit tests and invoking svcutil.exe to generate proxy, got the following warning:

Warning: The optional WSDL extension element 'UsingAddressing' from namespace 'http://www.w3.org/2006/05/addressing/wsdl' was not handled.
XPath: //wsdl:definitions[@targetNamespace='http://example.org/wsaTestService2']/wsdl:binding[@name='wsaTestPortTypeBindingAddressingRequired']

Seems like this CTP completely ignores a standard W3C extension element to indicate WS-Addressing on a binding/port. It generated the proxy correctly but of course the client did not send expected WS-Addressing headers and thus the endpoint faulted appropriately. Anyway, I specified UsingAddressing within a policy assertion, regenerated the proxy and invoked the client. The server returned the response correctly and CTP client displayed the response in console.

WSIT is now again interoperating with Jun CTP.

Technorati: WSIT Interoperability Web Services

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

WSIT and WCF Jun CTP Interop Bug

One of WSIT user reported an issue with WCF June CTP in WSIT user forums. And thus I tried installing the latest CTP from Microsoft. But as always, there are different runtime and SDKs floating on the website (dejavu). Lets see which one are required. 

The runtime components can be downloaded from here. There is a separate link for .NET Framework 3.0 Runtime Components Beta2 for Windows XP + SP2. But similar runtime components for Jun CTP are available for Windows XP only, no SP2. This is confusing but I took "Jun CTP" in the link name as the main indicator and hoped it was just a typo. Plug and Pray and yep, that was the correct runtime component.

The Windows SDK can be downloaded from here. If I click on 3rd bullet to download Windows SDK, then this is SDK for Beta2 of Vista and WinFX Runtime Components. This seemed incorrect but I still tried installing it and hoping it was a typo as in the previous case. But nope, not this time. Related Resources on the runtime website finally showed a link to the correct Windows SDK.

Why cant the runtime and SDK be published together in a consistent manner ? Once again, here is the correct runtime and SDK that gives you the functionality of Jun CTP.

Now I can get back to my work. 

BTW, The svcutil version is 3.0.4219.0.

Technorati: Bugs WSIT

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060531 Wednesday May 31, 2006

Project Tango @ SDN Channel

View Sun and Microsoft on Project Tango at Sun Developer Network Channel (SDN). SDN caught me and Kirill at the Microsoft pod in the JavaOne 2006 pavilion and talked to us about Project Tango and how developers can have access to this content. If interested in the content, you can view the video cast from 28:35 through 31:09.

Technorati: Javaone Microsoft Interoperability

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060530 Tuesday May 30, 2006

TS-5540 Summary by an audience

Read a brief summary of my talk (TS-5540, Making Java™ Technology-Based/.NET Web Services Interoperability Real) at JavaOne this year here by an audience. The slides were posted earlier.

Technorati: Javaone WCF Interoperability presos  

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

Project Tango @ Java One 2006 - Part 2

I posted the list of sessions and labs as part of Project Tango in JavaOne 2006 earlier.  It indeed got a lot of attention during JavaOne this year (see further down). I posted a collection of articles talking about Sun and Microsoft Web services interoperability effort earlier. Here is another article published on ZDNet Japan covering Project Tango and how it has fully embraced the keywords at JavaOne this year, namely SOA, Open Source and Web 2.0. Koji Tokuda, author of the article, told me that this was one of the top 50 articles reviewed on Google News Japan on the day following the general session keynote demo. Here is an English translation of the article using Google Translate English BETA. This article mentions me as the leader of Project Tango which is inaccurate since I'm just one of the team members but do touch lot of components in the project :) 

Here is another article in Japanese (English version) on Sun's SOA offerings and how they link to WSIT.

Coming back to Project Tango coverage in JavaOne, Googling Sun Project Tango JavaOne gives 17,200 entries.

google-2.JPG

Googling on Sun Project Tango gives 1,750,000 search entries and of course these entries are bound to grow as developers download and contribute to wsit.dev.java.net.

google-1.JPG  

Technorati: Javaone Indigo WCF Interoperability presos  

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060523 Tuesday May 23, 2006

JavaOne 2006 TS-5540 Slides

StarOffice and PDF versions of my J1 session (TS-5540, Making Java™ Technology-Based/.NET Web Services Interoperability Real) are now available. The StarOffice version has speaker notes and animation as well.

Technorati:     slides presos

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060518 Thursday May 18, 2006

Tango at Microsoft JavaOne party

I attended Microsoft JavaOne party Wednesday night. It was great to meet their developer evangelists (Jas, Nima and Woody to name a few). I specifically spent some time with Mohammed Akif who is a member of Microsoft Architecture Editorial Board. He is an ex-Sun employee and used to be a Senior Java architect and co-authored several Java books before joining Microsoft. I recommend reading his extensive coverage of JavaOne so far.

BTW, check me and Kirill doing Tango at the party here. I'm now relaxed after literally living at work for the past few weeks to pull the keynote demo.

Technorati:  

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

Articles on Sun/Microsoft interoperability

Here is the official and some related press release on the interoperability efforts happening between Sun and Microsoft for past few months:

  1. http://www.sun.com/smi/Press/sunflash/2006-05/sunflash.20060516.5.xml
  2. http://biz.yahoo.com/prnews/060516/sftu095.html?.v=56
  3. http://www.ftponline.com/special/javaart/interop/

In a related article published here in eweek, a quote from the article says "The companies' cooperation will soon give developers freedom to work with Web services partners using Microsoft's Windows Communication Foundation (formerly "Indigo";) or JAX-WSA (Java API for XML Web Services Addressing)."

Although I fully agree with Peter that this cooperation between the two companies will provide flexibility to work with either of the framework. But here WCF is incorrectly compared to JAX-WSA. The latter provides an API to enable WS-Addressing support in Java platform and is just one of the multiple specifications supported by WSIT. Instead WCF should be correctly compared to WSIT. I've already emailed a correction to the editor and hopefully will hear back soon.

Technorati:

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060517 Wednesday May 17, 2006

JavaOne 2006 - Project Tango Keynote Demo

We, at Sun Microsystems, have been working with Microsoft for past several months on achieving interoperability between Java EE and .NET technologies. Web Services Interoperability Technology (WSIT, a.k.a Project Tango) is Sun's Web services interoperability portal and provides all information on that effort. Earlier yesterday, we gave a demonstration of our work so far in JavaOne 2006 keynote. The main points from the talk is that Project GlassFish community and Windows Communication Foundation make Interoperability a Reality TODAY.

A video clip of the keynote demo is available here. This clip starts with our keynote presentation where Nick Kassem explains the business scenario which shows how Web services technologies enables integration within and across business boundaries. Watch me explaining the development environment to Jeff Jackson from 3:46 to 4:48. All the tools and technologies used in the demo are available today. And then Kirill Gavrylyuk shows an interoperability demo between Infocard and Sun's Secure Token Service. A picture is worth thousand words, here is a graphical representation of the scenario.

On the right, a Retail Quote Service (RQS), running in Sun-managed environment, uses Wholesale Quote Service (WQS) to serve car quotes to Java and WCF consumers shown on the bottom left. RQS also gets competitive bids from a WQS running in a Microsoft managed environment. The clients talk to the RQS secure MTOM, RQS talks to WQS using a Secure and Reliable Connection. Each managed environment has it's own identity provider, also known as Secure Token Service or STS in short. A trust relationship between the two environments is enabled by a trust relationship between a priori trust relationship between STS.

We also plan to share the demo code in the near future and I'll post another blog when it's available.

A specific Call To Action for you is to:

Test Drive Web Services Interoperability
java.sun.com/webservices/interop: Your main Web services interoperability portal.
Download! and Contribute!
wsit.dev.java.net: Your main source for downloading the source code, samples, documentation, etc.
Get the FREE Project GlassFish Open Source App Server
java.sun.com/javaee/glassfish: All WSIT technologies can be installed on this FREE app server
Download Netbeans IDE Module:
websvc.netbeans.org/wsit: All WSIT technologies available today can be configured visuall using this Netbeans module.

Check out some of the pictures I took at JavaOne on Tuesday. This picture shows me, Nick and Kirill.

Technorati: presos

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060516 Tuesday May 16, 2006

Introducing wsit.dev.java.net

  • 637 new Java source files
  • Approx 111K lines of new code
  • How To Documentation and Samples
  • Integrated NetBeans 5.5 tooling
  • Implementations of WS-Policy, WS-Security Policy, WS-Metadata Exchange, WS-Security 1.0 and 1.1, WS-Secure Conversation, WS-Trust and WS-Reliable Messaging.
  • Leverage existing JAX-WS programming model
  • User list and interoperability forum

These are some of the statistics of Sun's open-source implementation of next generation Web services technologies that deliver interoperability between Sun's Application Server 9.1 PE (part of GlassFish) and Microsoft's Windows Communication Foundation (WCF, aka Indigo). This implementation is known as Web Services Interoperability Technology (WSIT) and is part of Project Tango. Sun delivers on the initial promise of facilitating interoperability with .NET platform by embracing and open sourcing implementations of key WS-* specifications. Read more about the various technologies involved here.

We, engineers in Sun, have been working directly with Microsoft engineers ensuring out-of-the-box interoperability for WSIT artifacts with WCF. Read about Sun's participation in previous plugfests (Nov 2005 and Mar 2006).

NetBeans 5.5 IDE and documentation is released along with the source. This facilitate users to download the WSIT bundle and try the pre-existing samples or create new ones from scratch without remembering the exact syntax of config files or any other option that might be required to configure the sample.

Everything mentioned above can be downloaded at wsit.dev.java.net.

Download it, try it and pretty soon you'll find yourself completely immersed. And we do appreciate your feedback.

Technorati:

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

http://blogs.sun.com/arungupta/date/20060331 Friday March 31, 2006

Microsoft joins JCP

On the second anniversary of Microsoft and Sun entering into a broad technology collaboration, Microsoft exceeded expectations on this relationship when they decided to join the Java Community Process (JCP). JCP is an open and participative process to develop and revise the Java technology specifications, reference implementations and test suites. The exact details of their participation are still being worked out but they've already signed the Java Specification Participation Agreement (JSPA) and are now a member of the JCP.

Microsoft and Sun engineers have been working very closely in the recent months to ensure interoperability of enterprise features. This will ensure that Sun's Project Tango, that will be released on java.net and installable on Glassfish, will interoperate with Microsoft's Windows Communication Foundation (aka Indigo) out-of-the-box. After achieving great interoperability results between the two companies in the recent plugfest (Nov '05, Mar '06) meets conducted at Microsoft campus, Microsoft expressed interest in participating in the JSRs relevant to their enterprise feature.

This is an extremely pleasant surprise to the entire developer community since Microsoft's participation in the JCP will ensure that Microsoft can interoperate, not only with Sun, with the entire Java platform.

Interoperability between Microsoft and Sun products, as mentioned above, is a reality but every thing else said above is only wishful thinking since this blog is written to celebrate a special day of the year.

Happy April Fool's Day!

Technorati: Microsoft Sun JCP Interoperability April Fool Indigo

del.icio.us | furl | simpy | slashdot | technorati | digg |
|

Project Tango @ Java One 2006

JavaOne is 6 weeks away and I can see the momentum building up within Sun for the slideware, demoware, machines etc. As it gets closer, everything starts revolving around JavaOne. I've been involved with Project Tango since it's inception and here is the list of related technical sessions and BoFs that will be presented:

Session # Title Speakers Location
TS - 5540 Making Java™ Technology-Based/.NET Web Services Interoperability Real Kirill Gavrylyuk (Microsoft)
Arun Gupta (Sun Microsystems)
Room: Esplanade 307-310
Date: 16-MAY-06
Start Time: 11:00 
TS - 4661 Composable Web Services Using Interoperable Technologies from Sun's "Project Tango" Harold Carr, Nick Kassem (all Sun Microsystems) Room: Esplanade 307-310
Date: 16-MAY-06
Start Time: 02:00 PM 
TS - 1603 Reliable and Transacted Web Services between Java™ Technology-Based Project Tango and Microsoft Indigo Joe Fialli, Mike Grogan, Ryan Shoemaker (all Sun Microsystems) Room: North Mtg Rm 121/121/124/125
Date: 18-MAY-06
Start Time: 02:45 PM 
TS 3473 Web Services Security, WS-Trust, WS-Policy, and WS-SecureConversation Using Java™ Web Services Developer Pack Venugopal K, Jayanthi Kumar, Jiandong Guo  (all Sun Microsystems) Room: North Mtg Rm
Date: 18-MAY-06
Start Time: 12:15 PM 
BOF 2477 Interoperating Using XML Web Services Security 3.0 Jiandong Guo, Janet Breur, Pat Patterson (all Sun Microsystems), Mike Jones (Microsoft) Room: Hall E 135
Date: 16-MAY-06
Start Time: 09:30 PM 
LAB 4335 Developing Interoperable Next Generation Web Services with Project GlassfishSM, Netbeans IDE & WSIT Martin Grebac, Ramesh Babu Mandava, Ana Lindstrom-Tamer (all Sun Microsystems) Wednesday, 17-MAY-06
7:20 PM
Hall E 130/131

Each of these sessions will use code samples and current products to demonstrate interoperability between Glassfish and Windows Communication Foundation. I will update the location for other bofs as I get them.

Technorati: Javaone Indigo WCF Interoperability presos  

del.icio.us | furl | simpy | slashdot | technorati | digg |
|
« Previous page | Main | Next page »

Valid HTML! Valid CSS!

This is a personal weblog, I do not speak for my employer.