Announcement Announcement Module
Collapse
No announcement yet.
Example of GatewayProxyFactoryBean Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Example of GatewayProxyFactoryBean

    Hi

    Can any one of you provide me a working example or how to write a sample
    application which uses a GatewayProxyFactoryBean.

    How does the gateway namespace which accepts an iterface?
    How does invoking a method on this bean invoke the send and receive methods?

    Kindly explain.

    Thanks and Regards
    Bharath

  • #2
    Hi Bharath,

    Section "2.11 MessagingGateway" of the documentation covers that. It is valuable to look at "2.10 RequestReplyTemplate" before that.

    Some more detail:

    This generates a dynamic proxy that wraps the sending of a message and waiting for a response, so that it is usable as a Java class

    Essentially, the argument of the method will be sent as a message on the request-channel (using a MessageCreator) and if the method signature specifies a return value, the method call will block until the response message arrives on the reply-channel. If there are no method arguments, then the method will just block until a message arrives, if there is no return type for the method (i.e. it is void), the method will return immediately.

    Hope that helps,
    Marius

    Comment

    Working...
    X