Annotation Type CommandHandler
-
@CommandHandler @Deprecated @Documented @Retention(RUNTIME) @Target({METHOD,ANNOTATION_TYPE,CONSTRUCTOR}) public @interface CommandHandler
Deprecated.since 1.7, for removal in 2.0. UseCommandHandler
instead.Identifies a command handler in the context of CQRS, i.e. logic to process aCommand
. The command handler may or may not reject the command. In case of processing, the handler takes care of orchestrating the business logic related to the command.- Since:
- 1.1
- See Also:
- CQRS Documents by Greg Young - Commands
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.String
name
Deprecated.Optional identification of the name of the command handled by this handler.java.lang.String
namespace
Deprecated.Optional identification of the namespace of the command handled by this handler.
-
-
-
Element Detail
-
namespace
java.lang.String namespace
Deprecated.Optional identification of the namespace of the command handled by this handler. This information may be used for easier linkage between command and handler by external tools and refers toCommand.namespace()
. When leaving the default value, it is assumed that the method signature makes clear what command is consumed. If the handler takes care of all commands of a specific namespace, the value of this field needs to be set to the respective namespace and thename()
needs to be set accordingly. If the handler doesn't care about the namespace, the value may be set to the '*' (asterisk) placeholder.- Default:
- ""
-
-
-
name
java.lang.String name
Deprecated.Optional identification of the name of the command handled by this handler. This information may be used for easier linkage between command and handler by external tools and refers toCommand.name()
. When leaving the default value, it is assumed that the method signature makes clear what command is consumed. If the handler takes care of all commands of a specific namespace, the value of this field needs to be set to the '*' (asterisk) placeholder.- Default:
- ""
-
-