users@jax-ws.java.net

Re: use case for dynamic proxy?

From: Anne Thomas Manes <atmanes_at_gmail.com>
Date: Wed, 1 Feb 2006 13:11:08 -0800

Yes, you must generate the interface from the WSDL, but dynamic proxy allows
you to generate the implementation -- and the specific binding details -- at
runtime.

This allows you to dynamicallly select a service that implements a standard
interface at runtime and bind to it. Say for example you have defined a
standard WSDL interface that defines an operation called submitOrder, and
you have a dozen business partners that provide services that implement the
interface. Each business partner is likely to have a unique binding -- some
use HTTP vs JMS transport, each uses a different SOAPAction, etc.

When using the dynamic proxy, the application retrieves the WSDL and
generates the binding at runtime.One application can interface with any of
the dozen partners.

Anne

On 2/1/06, Mark Hansen <mark_at_javector.com> wrote:
>
> What is a use case where dynamic proxies make sense? In the example
> from the JAX-WS 2.0 specification (4.2.3.1), is shows how you can get a
> proxy using the StockQuoteProvider interface, without needing to
> genereate a stub class. But, where does the StockQuoteProvider
> interface come from? For all practical purposes, don't you have to
> generated the StockQuoteProvider interface from the WSDL?
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jax-ws.dev.java.net
> For additional commands, e-mail: users-help_at_jax-ws.dev.java.net
>
>