Annotation Interface HandleWeb
@Documented
@Retention(RUNTIME)
@Target({METHOD,ANNOTATION_TYPE})
@HandleMessage(WEBREQUEST)
public @interface HandleWeb
Marks a method or meta-annotation as a handler for incoming web requests (
MessageType.WEBREQUEST).
Web requests received by the Fluxzero Runtime are logged. Connected client applications can route these requests using
this annotation or one of its specific variants, like HandleGet, HandlePost, etc.
This annotation can be used directly to handle any method (GET, POST, etc.), or indirectly via more specific
annotations like HandleGet, HandlePost, HandleSocketOpen, etc.
By default, a handler will return a result which is published to the WebResponse log. To suppress this
behavior, set passive = true.
- See Also:
-
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionbooleanIftrue, disables this handler during discovery.String[]HTTP or WebSocket methods that this handler supports (e.g.booleanIftrue, the handler will not publish a response to theWebResponselog.String[]One or more path patterns this handler applies to (e.g.
-
Element Details
-
value
-
disabled
boolean disabledIftrue, disables this handler during discovery.- Default:
false
-
method
String[] methodHTTP or WebSocket methods that this handler supports (e.g. GET, POST, WS_OPEN). Default isHttpRequestMethod.ANY.- Default:
{"*"}
-
passive
boolean passiveIftrue, the handler will not publish a response to theWebResponselog.- Default:
false
-