Spring Integration

org.springframework.integration.annotation
Annotation Type Gateway


@Target(value=METHOD)
@Retention(value=RUNTIME)
@Inherited
@Documented
public @interface Gateway

Indicates that a method is capable of mapping its parameters to a message or message payload. These method-level annotations are detected by the GatewayProxyFactoryBean where the annotation attributes can override the default channel settings.

A method annotated with @Gateway may accept a single non-annotated parameter of type Message or of the intended Message payload type. Method parameters may be mapped to individual Message header values by using the @Header parameter annotation. Alternatively, to pass the entire Message headers map, a Map-typed parameter may be annotated with Headers.

Return values from the annotated method may be of any type. If the declared return value is not a Message, the reply Message's payload will be returned and any type conversion as supported by Spring's SimpleTypeConverter will be applied to the return value if necessary.

Author:
Mark Fisher, Gary Russell

Optional Element Summary
 java.lang.String replyChannel
           
 long replyTimeout
           
 java.lang.String requestChannel
           
 long requestTimeout
           
 

requestChannel

public abstract java.lang.String requestChannel
Default:
""

replyChannel

public abstract java.lang.String replyChannel
Default:
""

requestTimeout

public abstract long requestTimeout
Default:
-9223372036854775808L

replyTimeout

public abstract long replyTimeout
Default:
-9223372036854775808L

Spring Integration